The most recent server space is always an alarm and there is not enough disk space.
Using the DF command, disk space is close to 100%, the stale data on the machine and the logs are cleaned up, but the space is soon approaching 100%.
Using Du view, want to find out where the disk space is spent, the results found that his output and DF command output difference is very large, away from the 100% space occupied is still far away.
Where's The lost space, is the disk damaged?
Search by Google and discover two possible causes:
1. After the disk file is deleted, but the original corresponding to the process of writing the file is still, grasping the file, in the inside to write the data, the space continues to be consumed by him, while the deleted space is not released, du command can not see the space occupied by the file.
2. Use the mount command to mount to a directory that has data, and the files in the previous directory are not visible and are not counted by DU.
Because this server does not have a special directory mount, follow question 1 to find the lost space.
Using Lsof | grep deleted find the deleted file and sure enough to find a huge log file
Kill the process of writing this log file outside, found that disk space 1.1 points were released back
Rerun the process and the discovery log is also written correctly.
Recover lost disk space on Linux