<div dir="ltr"><div class="gmail_extra">On 25 June 2013 07:03, B-Art Gillis <span dir="ltr"><<a href="mailto:bacaselo@gmail.com" target="_blank">bacaselo@gmail.com</a>></span> wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">

Thank you for your answer but I just saw on the graph that the values are converted to rrd data seem to come from the "do_netstat.c" module.</blockquote></div><br>No, if you want interface statistics then you want ifstat parsed in do_ifstat.c.  If you want protocol statistics (layer 3 and above such as TCP and UDP) then you would want a [netstat] section parsed in do_netstat.c.  The message example you gave shows interface statistics.</div>

<div class="gmail_extra"><br></div><div class="gmail_extra">Xymon expects the format to match ifstat_bbwin_exprs[] (defined in do_ifstat.c). This includes an IP address then the in and out byte count.  The output of "netstat -e" does not provide an IP address, and it provides much more than just the bytes in and out.  You'd have to select the Bytes line and prefix it with an IP address (probably a dummy device name would do also).</div>

<div class="gmail_extra"><br></div><div class="gmail_extra">Something like:</div><div class="gmail_extra"><br></div><div class="gmail_extra">EthDev 144681781 42531845</div><div class="gmail_extra"><br></div><div class="gmail_extra">

Any whitespace can be used as separators (one or more tabs or spaces).</div><div class="gmail_extra"><br></div><div class="gmail_extra">You could probably get away with this:</div><div class="gmail_extra"><br></div><div class="gmail_extra">

echo [netstat] & netstat -e | find "Bytes"</div><div class="gmail_extra"><br></div><div class="gmail_extra">This would give "Bytes" as a devicename, but I don't think it would break anything.</div>

<div class="gmail_extra"><br></div><div class="gmail_extra">You need to prefix this message with the correct "client" message header.  If you're sending other client data, this should be included with that message, otherwise one will mask the other.</div>

<div class="gmail_extra"><br></div><div class="gmail_extra">The client message might look something like this:</div><div class="gmail_extra"><br></div><div class="gmail_extra">client server1.win32</div><div class="gmail_extra">

[netstat]</div><div class="gmail_extra">Bytes      144681781        42531845</div><div class="gmail_extra"><br></div><div class="gmail_extra">To get Xymon to match against the bbwin match string, you have to report your OS in the message as "bbwin" or "win32".  This is probably why you're getting the "reports netstat for an unknown OS" message.</div>

<div class="gmail_extra"><br></div><div class="gmail_extra">J</div><div class="gmail_extra"><br></div></div>