[CentOS] SNMP oddity

Fri Mar 24 05:20:25 UTC 2017
Digimer <lists at alteeve.ca>

Hi all,

  Not sure if this is on topic or not.

  I'm trying to query an SNMP value from centos 6 and I get a bad
response if I don't specify the MIB to use:

  0 digimer at pulsar:~/anvil/striker$ snmpget -v2c -c public -m
/home/digimer/Downloads/APC/AP7900/MIB/powernet421.mib 10.255.2.1
.1.3.6.1.2.1.2.2.1.6.2
RFC1213-MIB::ifPhysAddress.2 = Hex-STRING: 00 C0 B7 5F 8A 85

  0 digimer at pulsar:~/anvil/striker$ snmpget -v2c -c public 10.255.2.1
.1.3.6.1.2.1.2.2.1.6.2
IF-MIB::ifPhysAddress.2 = STRING: 0:c0:b7:5f:8a:85

Note the second reply is not returning the first character (should be
'00:', returning '0:'.

Trying to request Hex doesn't seem to help, either:

  0 digimer at pulsar:~/anvil/striker$ snmpget -v2c -c public -Ox
10.255.2.1 .1.3.6.1.2.1.2.2.1.6.2
IF-MIB::ifPhysAddress.2 = STRING: 0:c0:b7:5f:8a:85

  Any SNMP folks know what I might be doing wrong?

Thanks!

-- 
Digimer
Papers and Projects: https://alteeve.com/w/
"I am, somehow, less interested in the weight and convolutions of
Einstein’s brain than in the near certainty that people of equal talent
have lived and died in cotton fields and sweatshops." - Stephen Jay Gould