网上资料学习:
1、查找当前目录下最大文件(包括子目录里文件):
find . -type f -exec stat -c "%s %n" {} ; | sort -nr | head -1
2、只考察目录下的文件,排除掉目录(每一行以-开头)
ls -l | awk '/^-/ {print $5 $8}' | sort -nr | head -1
3、下面这种方法会把子目录当做一个文件来看。
du -s * | sort -nr | head -1