[mrtg] mrtg on OS X working / cpu usage?
Lozano_Art
Lozano_Art at lacoe.edu
Fri Nov 7 19:53:05 CET 2008
Hi,
I do not know about the disk usage, but this is what I use on FreeBSD. It is a config that calls an external perl script that takes the info from "uptime" and formats it for mrtg. I am sure you can adapt it to Max OSX.
#---------------------------------------------------------------
# CPU on FREEBSD
#---------------------------------------------------------------
Target[system_cpu]: `/usr/local/www/data/cpuusage.sh`
AbsMax[system_cpu]: 10000
MaxBytes[system_cpu]: 500
Options[system_cpu]: gauge,growright,nopercent
YLegend[system_cpu]: Percent CPU Load
ShortLegend[system_cpu]: .
Legend1[system_cpu]: CPU load in %
Legend2[system_cpu]: CPU load in %
Legend3[system_cpu]: Max Observed CPU load
Legend4[system_cpu]: Max Observed CPU load
LegendI[system_cpu]: CPU Load:
LegendO[system_cpu]:
Colours[system_cpu]: GREEN#00eb0c,BLUE#0000ff,GRAY#AAAAAA,VIOLET#ff00ff
WithPeak[system_cpu]: ymw
Title[system_cpu]: SYSTEM CPU Usage
PageTop[system_cpu]: <H1>SYSTEM CPU Usage</H1>
<TABLE>
<TR><TD>192.168.1.1 - SYSTEM 5 minute average CPU Load</TD></TR>
</TABLE>
#---------------------------------------------------------------
mrtg# cat cpuusage.sh
#!/usr/bin/perl
$load=`uptime`;
chop($load);
$load=~ /.averages:.+, (.+),.+/;
$la=$1*100;
print "$la\n"; #Load in a 5 minute average
print "0\n"; #Script running mrtg update
print "$load\n"; #Uptime
print "systemname.com\n"; #Hostname
Regards,
-Art
-----Original Message-----
From: mrtg-bounces at lists.oetiker.ch [mailto:mrtg-bounces at lists.oetiker.ch] On Behalf Of subs at mxr.at
Sent: Friday, November 07, 2008 4:51 AM
To: mrtg at lists.oetiker.ch
Subject: [mrtg] mrtg on OS X working / cpu usage?
Hi!
I finally managed to get mrtg working on my MAC OS 10.5 Server for my two
interfaces (en0,en1), now I am wondering if it is possible to monitor the
cpu usage / disk usage with mrtg?
I was googling for this, but did not find a guide for os x. Anyone knows
if this could be done and if how? :-)
Thanks in advance so much,
Chris
_______________________________________________
mrtg mailing list
mrtg at lists.oetiker.ch
https://lists.oetiker.ch/cgi-bin/listinfo/mrtg
More information about the mrtg
mailing list