![](/img/trans.png)
[英]How to recursively remove the caret (^) character recursively in all files in a directory?
[英]How to get total size of all files recursively under directory
我正在使用此命令來獲取小於17MB的文件:
hadoop fsck /admin_test -files |
gawk '{if ($2 ~ /^[0-9]+$/ && $2 <= 17825792) print $1,$2;}'
如何獲得小於17MB的所有文件的總大小?
gawk '
$2 ~ /^[0-9]+$/ && $2 <= 17825792 {sum += $2; print $1, $2}
END {print "sum=", 0+sum}
'
如何將du
與--threshold=SIZE
參數一起使用:
-t, --threshold=SIZE
exclude entries smaller than SIZE if positive, or entries greater than SIZE if negative
像這樣的東西:
du -sk --threshold=-17825792 /admin_test
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.