Thursday, August 4, 2011

df not showing correct free size after deleting a file

Some times when you delete a file df does not show the true file size (i.e. it does not consider the deleted file size ). This is due to the fact that some processes still have a handle on the file i.e. they might still be using the file. This can be confirmed by the following command

as root run "lsof -n | grep file

to see the list of processes still having a handle on file.

You may kill the processes or restart the system to fix this.

No comments: