How to find the largest files and directories in Linux?

How to find the largest files and directories in Linux?

Answer:

For example, to list out top 10 files and directories inside /opt, you can use the following command:

# du -a /opt| sort -nr | head -n 10

Attachments
There are no attachments for this article.
Related Articles RSS Feed
Managing temporary files with systemd-tmpfiles on Red Hat Enterprise Linux 7
Viewed 9797 times since Sun, Nov 22, 2020
zabbix linux How to solve apache error No space left on device: Cannot create SSLMutex
Viewed 2557 times since Wed, Nov 11, 2020
INSTALACJA MIB SNMP W SYSTEMIE CENTOS/RHEL 6
Viewed 13136 times since Fri, Nov 30, 2018
Tunnel SSH Connections Over SSL Using ‘Stunnel’ On Debian 7 / Ubuntu 13.10
Viewed 3463 times since Fri, Sep 28, 2018
ZFS: Remove an existing zfs filesystem
Viewed 2241 times since Sun, Jun 3, 2018
Improve security with polyinstantiation
Viewed 13478 times since Fri, May 15, 2020
List DNS records, nameservers of a domain from command line
Viewed 2126 times since Sun, Sep 30, 2018
stunnel How To Set Up an SSL Tunnel Using Stunnel on Ubuntu
Viewed 1889 times since Sun, Dec 6, 2020
Linux Network (TCP) Performance Tuning with Sysctl
Viewed 11851 times since Fri, Aug 3, 2018
Linux An introduction to swap space on Linux systems
Viewed 2570 times since Thu, Jan 23, 2020