deleted but open file
A file whose last name has been removed but whose data still uses disk space because a process keeps it open.
In more detail
It is the usual reason df reports a full disk while du cannot find the space: du walks names, and this file has none. Common cause: deleting a large log while the service is still writing to it. Restarting the process, or telling it to reopen its logs, frees the space; lsof +L1 lists such files.
Related terms
- unlink — The system call that removes one name from a directory and lowers the file's link count.
- file descriptor — A small number the operating system gives a process for each open file, socket or pipe, used in every later read or write.
- df — The command that reports total, used and free space for each mounted filesystem.
- du — The command that adds up how much disk space a directory and everything below it uses.
- block exhaustion — A filesystem running out of free data blocks, so it cannot store more bytes even though it may have inodes left.
Taught in
- Inodes, Hard Links And What rm Removes — Linux Fundamentals & Systems Administration
- Running Out Of Space: df, du And Inodes — Linux Fundamentals & Systems Administration