6

I have a question about ifAdminStatus and ifOperStatus. Here is an output of my network interfaces state using ifAdminStatus:

snmpwalk -Os -c public -v 1 192.168.1.1 1.3.6.1.2.1.2.2.1.7ifAdminStatus.1 = INTEGER: up(1)

ifAdminStatus.12 = INTEGER: down(2)
ifAdminStatus.13 = INTEGER: up(1)
ifAdminStatus.14 = INTEGER: up(1)

And here is the same list using ifOperStatus:

snmpwalk -Os -c public -v 1 192.168.1.1 1.3.6.1.2.1.2.2.1.8

ifOperStatus.12 = INTEGER: down(2)
ifOperStatus.13 = INTEGER: down(2)
ifOperStatus.14 = INTEGER: down(2)

As you can see an ifAdminStatus reports that #13 and #14 are up but ifOperStatus reports them both down. I know for a fact that #13 is up and passing packets though it ( it's my PPPoE Internet connection interface). According to cisco documentation "If ifAdminStatus is down(2) then ifOperStatus should be down(2)." Which doesn't seems to be the case here...

My question is - why the reported statuses are different and is it safe to use just ifAdminStatus to tell if the interface is up and running instead of ifOperStatus?

thanks!

Here is snmpwalk with additional interfaces info:

snmpwalk -Os -c public -v 1 192.168.1.1 1.3.6.1.2.1.2.2.1
[.....]
ifIndex.12 = INTEGER: 12    
ifIndex.13 = INTEGER: 13
ifIndex.14 = INTEGER: 14
[.....]
ifDescr.12 = STRING: etherip0
ifDescr.13 = STRING: ppp0
ifDescr.14 = STRING: tun1
[.....]
ifType.12 = INTEGER: ethernetCsmacd(6)
ifType.13 = INTEGER: ppp(23)
ifType.14 = INTEGER: other(1)
Oliver Salzburg
  • 21,652
  • 20
  • 93
  • 138
PrimeSeventyThree
  • 940
  • 2
  • 9
  • 24
  • I am going out on a limb and betting your public IP was 67.204.0.214 when you took that snmpwalk capture. If so, that address is bound to ifIndex 16, but you dont have an interface in ifName for it. The most likely reason is you have a linksys and the just didnt code this kind of functionality into their SNMP agent. – Mike Pennington May 21 '12 at 13:17

1 Answers1

10

ifAdminStatus reveals whether the interface is enabled for operation

ifOperStatus reveals whether the interface has successfully formed a link.

The documentation you cited only asserts that ifAdminStatus=down means ifOperStatus=down. That much is true with ifIndex 12.

ifAdminStatus reports ifIndex 13 and 14 as up. Therefore, the guidance you quoted from Cisco's documentation doesn't apply. The operational status of those interfaces can still be down, even if they are enabled to operate. One simple case would be if no cable was plugged into them.

EDIT

The whole time I have been answering this question, I thought you had a Cisco router running IOS. Based on your snmpwalk, this is in fact a Linksys

sysDescr.0 = STRING: Linux Linksys E4200 2.6.24.111 #8614 
    Tue Dec 20 05:09:38 CET 2011 mips

Based on the evidence I have seen, you just cant monitor ifOperStatus for your PPPoE connection; they didnt code that much functionality into the SNMP agent on the Linksys.

Mike Pennington
  • 41,899
  • 19
  • 136
  • 174
  • thank you for the reply. as I've mentioned before #13 is definitely up - my Internet connection goes through this interface. and when ifAdminStatus reports that this interface is down I shouldn't have a connection to the Internet. Which is clearly not the case... – PrimeSeventyThree May 21 '12 at 01:21
  • How did you conclude that 13 is your PPPoE interface? Please post the walk of `ifName`; that would provide definitive information. `ifAdminStatus` is not sufficient, you should be monitoring `ifOperStatus`. – Mike Pennington May 21 '12 at 01:32
  • snmpwalk shows ifDescr.13 = STRING: ppp0 (I've updated my question with some additional info) – PrimeSeventyThree May 21 '12 at 02:59
  • If you are using a `dialer` interface, please include `ifName` and `ifOperStatus` information for that interface – Mike Pennington May 21 '12 at 03:19