[mrtg] Can not determine ifNumber for public at gw

Brian J. Murrell brian at interlinx.bc.ca
Wed Mar 17 11:39:21 CET 2010


On Wed, 2010-03-17 at 17:25 +1300, Steve Shipway wrote: 
> 
> Yes.  MRTG has no way to uniquely identify which interface you want to graph.

The one (and only one) that's "up" of course.  :-)

> Many are called 'ppp0', many have type 23, the ppp interfaces have no MAC address, and so on.

Indeed.  But only one is up.

> This is a very odd state of affairs with multiple interfaces with the same name;

Indeed, it does seem odd.  But it's a net-snmp artifact only.  ifconfig
-a (or alternatively /proc/net/dev) only shows a single ppp0.  So maybe
I am barking up the wrong tree here and I should be bothering the
net-snmp folks about this.  Ahhh. but wait.  The only thing that has
changed here to cause the error messages on every run is an mrtg
upgrade.  The software on "gw" has been static for a while now.

Seems this indeed, has been around for a while:

http://www.mail-archive.com/net-snmp-users@lists.sourceforge.net/msg07474.html
http://www.mail-archive.com/net-snmp-coders@lists.sourceforge.net/msg05919.html

> also it appears the only 'up' interface is the last (number 85) so I assume this changes.

Yes, indeed it does.  Currently:

IF-MIB::ifAdminStatus.102 = INTEGER: up(1)

> You might like to review your ppp start/stop code as it seems to be creating a new interface ppp0 every time it restarts rather than closing down the old one,

Well, as I said, there is only in fact one interface.  It's just
net-snmp that is enumerating it a zillion times.

> I suspect a reboot will leave you with a single ppp0 interface again (after which it will work) but then the next restart of the interface might start spawning more copies...

Yes, I suspect so as well.

What I am thinking is that an option (or default even, perhaps) for mrtg
to report data on the "up" interface if more than 1 exists, would be
useful here.

b.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: This is a digitally signed message part
Url : http://lists.oetiker.ch/pipermail/mrtg/attachments/20100317/ade40c13/attachment.pgp 


More information about the mrtg mailing list