[c-nsp] snmpwalk for switch port status

sky vader aptgetd at gmail.com
Tue Nov 17 15:46:42 EST 2009


Hi,

Can anyone point me in right direction for a perl script that will
snmpwalk the MIB for switch port status whether "up" or "down" including
total number of ports available?

I have approximately 400 switches that I would like to query via script
and pipe the results to a file for every device.

I'm currently querying it manually (see below) which is not scaling :-)

$ snmpwalk -c <community> <host_ip>
interfaces.ifTable.ifEntry.ifOperStatus | grep down


Any pointers will be greatly appreciated.


regards
sky



More information about the cisco-nsp mailing list