Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Mailing Lists -> Oracle-L -> Re: Shell script broken, bdf adds new line for long filesystem name.
Hi Ethan,
Our SA gave me the following script...
Put it in your /usr/local/bin and include the dir in PATH...
#!/bin/ksh
# -- bdfg
COUNT=0
bdfit () {
if [ -z "$SIZE" ] ; then
LVOL2=$LVOL
((COUNT=1))
else
if [ "$COUNT" -eq "1" ] ; then
echo $LVOL2 $LVOL $SIZE $USED $FREE $PERCNT|awk '{ printf "%-33s %10s%10s%10s%6s %-26s\n",
$1, $2, $3, $4, $5, $6}'
COUNT=0 unset LVOL2 else echo $LVOL $SIZE $USED $FREE $PERCNT $MOUNT|awk '{ printf "%-33s %10s%10s%10s%6s %-26s\n",
if [ -z "$1" ] ; then
/usr/bin/bdf|while read LVOL SIZE USED FREE PERCNT MOUNT ; do
bdfit
done
else
echo Filesystem kbytes used avail %used Mounted |awk '{ printf "%-33s %10s%10s%10s%6s %-26s\n",
$1, $2, $3, $4, $5, $6}'
for FILESYS in $* ; do
/usr/bin/bdf $FILESYS|grep -v Filesystem|while read LVOL SIZE USED FREE PERCNT MOUNT ; do
bdfit
done
done
fi
#
-- Please see the official ORACLE-L FAQ: http://www.orafaq.net -- Author: Kirtikumar Deshpande INET: kirtikumar_deshpande_at_yahoo.com Fat City Network Services -- 858-538-5051 http://www.fatcity.com San Diego, California -- Mailing list and web hosting services --------------------------------------------------------------------- To REMOVE yourself from this mailing list, send an E-Mail message to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing).Received on Tue Oct 07 2003 - 19:19:25 CDT
![]() |
![]() |