What an inode is, how to see inode usage with df -i, and how to find directories with millions of small files.
An inode is the data structure a Unix-style file system uses to store information about a file, such as its owner, permissions, size and where its data lives. Each file uses one inode, and many file systems have a fixed number, so millions of tiny files can cause 'No space left on device' while df -h still shows free space.
'df -i' lists total, used and free inodes per file system. 'ls -i' shows a file's inode number, and 'stat <file>' shows its inode details.
Session or cache directories of web applications, mail queues, unrotated small log files and build caches can create millions of files.
GNU du can count inodes: 'du --inodes -x / | sort -n | tail' lists the directories with the most entries.
df -i (IUse% near 100%).sudo du --inodes -x --max-depth=3 / | sort -n | tail -20find /path -type f -mtime +7 -delete after a dry run without -delete.Last updated: 2026-10-08
How to read df output, why Use% can reach 100% before Avail is zero for normal users, and how to check inodes with df -i.
How to use find to list big or old files on Linux, preview them safely and delete only what you checked.
How to find what fills a Linux disk with du and the interactive ncdu, with options that stay on one file system.