← Disk & Filesystem
Linux · Disk & Filesystem

How to find large files in Linux

Locate the largest files on a Linux filesystem with find, filtered by size and kept to one filesystem with -xdev.


Track down big files that are filling a filesystem. Stay on one filesystem with -xdev so find does not wander into other mounts.

# Files larger than 500 MB under /var (one filesystem only)
find /var -xdev -type f -size +500M -exec ls -lh {} \;

# Top 20 biggest files under a path
find /var -xdev -type f -printf '%s %p\n' 2>/dev/null \
  | sort -rn | head -n 20 \
  | awk '{ printf "%.1f MB  %s\n", $1/1024/1024, $2 }'
LinuxfindLarge Files