How to if_* graph from Devmon to Hobbit
list Xbgmsharp
How to if_* graph from Devmon to Hobbit
This mail describe how to graph all if_* data from Devmon to Hobbit.
I am currently running hobbit 4.2.0/all-in-one patch and devmon 0.3-beta2
1)
First you need a curently working hobbit and devmon.
2)
Then make sure, than the file devmon/templates/modele/if_load/message
TABLE:rrd()
This will show data in a htmltable and add rrd information in the status page.
In order to check, you should see RRD data information in the status
page of the service corresponding to your devmon modele when showing
source html.
3)
Now make parse the data to create a rrd file (one par interfaces),
this is done via extra-rrd.pl.
In etc/hobbitlaunch.cfg
[rrdstatus]
ENVFILE /data/hobbit/server/etc/hobbitserver.cfg
NEEDS hobbitd
CMD hobbitd_channel --channel=status \
--log=$BBSERVERLOGS/rrd-status.log hobbitd_rrd \
--rrddir=$BBVAR/rrd \
--extra-script=$BBHOME/ext/extra-rrd.pl \
--extra-tests=if_load
In ext/extra-rrd.pl
if ( $TESTNAME eq "if_load" ) {
# Analyze the message we got
foreach $line (@input) {
if ($line =~ /(^[A-Z].*) (\d+):(\d+)$/ ) {
# The RRD dataset definitions
print "DS:in:DERIVE:600:0:U\n";
print "DS:out:DERIVE:600:0:U\n";
# The filename
print "if_load_$1.rrd\n";
# The data
print "$2:$3\n";
}
}
}
4)
Modify etc/hobbitgraph.cfg
[if_load]
FNPATTERN if_load(.*).rrd
TITLE Network Traffic
YAXIS Bits/second
DEF:in at RRDIDX@=@RRDFN@:in:AVERAGE
CDEF:inbytes at RRDIDX@=in at RRDIDX@,8,*
DEF:out at RRDIDX@=@RRDFN@:out:AVERAGE
CDEF:outbytes at RRDIDX@=out at RRDIDX@,8,*
LINE1:inbytes at RRDIDX@#@COLOR@:@RRDPARAM@ In
GPRINT:inbytes at RRDIDX@:LAST: %8.2lf %s (cur)
GPRINT:inbytes at RRDIDX@:MAX: %8.2lf %s (max)
GPRINT:inbytes at RRDIDX@:MIN: %8.2lf %s (min)
GPRINT:inbytes at RRDIDX@:AVERAGE: %8.2lf %s (avg)\n
LINE1:outbytes at RRDIDX@#@COLOR@:@RRDPARAM@ Out
GPRINT:outbytes at RRDIDX@:LAST: %8.2lf %s (cur)
GPRINT:outbytes at RRDIDX@:MAX: %8.2lf %s (max)
GPRINT:outbytes at RRDIDX@:MIN: %8.2lf %s (avg)
GPRINT:outbytes at RRDIDX@:AVERAGE: %8.2lf %s (avg)\n
4)
In etc/hobbitserver.cfg
Modify the following.
See help/howtograph.html
TEST2RRD="cpu=la,disk,...,if_load"
GRAPHS="la,disk,if_load::1"
The ::1 set the maxcount in order to make one graph form each rrd file create.
5)
In etc/hobbitcgi.cfg
Modify the following.
See hobbitsvc.cgi man
CGI_SVC_OPTS="--env=/data/hobbit/server/etc/hobbitserver.cfg
--no-svcid --history=top --multi-grahs=if_load,if_err..."
6)
The hardest part.
The hobbit parsing doesn't remove html table table so you will see
many graph link.
In order to fix than, you need to modify the hobbit source with the patch:
lib/htmllog.c
$cd lib/
$patch -p0 < htmllog.path
Here is the path, this only set a new counter for all if_* services.
This is allready working for the trends colunms because, it is
checking all rrd file in the directory.
Henrik, do you have any tips to get the nice counter without editing
the source code of htmllog.c file ?
That's all folks.
list Trent Melcher
Where do you get this extra-rrd.pl script from to add these changes? Thanks Trent Melcher
▸
On Fri, 2007-07-13 at 11:58 +0200, xbgmsharp wrote:How to if_* graph from Devmon to Hobbit
This mail describe how to graph all if_* data from Devmon to Hobbit.
I am currently running hobbit 4.2.0/all-in-one patch and devmon 0.3-beta2
1)
First you need a curently working hobbit and devmon.
2)
Then make sure, than the file devmon/templates/modele/if_load/message
TABLE:rrd()
This will show data in a htmltable and add rrd information in the status page.
In order to check, you should see RRD data information in the status
page of the service corresponding to your devmon modele when showing
source html.
3)
Now make parse the data to create a rrd file (one par interfaces),
this is done via extra-rrd.pl.
In etc/hobbitlaunch.cfg
[rrdstatus]
ENVFILE /data/hobbit/server/etc/hobbitserver.cfg
NEEDS hobbitd
CMD hobbitd_channel --channel=status \
--log=$BBSERVERLOGS/rrd-status.log hobbitd_rrd \
--rrddir=$BBVAR/rrd \
--extra-script=$BBHOME/ext/extra-rrd.pl \
--extra-tests=if_load
In ext/extra-rrd.pl
if ( $TESTNAME eq "if_load" ) {
# Analyze the message we got
foreach $line (@input) {
if ($line =~ /(^[A-Z].*) (\d+):(\d+)$/ ) {
# The RRD dataset definitions
print "DS:in:DERIVE:600:0:U\n";
print "DS:out:DERIVE:600:0:U\n";
# The filename
print "if_load_$1.rrd\n";
# The data
print "$2:$3\n";
}
}
}
4)
Modify etc/hobbitgraph.cfg
[if_load]
FNPATTERN if_load(.*).rrd
TITLE Network Traffic
YAXIS Bits/second
DEF:in at RRDIDX@=@RRDFN@:in:AVERAGE
CDEF:inbytes at RRDIDX@=in at RRDIDX@,8,*
DEF:out at RRDIDX@=@RRDFN@:out:AVERAGE
CDEF:outbytes at RRDIDX@=out at RRDIDX@,8,*
LINE1:inbytes at RRDIDX@#@COLOR@:@RRDPARAM@ In
GPRINT:inbytes at RRDIDX@:LAST: %8.2lf %s (cur)
GPRINT:inbytes at RRDIDX@:MAX: %8.2lf %s (max)
GPRINT:inbytes at RRDIDX@:MIN: %8.2lf %s (min)
GPRINT:inbytes at RRDIDX@:AVERAGE: %8.2lf %s (avg)\n
LINE1:outbytes at RRDIDX@#@COLOR@:@RRDPARAM@ Out
GPRINT:outbytes at RRDIDX@:LAST: %8.2lf %s (cur)
GPRINT:outbytes at RRDIDX@:MAX: %8.2lf %s (max)
GPRINT:outbytes at RRDIDX@:MIN: %8.2lf %s (avg)
GPRINT:outbytes at RRDIDX@:AVERAGE: %8.2lf %s (avg)\n
4)
In etc/hobbitserver.cfg
Modify the following.
See help/howtograph.html
TEST2RRD="cpu=la,disk,...,if_load"
GRAPHS="la,disk,if_load::1"
The ::1 set the maxcount in order to make one graph form each rrd file create.
5)
In etc/hobbitcgi.cfg
Modify the following.
See hobbitsvc.cgi man
CGI_SVC_OPTS="--env=/data/hobbit/server/etc/hobbitserver.cfg
--no-svcid --history=top --multi-grahs=if_load,if_err..."
6)
The hardest part.
The hobbit parsing doesn't remove html table table so you will see
many graph link.
In order to fix than, you need to modify the hobbit source with the patch:
lib/htmllog.c
$cd lib/
$patch -p0 < htmllog.path
Here is the path, this only set a new counter for all if_* services.
This is allready working for the trends colunms because, it is
checking all rrd file in the directory.
Henrik, do you have any tips to get the nice counter without editing
the source code of htmllog.c file ?
That's all folks.
list Uma Bandi
Hi I am new to hobbit, here already hobbit server is running, just now I configured hobbit client on Linux it is running, is there any thing I need to configure on server side please guide Thanks Uma Maheswar
list Rich Smrcina
Only if you wish to modify any of the default thresholds. The hobbit-clients.cfg file on the server contains info on what can be set on the server to monitor client thresholds. Changes take effect immediately (but may be delayed up to 10 minutes).
▸
Bandi, Uma (GE Indust, Plastics, consultant) wrote:Hi I am new to hobbit, here already hobbit server is running, just now I configured hobbit client on Linux it is running, is there any thing I need to configure on server side please guide Thanks Uma Maheswar
--
Rich Smrcina VM Assist, Inc. Phone: XXX-XXX-XXXX Ans Service: XXX-XXX-XXXX user-61add9955ef9@xymon.invalid http://www.linkedin.com/in/richsmrcina Catch the WAVV! http://www.wavv.org WAVV 2008 - Chattanooga - April 18-22, 2008
list Joshua Krause
I have followed this page I found on how to integrate graphs from devmon into hobbit. But i am getting lost on one of the steps.
▸
6)The hardest part. The hobbit parsing doesn't remove html table table so you will see many graph link. In order to fix than, you need to modify the hobbit source with the patch: lib/htmllog.c $cd lib/ $patch -p0 < htmllog.path
Can anyone help?