How to make script check disk auto

October 12, 2010 at 01:24:55
Specs: Unix
Dear All,

I am student for shell script
I would like to check disk space on solaris10.
I ran #df -h it is ok BUT I need to show just row that i need
such as


1 Filesystem size used avail capacity Mounted on
2 /
3 /global
4 /usr

How to make disk space script and cut the some row (<<< I need).?

[This is normal result of df-h ]
Filesystem size used avail capacity Mounted on <<< I need
/dev/md/dsk/d0 94G 34G 59G 37% / <<<< I need
/proc 0K 0K 0K 0% /proc
mnttab 0K 0K 0K 0% /etc/mnttab
fd 0K 0K 0K 0% /dev/fd
swap 36G 264K 36G 1% /var/run
dmpfs 36G 0K 36G 0% /dev/vx/dmp
dmpfs 36G 0K 36G 0% /dev/vx/rdmp
swap 36G 944K 36G 1% /tmp
vxiprd:/intf 56G 15G 39G 28% /intf
/dev/md/dsk/d52 1002M 4.9M 937M 1% /global/.devices/node@2
/dev/md/dsk/d5 963M 4.9M 900M 1% /global/.devices/node@1
/dev/vx/dsk/apoprddg/apoprdvol
942G 743G 197G 79% /global/apoprd <<< I need
/dev/vx/dsk/apoprddg/transvol
6.0G 2.1G 3.8G 36% /usr/sap/trans <<<< I need


Thank you very much for your kinldy help


See More: How to make script check disk auto

Report •

#1
October 19, 2010 at 17:52:33
you can use awk. Google "gawk manual"

GNU win32 packages | Gawk


Report •
Related Solutions


Ask Question