4.4 Explain how SNMP is used in network operations

CCNA 200-301 v1.1 · 4.0 IP Services

SNMP lets a management station (NMS) read counters and settings from network devices and receive alerts from them. Every device runs an agent that exposes a MIB, a tree of objects such as interface counters and CPU load. For the CCNA you explain gets, sets, traps and informs, the versions, and why SNMPv3 is the one to use.

What you must know

Manager, agent and MIB

The NMS polls agents with Get requests on UDP 161, for example every 5 minutes for interface counters, and graphs the results. Each value is an OID in the MIB tree (1.3.6.1.2.1.2.2.1.10 is an interface's input octets). Agents also send traps on UDP 162 when something happens, such as a link going down, without waiting to be asked. An inform is a trap that the NMS acknowledges, so it is resent if lost.

The NMS reads counters with gets (1); the switch reports events with traps as they happen (2).

Versions and security

VersionAuthenticationEncryptionNotes
v1Community string, clear textNoObsolete
v2cCommunity string, clear textNoAdds GetBulk and informs; still common
v3Username with SHA (authNoPriv)AES (authPriv)The secure choice
snmp-server group NMS-GROUP v3 priv
snmp-server user nms NMS-GROUP v3 auth sha Auth-Pass1 priv aes 128 Priv-Pass1
snmp-server host 10.0.50.10 version 3 priv nms
snmp-server enable traps

With v2c, a read-only community allows gets; a read-write community also allows sets, so anyone who sniffs it can change the configuration. Restrict SNMP with an ACL either way.

Commands

show snmpPackets in and out, errors, and whether traps are enabled.
show snmp userSNMPv3 users and their security settings.
show snmp hostWhere traps and informs are sent.

Exam traps

Check yourself

Which SNMP message does a device send unasked when an interface goes down?
A trap (or an inform, if the NMS must acknowledge it).
Which version and security level give authentication and encryption?
SNMPv3 with authPriv.
What is a MIB?
The structured set of objects (OIDs) an agent exposes.

More topics in 4.0 IP Services