Gathering statistics on disk usage

2005-10-15 Thread Josh Paetzel
I am trying to set up mrtg to graph disk usage.  I've tried using the 
output of iostat to provide me with usage in MB/s.  The problem with 
this is that moving data from disk to disk on the system causes the 
usage to jump to around 30MB/s.  Even with mrtg configured to draw 
the graphs logarithmically they basically blow up and the normal 
transfers are not really visable.  systat -vm gives statistics on 
disk usage  with a percent busy field.  This stat would be easier to 
graph and I would like to use it.  My problem is that I can't seem to 
extract the output of systat properly.  I've tried doing systat -vm | 
tail -n -1 and that doesn't work.  I've also tried systat -vm  
somefile.txt and that doesn't work.  There doesn't seem to be a way 
to get systat to run once and then quit either.

Can anyone think of a way to either capture systat's output or 
recommend a utility that will give me a % busy output?  I've tried 
iostat without success.
 
-- 
Thanks,

Josh Paetzel
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Gathering statistics on disk usage

2005-10-15 Thread Dan Nelson
In the last episode (Oct 15), Josh Paetzel said:
 I am trying to set up mrtg to graph disk usage.  I've tried using the
 output of iostat to provide me with usage in MB/s.  The problem with
 this is that moving data from disk to disk on the system causes the
 usage to jump to around 30MB/s.  Even with mrtg configured to draw
 the graphs logarithmically they basically blow up and the normal
 transfers are not really visable.  systat -vm gives statistics on
 disk usage with a percent busy field.  This stat would be easier to
 graph and I would like to use it.  My problem is that I can't seem to
 extract the output of systat properly.  I've tried doing systat -vm |
 tail -n -1 and that doesn't work.  I've also tried systat -vm 
 somefile.txt and that doesn't work.  There doesn't seem to be a way
 to get systat to run once and then quit either.
 
 Can anyone think of a way to either capture systat's output or
 recommend a utility that will give me a % busy output?  I've tried
 iostat without success.

If you apply the patch at
http://www.freebsd.org/cgi/query-pr.cgi?pr=bin/68840, you will be able
to get %busy stats out of iostat.

You can also try installing net-snmp and polling the diskIOLA5 value
for the disk, but on my system at least, the values don't seem to make
sense (I have seen numbers from -2546 to 3000).

-- 
Dan Nelson
[EMAIL PROTECTED]
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Gathering statistics on disk usage

2005-10-15 Thread Josh Paetzel
 If you apply the patch at
 http://www.freebsd.org/cgi/query-pr.cgi?pr=bin/68840, you will be
 able to get %busy stats out of iostat.


Thanks for your quick reply.  Unfortunately your patch does not apply 
cleanly to a 4.11-STABLE box.  I can supply iostat.c.rej if you want 
it.  I also tried it on a 5.4-RELENG-p7 box and it failed there as 
well.

-- 
Thanks,

Josh Paetzel
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Gathering statistics on disk usage

2005-10-15 Thread Dan Nelson
In the last episode (Oct 15), Josh Paetzel said:
  If you apply the patch at
  http://www.freebsd.org/cgi/query-pr.cgi?pr=bin/68840, you will be
  able to get %busy stats out of iostat.
 
 Thanks for your quick reply.  Unfortunately your patch does not apply
 cleanly to a 4.11-STABLE box.  I can supply iostat.c.rej if you want
 it.  I also tried it on a 5.4-RELENG-p7 box and it failed there as
 well.

It definitely should have applied cleanly on 5.4.  I just tested it.
Try downloading the Raw PR link at the bottom of the page; that will
remove any html-escaping.  The patch won't work on 4.x because the
devstat interface got overhauled between 4.x and 5.x.

-- 
Dan Nelson
[EMAIL PROTECTED]
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Gathering statistics on disk usage

2005-10-15 Thread Josh Paetzel
 It definitely should have applied cleanly on 5.4.  I just tested
 it. Try downloading the Raw PR link at the bottom of the page;
 that will remove any html-escaping.  The patch won't work on 4.x
 because the devstat interface got overhauled between 4.x and 5.x.

All right, I get the point hat for this one.  You're right, it works 
fine on 5.4 for me now.

-- 
Thanks,

Josh Paetzel
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]