How to clean large files under Linux

  

Find large files
find /dir -size +100M -exec ls -lh {} \\;

If you want to empty some text file classes, you can use
echo "" > /www/xxx.log

If you want to delete files larger than 50M directly, use the command
find /var/mail/-size +50M -exec rm {} \\;

If you want to sort folders and files, you can use
du -s * |  Sort -nr |  Head

Copyright © Windows knowledge All Rights Reserved