monitoring aggregated network traffic
Hi,
thanks for your very helpful answer. It took me a few days to get back to that issue, so sorry for that late responose.
I've added additional lines for outgoing, and it works as expected.
I'm absolutely fine with hardcoed interfaces, cause I need the aggregated view of particular interfaces.
Thanks again,
Stephan
Am Donnerstag, den 13.10.2011, 19:42 +0200 schrieb Henrik Størner:
On 13-10-2011 16:44, netz-haut - stephan seitz wrote:
> is there any "usual" way, to monitor and graph the traffic of a bulk
> of network interfaces? The reason is, some of our hosts are connected
> to iSCSI storages via multipath over two or four independent
> interfaces. Since the traffic is balanced equally, every interface
> shows (more or less) the same amount of traffic. This leads to very
> useless rrdtool graphics as there is only one multicolored thick line
> visible. It would be really helpful to see a graph which shows the
> SUM of the particular interfaces.
This can be done by creating an RRD graph definition to do the summation
for you.
In RRDtool, you first use one or more "DEF" lines to grab specific data
items from one or more RRD files, and put them into some "variables".
You can then either use these variables directly to make a line on the
graph, or you can use them for calculating other variables via a "CDEF"
line.
The default ifstat graph has these lines:
DEF:inbytes at RRDIDX@=@RRDFN@:bytesReceived:AVERAGE
CDEF:in at RRDIDX@=inbytes at RRDIDX@,8,*
(The @RRDIDX@ and @RRDFN@ are because this graph repeats over all the
interfaces - Xymon replaces these with a number and the RRD filename).
What this does is to first define a variable "inbytes at RRDIDX@" which has
the "bytesReceived" value from the RRD. The it computes another
variable, "in at RRDIDX@" as 8*inbytes - to convert from bytes to bits.
The notation here is Reverse Polish (RPN).
So if you have 4 RRD files, one for each interface, you can have RRDtool
do the math for you like this:
[ifsum]
TITLE Network Traffic
YAXIS Bits/second
DEF:inbytes0=ifstat.eth0.rrd:bytesReceived:AVERAGE
DEF:inbytes1=ifstat.eth1.rrd:bytesReceived:AVERAGE
DEF:inbytes2=ifstat.eth2.rrd:bytesReceived:AVERAGE
DEF:inbytes3=ifstat.eth3.rrd:bytesReceived:AVERAGE
CDEF:intotal=inbytes0,inbytes1,inbytes2,inbytes3,+,+,+
CDEF:inbits=intotal,8,*
LINE:inbits#FF0000:Aggregate inbound
The "LINE" definition then uses the "inbits" value to draw a (red) line
with this data.
Have a look at graphs.cfg, and I'm sure you can figure out to add a line
for the outgoing data also.
Add "ifsum" to the GRAPHS setting in xymonserver.cfg, and the graph
should show up on the "trends" page.
Regards,
Henrik
PS: I haven't actually tested any of this, so feel free to provide
corrections :-)
_______________________________________________
Xymon mailing list
Xymon at xymon.com
http://lists.xymon.com/mailman/listinfo/xymon
On Sun, 30 Oct 2011, netz-haut - stephan seitz wrote:
Hi,
thanks for your very helpful answer. It took me a few days to get back to that issue, so sorry for that late responose.
I've added additional lines for outgoing, and it works as expected.
I'm absolutely fine with hardcoed interfaces, cause I need the aggregated view of particular interfaces.
Thanks again,
Stephan
Am Donnerstag, den 13.10.2011, 19:42 +0200 schrieb Henrik Størner:
On 13-10-2011 16:44, netz-haut - stephan seitz wrote:
is there any "usual" way, to monitor and graph the traffic of a bulk of network interfaces? The reason is, some of our hosts are connected to iSCSI storages via multipath over two or four independent interfaces. Since the traffic is balanced equally, every interface shows (more or less) the same amount of traffic. This leads to very useless rrdtool graphics as there is only one multicolored thick line visible. It would be really helpful to see a graph which shows the SUM of the particular interfaces.
This can be done by creating an RRD graph definition to do the summation for you.
In RRDtool, you first use one or more "DEF" lines to grab specific data items from one or more RRD files, and put them into some "variables". You can then either use these variables directly to make a line on the graph, or you can use them for calculating other variables via a "CDEF" line.
The default ifstat graph has these lines:
DEF:inbytes at RRDIDX@=@RRDFN@:bytesReceived:AVERAGE CDEF:in at RRDIDX@=inbytes at RRDIDX@,8,*(The @RRDIDX@ and @RRDFN@ are because this graph repeats over all the interfaces - Xymon replaces these with a number and the RRD filename).
What this does is to first define a variable "inbytes at RRDIDX@" which has the "bytesReceived" value from the RRD. The it computes another variable, "in at RRDIDX@" as 8*inbytes - to convert from bytes to bits. The notation here is Reverse Polish (RPN).
So if you have 4 RRD files, one for each interface, you can have RRDtool do the math for you like this:
[ifsum] TITLE Network Traffic YAXIS Bits/second DEF:inbytes0=ifstat.eth0.rrd:bytesReceived:AVERAGE DEF:inbytes1=ifstat.eth1.rrd:bytesReceived:AVERAGE DEF:inbytes2=ifstat.eth2.rrd:bytesReceived:AVERAGE DEF:inbytes3=ifstat.eth3.rrd:bytesReceived:AVERAGE CDEF:intotal=inbytes0,inbytes1,inbytes2,inbytes3,+,+,+ CDEF:inbits=intotal,8,* LINE:inbits#FF0000:Aggregate inbound
The "LINE" definition then uses the "inbits" value to draw a (red) line with this data.
Have a look at graphs.cfg, and I'm sure you can figure out to add a line for the outgoing data also.
Add "ifsum" to the GRAPHS setting in xymonserver.cfg, and the graph should show up on the "trends" page.
Regards, Henrik
PS: I haven't actually tested any of this, so feel free to provide corrections :-)
Hi !
I knew, this thread is very old, but i want this feature very much :)
.. unfortunately something is missing in my enviroment, because i couldn't see the ifsum-graph on the trend-page ... :-(
Can somebody give me an advice how i debug this missing graph ?
My xmon-server is running the 4.3.7-version ..
thanks & cheers,
Martin
On Sun, 30 Oct 2011, netz-haut - stephan seitz wrote:
Hi,
thanks for your very helpful answer. It took me a few days to get back to that issue, so sorry for that late responose.
I've added additional lines for outgoing, and it works as expected.
I'm absolutely fine with hardcoed interfaces, cause I need the aggregated view of particular interfaces.
Thanks again,
Stephan
Am Donnerstag, den 13.10.2011, 19:42 +0200 schrieb Henrik Størner:
On 13-10-2011 16:44, netz-haut - stephan seitz wrote:
is there any "usual" way, to monitor and graph the traffic of a bulk of network interfaces? The reason is, some of our hosts are connected to iSCSI storages via multipath over two or four independent interfaces. Since the traffic is balanced equally, every interface shows (more or less) the same amount of traffic. This leads to very useless rrdtool graphics as there is only one multicolored thick line visible. It would be really helpful to see a graph which shows the SUM of the particular interfaces.
This can be done by creating an RRD graph definition to do the summation for you.
In RRDtool, you first use one or more "DEF" lines to grab specific data items from one or more RRD files, and put them into some "variables". You can then either use these variables directly to make a line on the graph, or you can use them for calculating other variables via a "CDEF" line.
The default ifstat graph has these lines:
DEF:inbytes at RRDIDX@=@RRDFN@:bytesReceived:AVERAGE CDEF:in at RRDIDX@=inbytes at RRDIDX@,8,*(The @RRDIDX@ and @RRDFN@ are because this graph repeats over all the interfaces - Xymon replaces these with a number and the RRD filename).
What this does is to first define a variable "inbytes at RRDIDX@" which has the "bytesReceived" value from the RRD. The it computes another variable, "in at RRDIDX@" as 8*inbytes - to convert from bytes to bits. The notation here is Reverse Polish (RPN).
So if you have 4 RRD files, one for each interface, you can have RRDtool do the math for you like this:
[ifsum] TITLE Network Traffic YAXIS Bits/second DEF:inbytes0=ifstat.eth0.rrd:bytesReceived:AVERAGE DEF:inbytes1=ifstat.eth1.rrd:bytesReceived:AVERAGE DEF:inbytes2=ifstat.eth2.rrd:bytesReceived:AVERAGE DEF:inbytes3=ifstat.eth3.rrd:bytesReceived:AVERAGE CDEF:intotal=inbytes0,inbytes1,inbytes2,inbytes3,+,+,+ CDEF:inbits=intotal,8,* LINE:inbits#FF0000:Aggregate inbound
The "LINE" definition then uses the "inbits" value to draw a (red) line with this data.
Have a look at graphs.cfg, and I'm sure you can figure out to add a line for the outgoing data also.
Add "ifsum" to the GRAPHS setting in xymonserver.cfg, and the graph should show up on the "trends" page.
Regards, Henrik
PS: I haven't actually tested any of this, so feel free to provide corrections :-)
Hi !
I knew, this thread is very old, but i want this feature very much :)
.. unfortunately something is missing in my enviroment, because i couldn't see the ifsum-graph on the trend-page ... :-(
Can somebody give me an advice how i debug this missing graph ?
My xmon-server is running the 4.3.7-version ..
thanks & cheers,
Martin
Ok, correction ... I can't see the ifsum-graph on the default trend-page, but if i take on graph of the trend-page and change the service=ports to service=ifsum
from https://xymon.desy.de/xymon-cgi/showgraph.sh?host=oracle1&service=ports&grap... to https://xymon.desy.de/xymon-cgi/showgraph.sh?host=oracle1&service=ifsum&grap...
then i got the graph :-)
But how can i display this on the default trend-page ?
thanks martin
On Thu, Feb 16, 2012 at 6:53 AM, Martin Flemming <martin.flemming at desy.de> wrote:
Ok, correction ... I can't see the ifsum-graph on the default trend-page, but if i take on graph of the trend-page and change the service=ports to service=ifsum then i got the graph :-)
But how can i display this on the default trend-page ?
From the "how to setup custom graphs" page:
"If you want the graph included with the other graphs on the trends column, you must add it to the GRAPHS setting in the ~xymon/server/etc/xymonserver.cfg file."
So in your case, add ",ifsum" to your GRAPHS setting and then reload the trends page.
Cheers Jeremy
On Thu, 16 Feb 2012, Jeremy Laidman wrote:
On Thu, Feb 16, 2012 at 6:53 AM, Martin Flemming <martin.flemming at desy.de> wrote:
Ok, correction ... I can't see the ifsum-graph on the default trend-page, but if i take on graph of the trend-page and change the service=ports to service=ifsum then i got the graph :-)
But how can i display this on the default trend-page ?
From the "how to setup custom graphs" page:
"If you want the graph included with the other graphs on the trends column, you must add it to the GRAPHS setting in the ~xymon/server/etc/xymonserver.cfg file."
So in your case, add ",ifsum" to your GRAPHS setting and then reload the trends page.
Yes, added ifsum to the GRAPHS settings and restart was done .. but nothing was to display :-(
i've add behind the hostname TRENDS:*,ifsum but also without success :-(
Now i've found this thread and the solution :-)
http://lists.xymon.com/pipermail/xymon/2011-December/033323.html
I've had to make an touch ifsum.rrd and voila, the graph will be display :-)
Is that an bug ?
thanks & cheers,
martin
On Thu, Feb 16, 2012 at 6:26 PM, Martin Flemming <martin.flemming at desy.de> wrote:
Now i've found this thread and the solution :-)
http://lists.xymon.com/pipermail/xymon/2011-December/033323.html
I remember that thread now, but I didn't understand quite what was going on. I've recently been trying to solve a different problem related to the same bit of code.
I've had to make an touch ifsum.rrd and voila, the graph will be display
Is that an bug ?
Probably not really a bug. It's just that the code that generates the trends page was not (it seems) designed to handle graphs where the graph name doesn't match the RRD filename. It probably needs enhancements to incorporate this as a feature.
The code also looks at FNPATTERN in the graph definition to tell the code which filename to look at, and while it is probably not intended for use with fixed filenames like you're using, it might still work, without having to create a dummy file.
Cheers Jeremy
On Fri, 17 Feb 2012, Jeremy Laidman wrote:
On Thu, Feb 16, 2012 at 6:26 PM, Martin Flemming <martin.flemming at desy.de> wrote:
Now i've found this thread and the solution :-)
http://lists.xymon.com/pipermail/xymon/2011-December/033323.html
I remember that thread now, but I didn't understand quite what was going on. I've recently been trying to solve a different problem related to the same bit of code.
I've had to make an touch ifsum.rrd and voila, the graph will be display
Is that an bug ?
Probably not really a bug. It's just that the code that generates the trends page was not (it seems) designed to handle graphs where the graph name doesn't match the RRD filename. It probably needs enhancements to incorporate this as a feature.
The code also looks at FNPATTERN in the graph definition to tell the code which filename to look at, and while it is probably not intended for use with fixed filenames like you're using, it might still work, without having to create a dummy file.
Hmmmm, ok before i start another thread to the similar problem, i want to ask how i could solve this problem whith FNPATTERN ?
in my situation
[ifsum] TITLE Network Traffic YAXIS Bits/second DEF:inbytes0=ifstat.eth0.rrd:bytesReceived:AVERAGE DEF:inbytes1=ifstat.eth1.rrd:bytesReceived:AVERAGE DEF:inbytes2=ifstat.eth2.rrd:bytesReceived:AVERAGE DEF:inbytes3=ifstat.eth3.rrd:bytesReceived:AVERAGE CDEF:intotal=inbytes0,inbytes1,inbytes2,inbytes3,+,+,+ CDEF:inbits=intotal,8,* LINE:inbits#FF0000:Aggregate inbound
[ifsum] FNPATTERN ifstat(.+).rrd TITLE Network Traffic YAXIS Bits/second DEF:inbytes at RRDIDX@=@RRDFN@:bytesReceived:AVERAGE . . .
???
thanks in advance
martin
On Fri, Feb 24, 2012 at 9:12 AM, Martin Flemming <martin.flemming at desy.de> wrote:
Hmmmm, ok before i start another thread to the similar problem, i want to ask how i could solve this problem whith FNPATTERN ?
I don't think you can. If you use @RRDIDX@ type DEFs, you can't use non- at RRDIDX@ DEFs. So there's no way to dynamically add all instances of an indexed value into a single non-indexed value.
It seems you either need to live without the "total" on your graph, or you need to explicitly define every DEF.
J
participants (3)
-
jlaidman@rebel-it.com.au
-
martin.flemming@desy.de
-
s.seitz@netz-haut.de