Search for and find large files on your server Print

  • 13

Syntax for RedHat / CentOS / Fedora Linux

find {/path/to/directory/} -type f -size +{size-in-kb}k -exec ls -lh {} \; | awk '{ print $9 ": " $5 }'

Search or find big files Linux (150MB) in current directory, enter:
$ find . -type f -size +150000k -exec ls -lh {} \; | awk '{ print $9 ": " $5 }'

Search or find big files Linux (150MB) across the whole server, enter:
$ find / -type f -size +150000k -exec ls -lh {} \; | awk '{ print $9 ": " $5 }'

Search in my /var/log directory:
# find /var/log -type f -size +100000k -exec ls -lh {} \; | awk '{ print $9 ": " $5 }'

Syntax for Debian / Ubuntu Linux

find {/path/to/directory} -type f -size +{file-size-in-kb}k -exec ls -lh {} \; | awk '{ print $8 ": " $5 }'

Search in current directory:
$ find . -type f -size +10000k -exec ls -lh {} \; | awk '{ print $8 ": " $5 }'


Was this answer helpful?

« Back