I ran across a server in which all the inodes were used and this was causing myriad issues on the server.
# df -i
Filesystem Inodes IUsed IFree IUse% Mounted on
/dev/sda5 16318464 16318464 0 100% /
Filesystem Inodes IUsed IFree IUse% Mounted on
/dev/sda5 16318464 16318464 0 100% /
I needed to find out where all the files were so my colleague Kale provided me with this little script to do what I needed.
for d in *; do echo -n "$d: "; find $d -type f | wc -l; done
This is not recursive so you'll have to drill down through the directories to find the root source.