How to reclaim storage of "deleted", but still used files on Linux?
You can use the entries in /proc
to truncate such files.
# ls -l /proc/4315/fd
That will show all the files opened by process 4315. You've already used lsof
and that shows that the deleted file is file descriptor 135, so you can free the space used by that deleted file as follows:
# > /proc/4315/fd/135
The same goes for the other deleted file opened by process 44654, there it's file descriptor 133, so:
# > /proc/44654/fd/133
You should now see that the space is freed up.
You can also use this to copy the contents of a file that's been deleted but still held open by a process, just cp /proc/XXX/fd/YY /some/other/place/filename
.