du -sh shows incorrect size for directories with hard links

Solution Verified - Updated -

Issue

  • When running du -sh on directories that share hard links, the first directory shows the correct size while the other directories report a smaller size
  • du not accounting for hard links
  • du -sh showing wrong size calculations

Environment

  • Red Hat Enterprise Linux 6
  • Directories with numerous hard links

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.

Current Customers and Partners

Log in for full access

Log In
Close

Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.