Admin Up/Down port using SNMP

Answered Question
Oct 29th, 2007
User Badges:

Hi,


Can anyone advise how to shutdown and no shutdown a port on a cisco switch using just SNMP?


I can't find much documentation on it.


Cheers,

Ben

Correct Answer by lgijssel about 9 years 8 months ago

You can use the standard MIB2 for this: http://www.alvestrand.no/objectid/1.3.6.1.2.1.html

and then check the options under "SNMP MIB-2 Interfaces" The IfStatus is somewhere in there.

Then, find an application that allows you to do snmp set instructions, such as SNMPchttp://www.castlerock.com/

and assign a write community string to your devices. After doing all this, it should work!


regards,

Leo

  • 1
  • 2
  • 3
  • 4
  • 5
Overall Rating: 4 (1 ratings)
Loading.
Correct Answer
lgijssel Mon, 10/29/2007 - 01:59
User Badges:
  • Red, 2250 points or more

You can use the standard MIB2 for this: http://www.alvestrand.no/objectid/1.3.6.1.2.1.html

and then check the options under "SNMP MIB-2 Interfaces" The IfStatus is somewhere in there.

Then, find an application that allows you to do snmp set instructions, such as SNMPchttp://www.castlerock.com/

and assign a write community string to your devices. After doing all this, it should work!


regards,

Leo

misd.network.support Fri, 11/02/2007 - 03:22
User Badges:

Thanks - the exact MIB is:


IF-MIB::ifAdminStatus


snmpset syntax is:


Interface UP:

snmpset -v1 -c community hostname IF-MIB::ifAdminStatus.interface i 1


Interface DOWN:

snmpset -v1 -c community hostname IF-MIB::ifAdminStatus.interface i 2


Hope this helps anyone else trying to do the same.


Cheers,

Ben

Actions

This Discussion