Show larger files in Linux

Tiempo de lectura: < 1 minuto

Today I’m sharing a command that will help us find the largest files using Linux.

Forest - pexels

We use the following command in the console:

sudo find / -type f -exec du -Sh {} + 2>/dev/null | sort -rh | head -n 50

This will show the largest files and we can delete them.

Si queremos resetear un log podemos usar lo siguiente:

sudo truncate -s 0 /var/lib/docker/containers//-json.log

Leave a Comment