[collectd] How can I determine network interface status? (up/down)

Николай Кучумов kuchumovn at gmail.com
Fri Apr 18 17:29:45 CEST 2014


Thanks bill, it was.
We have a software that needs to monitor itself, i.e. the server.
We chose collectd as we found no other sane alternatives.
We managed to get hdd stats, ram stats, network stats and cpu stats, but
what is left is interface status.
We don't need nagios, this is a requirement for collectd.
I found a way though: to read the /sys/class/net/eth0/carrier file: 1 for
up, 0 for down (i suppose).
Another issue i've faced is that the "tail" plugin (for reading files)
doesn't work - it always returns "null".
Maybe I'll find yet another plugin, maybe it'll be the "Exec" plugin and
"cat /sys/class/net/eth0/carrier" script.


2014-04-18 19:02 GMT+04:00 bill <bilsch at gmail.com>:

> I think what the question was really about was monitoring. not just metrics
>
> the use if metrics in an overall monitoring solution is important.
> collectd itself I view more as a metrics collection framework
>
> what is really needed as part of the answer is that collectd itself is not
> an alerting framework. eg they need I look at something like nagios.
> getting nagios checks to do threshold checks against historical metrics (
> say link errors in the last 30 seconds ) is very helpful
>
> collectd itself does not necessarily know not care about individual link
> state
>
> original requester - hope that helps. was that really more your
> question/direction?
>
>
> Bill Schwanitz
>
> If A is a success in life, then A equals x plus y plus z. Work is x; y is
> play; and z is keeping your mouth shut. - Albert Einstein.
>
> > On Apr 18, 2014, at 10:21 AM, "G.W. Haywood" <
> collectd at jubileegroup.co.uk> wrote:
> >
> > B0;278;0cHi there,
> >
> >> On Fri, 18 Apr 2014, (??????? ???????) wrote:
> >>
> >> How can I determine network interface status? (up/down)
> >
> > man ip
> > man ifconfig
> >
> > --
> >
> > 73,
> > Ged.
> >
> > _______________________________________________
> > collectd mailing list
> > collectd at verplant.org
> > http://mailman.verplant.org/listinfo/collectd
>
> _______________________________________________
> collectd mailing list
> collectd at verplant.org
> http://mailman.verplant.org/listinfo/collectd
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.verplant.org/pipermail/collectd/attachments/20140418/9988f220/attachment.html>


More information about the collectd mailing list