On Wed, Mar 16, 2011, at 09:42:30AM GMT+01:00, Morten Brekkevold wrote:
We had similar issues with Cisco devices before NAV 3.6. For Cisco devices we used their ifDescr value as interface names; a typical value would be "GigabitEthernet3/2", which is way too long for the port matrix in ipdevinfo (today we use the ifName value always, which in the Cisco case would be "Gi3/2").
Before NAV 3.6, ipdevinfo had some shortening logic especially for Cisco interfaces names, which knew how to shorten "GigabitEthernet3/2" into "Gi3/2".
I might imagine some sort of generic algorithm for shortening interface names if they happen to exceed some maximum length. Something that might work in this case is to pick the rightmost word containing any digits. Wouldn't work nicely for GigabitEthernet3/2, though.
Any idea what the ifDescr values look like on this device (snmpwalk ifDescr)?
It doesn't have ifName at all, so I guess NAV falls back to use ifDescr?
root@nav:~# snmpwalk -v 2c -c public sw-mgmt-cr2-x02 ifDescr IF-MIB::ifDescr.1 = STRING: FSM726 Management Switch 10/100 Mbps Ethernet Network Interface 1 [...] IF-MIB::ifDescr.24 = STRING: FSM726 Management Switch 10/100 Mbps Ethernet Network Interface 24 IF-MIB::ifDescr.25 = STRING: FSM726 Management Switch 1000 Mbps Ethernet Network Interface 25 IF-MIB::ifDescr.26 = STRING: FSM726 Management Switch 1000 Mbps Ethernet Network Interface 26 IF-MIB::ifDescr.27 = STRING: FSM726 Management Switch CPU Ethernet Network Interface
It would be hard to filter this out on a general basis, I guess, unless one use the ifIndex in conjunction with ifDescr.