cemdogan.com

Tag: bash

folder sizes

by on Jun.13, 2009, under linux

To list the users in the size of the mailbox (Maildir) is available;

du-h / home / users | awk '$ 1 ~ / M / {sub (/ M /, "MB"); print $ 0}' | awk '$ 2 ~ /. Maildir $ / {print $ 0}' | sort-n

To list files larger than 20Mb

find /-type f-size +20000 k-exec ls-lh {} \; | awk '{print $ 9 ":" $ 5}'

To correct folder in the file name spaces, and uppercase letters;

/ Bin / bash
for f in *; do
file = $ (echo $ f | tr AZ az | tr '' _)
[! -F $ file] & & mv "$ f" $ file
done

more... 1 Comment : , , , , , , , , ... more

Search

The following kutucukla site search you can do:

Links