title: In Linux, how do I find find directory with the most subdirectories or files?
body: <p>How can I find the directory with the largest number of files/subdirectories in it on the system? Obviously the clever answer is <code>/</code>, but that's not what I'm looking for.</p>
  
  <p>I’ve been told the filesystem is out of nodes, so I suspect that somewhere there are a lot of files/directories which are just garbage, and I want to find them.</p>
  
  <p>I’ve tried running this:</p>
  
  <pre><code>$ find /home/user -type d -print | wc -l
  </code></pre>
  
  <p>to find specific directories.</p>