|
Im sorry if Ive confused you...
Objective:
1. Calculate the sum of total space, used space for all matching 'filesystems'
2. Display "Total Space = xx " ; "Used Space = yy"; "Free space = zz"
This is the script I have wrote for it:
[code1]
find / -name 'filesystem' 2>/dev/null
while read line
do
bdf $line
done
awk '{print$1}' | sort -n | grep -v used | awk '{sum += $1} END { print sum;}'
The find command works fine, but the while do command hangs? So I dont know if the awk print line works?
Bigben
|