ubuntu文件清理.md

大文件查看

cd /

sudo ls -a |sed -e ‘/^.$/d’ -e ‘/^..$/d’ | xargs -i sudo du -ms {}|sort -n |tee “/tmp/.capacity.date "+%Y-%m-%d_%H-%M-%S".log

大文件来源

  • thunderbird 回收站, 收件箱缓存

${HOME}/.thunderbird/gz2x0nma.default/ImapMail

echo “” > filename

  • idea应用日志

${HOME}/.IntelliJIdea2017.2/system/tomcat

find ./ -type f -iname “*.log” |xargs -i rm -rf {}