====== 查找inode占用过多的文件夹 ====== 查找最近1天的最新文件信息,可以明显发现碎片文件增长迅速的文件夹 find / -mtime -1 find / -mmin -1 对怀疑的文件夹进行扫描,逐层扫描后定位到文件夹 ls -fR xxx | wc -l #删除 ls -UR1 | xargs -n 100 rm -f ====== 清理文件 ====== #推荐使用,速度快 find xxx -type f |xargs -n 200 rm -rf #速度非常慢 find xxx -type f | exec rm -rf {}\; #速度快,缺点是不能指定文件类型 rsync --delete -a 空文件夹 xxx ---- ====== 常见文件夹 ====== ===== maildrop ===== ls /var/spool/postfix/maildrop/ | wc -l