home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #27 / NN_1992_27.iso / spool / comp / unix / admin / 6238 < prev    next >
Encoding:
Internet Message Format  |  1992-11-17  |  1.9 KB

  1. Path: sparky!uunet!destroyer!ncar!hsdndev!news.cs.umb.edu!rouilj
  2. From: rouilj@cs.umb.edu (John P. Rouillard)
  3. Newsgroups: comp.unix.admin
  4. Subject: Re: does anyone have a disk x% full capture program???
  5. Message-ID: <ROUILJ.92Nov17130357@ra.cs.umb.edu>
  6. Date: 17 Nov 92 18:03:57 GMT
  7. References: <fish.721343514@news2.gsfc.nasa.gov> <meskes.721482983@ulysses>
  8. Sender: news@cs.umb.edu (USENET News System)
  9. Organization: University of Massachusetts at Boston
  10. Lines: 37
  11. In-Reply-To: meskes@ulysses.informatik.rwth-aachen.de's message of 11 Nov 92 11: 56:23 GMT
  12. Nntp-Posting-Host: ra.cs.umb.edu
  13.  
  14.  
  15. Has anybody enhanced watcher to support LINE selection
  16. I.E. I would like something like (for a df command):
  17.  
  18.  LINE 1 header1%k
  19.  LINE 2 header2%k
  20.  LINE 3-0 1 disk%k 2 3 kbytes_used%d 4 kbytes_free%d 5 percent_used%d
  21.  
  22. for the following df output:
  23.  
  24.   Filesystem   Total    kbytes   kbytes   %     
  25.   node         kbytes   used     free     used  Mounted on
  26.   /dev/rz6h     494294  412044   32821    93%   /nfs/news
  27.  
  28. Line 1 and line 2 would be header files and would be reported in the
  29. watcher output. Lines 3 and on would be analyzed according to the
  30. template given. This would allow the removal of the tails and greps
  31. that I have to use now to filter the output of the commands.
  32.  
  33. Also allowing expressions in the spec of things to check would be very
  34. useful as well. Given the output of nfstat -c:
  35.  
  36.   Client rpc:
  37.   calls      badcalls   retrans    badxid     timeout    wait       newcred
  38.   4340       1          84         2          84         0          0          
  39.  
  40.   LINE 3 1 calls%d 2 badcalls%d 3 retrans%d 4 badxid%d 5 timeout%d :
  41.  
  42.      retrans/calls*100 0 1  # the percentage of retrans < 1%
  43.      badcalls/retrans*100 0 1 # same idea. 
  44.  
  45. Right now all of these numbers are being calculated using mawk, and
  46. perl. Needless to say this is causing the watcher program and the
  47. programs it runs to be influencing the load and other operations on
  48. the machine it is watching.
  49.  
  50. -- John
  51.