wozijisunfly 2010-04-28
liweihui@liweihui-desktop:~/Documents/zbs$ df -h Filesystem Size Used Avail Use% Mounted on /dev/sda1 71G 26G 43G 38% / varrun 759M 116K 759M 1% /var/run varlock 759M 0 759M 0% /var/lock udev 759M 44K 759M 1% /dev devshm 759M 384K 759M 1% /dev/shm lrm 759M 40M 720M 6% /lib/modules/2.6.24-27-generic/volatile gvfs-fuse-daemon 71G 26G 43G 38% /home/liweihui/.gvfs
--max-depth表示深入目录的层次,如果不指定,则会一直迭代
liweihui@liweihui-desktop:~/Documents/zbs$ du -h --max-depth=1 1.8M ./app 1.1M ./spec 36K ./bat_tasks 224K ./features 39M ./.git 15M ./db 20K ./test 8.0K ./doc 3.7M ./lib 9.7M ./vendor 268K ./config 260K ./index 132M ./log 108K ./script 24M ./public 225M .
linux 查看磁盘命令 du df. ② df -h: 查看每个根路径的分区大小。④ du -sm[ 目录名]: 返回该文件夹总 MB 数。⑤ du -h[目录名]: 查看指定文件夹下的所有文件大小