HP3000-L Archives

March 2000, Week 5

HP3000-L@RAVEN.UTC.EDU

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
Michael Anderson <[log in to unmask]>
Reply To:
Michael Anderson <[log in to unmask]>
Date:
Wed, 29 Mar 2000 15:14:20 -0600
Content-Type:
text/plain
Parts/Attachments:
text/plain (54 lines)
I got this from someone on the list years ago, and would like to know who. It's not HTML, but is somewhat graphical, and makes use of AWK.



USER DEFINED COMMAND FILE:  DFX.UTIL.SYS

parm format=e
if ups('!format')='Z'
   discfree c >df1
   /SYS/HPBIN/AWK "-f /SYS/UTIL/DFAWK" <df1
   purge df1,temp
else
   discfree !format
endif
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
USER DEFINED COMMAND FILE:  DFAWK.UTIL.SYS

BEGIN {print "dev size utilization"}
   # ldev 11 is a cd-rom on our system, not relevant for discfree
   /^LDEV/ {d=$3; if(d!=11)printf("%3s ",$3)}
   /^ Device/ && d!=11 && !t {
   printf("%5.1fG ",$3/4/1024/1024);
   for(i=0;i<$5/$3*60;i++) printf("*");
   for(i=0;i<($3-$5)/$3*60;i++) printf(".");
   printf(" %3d%%\n",$5/$3*100);
   tc+=$3;
   tu+=$5;
   }
   /^TOTALS/ {
   t=1;
   printf("\nall %5.1fG ",tc/4/1024/1024);
   for(i=0;i<tu/tc*60;i++) printf("*");
   for(i=0;i<(tc-tu)/tc*60;i++) printf(".");
   printf(" %3d%%\n\n",tu/tc*100);
   }
:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

The output looks something like:

 dfx z
dev size utilization
  1   4.0G ******************************************...................  69%
  2   8.5G ***********************************************..............  78%
  3   8.5G ************************************************.............  79%

all  21.0G ***********************************************..............  76%



>>> Jeff Mikolai <[log in to unmask]> 03/29 1:06 PM >>>
Before I venture into writing this does anyone have anything that takes a
discfree and converts it into pretty html?

ATOM RSS1 RSS2