# du htdocs | sort -nr
15076 htdocs/
9940 htdocs/discuz
4668 htdocs/manual
2484 htdocs/manual/mod
2088 htdocs/discuz/images
1980 htdocs/discuz/templates
1976 htdocs/discuz/templates/default
1332 htdocs/discuz/admin
1036 htdocs/discuz/include
920 htdocs/manual/mod/mod_ssl
888 htdocs/discuz/images/common
828 htdocs/discuz/usersguide
604 htdocs/manual/misc
592 htdocs/discuz/forumdata
416 htdocs/discuz/utilities
356 htdocs/discuz/forumdata/templates
320 htdocs/discuz/images/default
312 htdocs/discuz/install
sort 的参数 -nr 表示要以数字排序法进行反向排序,因为我们要对目录大小做排序,所以不可以使用
human-readable 的大小输出,不然目录大小中会有 K、M 等字样,会造成排序不正确。
阅读(1323) | 评论(0) | 转发(0) |