df command still shows much space used after delete all files under ubifs

Mao Wang maow at qti.qualcomm.com
Wed Jun 19 02:04:29 PDT 2024


Hi, 

We are able to reproduce below issue stably based on kernel 4.14.

Issue description:
1.	Run a special auto. Test for 2~5 days(test step will be descried in details later). 
2.	Stop the test, delete all files under /userdata manually.
3.	Then use df command to check the free space of userdata, when issue reproduced, df result shows 15~70% space used(while according ls result, userdata is empty).

Auto test steps to reproduce the issue:
1.	After log in adb shell, sleep 30s.
2.	Touch one empty file into /userdata.
3.	If above empty file can be created successfully, then delete all files/dirs under /userdata.
4.	Adb push a big file(size less than free space of userdata) into /userdata.
5.	During file push, do SPO(unsafe power cut off directly). 
6.	Sleep 3s, power up the test board again, goto step 1 to repeat the test.

Now we observed that based on same above test case, such issue can't be reproduced on kernel 5.15.
So the purpose of sending this mail is, do you know some changes merged in kernel version bigger than 4.14 which may help to fix above issue? 

Thanks,
Mao



More information about the linux-mtd mailing list