Site icon New Generation Enterprise Linux

Stop relying on df when your file system reports a lie

Disk & Filesystem Management (Du/Df/Lsblk/Fstrim)

Stop relying on df when your file system reports a lie

đź§© The Challenge

You’ve been staring at a disk-full error for an hour, but df says you have plenty of room left. Turns out a deleted log file is still being held open by a zombie process, and the kernel isn’t releasing the blocks.

đź’ˇ The Fix

Use lsof to track down exactly which process is keeping those “deleted” blocks alive. It’s the only way to reclaim space without rebooting the whole box.

lsof +L1 /var/log/ | grep deleted

⚙️ Why It Works

Adding the +L1 flag tells lsof to look specifically for open files that have a link count of less than one. This clears up the mystery of where your missing gigabytes vanished to.

🚀 Pro-Tip: Restart the specific service identified in the output instead of bouncing the entire server at 3 AM.

Linux Tips & Tricks | © ngelinux.com | 12/5/2026

0 0 votes
Article Rating
Exit mobile version