Contents
SNMP Monitoring of the Switch 2
2. Configuring SNMPv3 in CLI 2
SNMP or Simple Network Management Protocol is a networking protocol designed for managing and monitoring network-connected devices in IP networks. The devices can be routers, switches, firewalls, gateways, servers, printers etc. All SNMP messages are transported via UDP (User Datagram Protocol). The SNMP agent receives requests on port 161.
SNMPv3 provides the following authentication possibilities.
● No authentication and no privacy (noAuthNoPriv) - used for monitoring
● Authentication and no privacy (authNoPriv) - used for control
● Authentication and privacy (authPriv) - used for downloading encrypted information
In CLI enter the following commands to enable SNMPv3 on the switch:
Switch>enable
(Note: You must enter into the privileged mode using the ‘enable’ command in case you are using the Telnet option to access the switch.)
Switch#configure terminal
Switch(config)#security-manage snmp enable
Switch(config)#snmp user <user_name(user-defined)> {ro | rw} auth {md5 | sha} <auth_password(user-defined)> priv des <priv_password(user-defined)>
Switch(config)#exit
Switch#write
(ro stands for read only and rw stands for read write)
Example: Configuring ‘sw-1’ as the user name with read-only purview and providing authentication and encryption password to it.
Switch#configure terminal
Switch(config)#security-manage snmp enable
Switch(config)#snmp user sw-1 ro auth sha 1234567890 priv des 0987654321
Switch(config)#exit
To display the SNMP user information, enter the following command
Switch#show snmp user
Note: SNMPv3 feature is unavailable on the Web GUI.
On the Linux server enter the following commands to install SNMP management server:
sudo apt-get update
sudo apt-get install snmp snmpd libsnmp-dev
Make sure that the server and the switch are in the same subnet. Enter the following command to test if SNMP is working:
snmpwalk -v3 -l authpriv sha -a 123456789 -x des -X 0987654321 -u sw-1 192.168.0.97
If you find a list of OIDs as an output at the end, then SNMP is working on the device.