#!/usr/bin/ksh
vxprint | grep Disk |awk {'print $3'} | grep -v rootdg >/var/tmp/dgname
printf "\n......................................................................\n"
printf "Server Name : "
hostname
cat /var/tmp/dgname | while read dgnames
do
printf "......................................................................\n"
printf "\nDiskGroup Name : $dgnames "
vxprint -g $dgnames | grep ^dm |awk 'BEGIN {TOT=0} {TOT=TOT+$5} END{print " Total Size of the DG=" TOT/2/1024" MB ("TOT/
2/1024/1024" GB)\n"}'
vxprint -g $dgnames | grep ^v | awk '{print "Volume : " $2" " $5/2/1024 " MB (" $5/2/1024/1024 "GB)"}'
printf "\nAvailable space in $dgnames = "
vxassist -g $dgnames maxsize| awk '{print $5}'
done
printf "......................................................................\n"