SNMP Pynet Labs
SNMP Pynet Labs
Management Protocol
SNMP – Simple Network Management Protocol works on the application layer using the
UDP port number 161 (manager) /162 (agent) and helps in monitoring the network,
detecting the issues, and making configurations on devices. A complete SNMP setup
includes:
SNMP Manager: A management system that uses SNMP to poll and fetch data from a
number of network devices to monitor the performance, health, and status of network
devices such as routers, switches, and servers. This is typically a software application that
runs in a central location.
SNMP Agent: A program that the network devices which we are willing to monitor will be
configured with. The devices enabled as SNMP Agent will reply to SNMP Polls sent by the
SNMP manager with the information from the local database. In addition to responding to
SNMP Polls and queries the agents can also send alerts or “traps” to the SNMP manager
informing it about specific events like device failure.
There are several types of messages which are exchanged between SNMP Manager and
SNMP Agents, let’s understand them:
Get Request: A Get Request is sent by the manager to request a specific variable from the
SNMP Manager. In simpler terms, we can understand that this is used to fetch the data from
the devices. As a response agent replies back with the requested information.
Get Next Request: This message is used to request for a variable in a sequence following an
initial get request instead of requesting for a specific variable.
Get Bulk Request: This message is used to fetch out large data at once for example, when
whole tables or lists of values in a MIB variable are needed.
Set Request: This message is used to set a specific value for an object on the SNMP Agent
Response: These messages are sent from the agent to the SNMP manager as a reply to the
requests or SNMP Polls sent by the manager on regular intervals.
SNMP Trap: SNMP agents can send unsolicited alerts to notify the SNMP manager of real-
time events using SNMP Traps. For example, information about an event like interface state
change, device failures, etc.
Inform Request: These messages are used by agents and are similar to trap messages but
they require acknowledgement from SNMP manager. If in case the manager does not
acknowledge the message the agent will resend the message.
As network management has evolved, SNMP has developed into three different versions:
SNMPv1 (The original SNMP Version 1): In version 1 the SNMP managers can gain access to
the SNMP agents by matching a simple “community” text string which makes it a little less
secured as compared to other versions.
SNMPv2C (The second version of SNMP): Version 2 of SNMP also uses community strings.
In version 2 the availability of bulk request enables the SNMP managers to fetch out data in
bulk form by making a single request. In addition, v2 requires an acknowledgement from the
SNMP manager after receiving the SNMP traps or Inform requests. SNMPv2C does not
address any security concerns over that of SNMPv1.
SNMPv3 (The third version of SNMP): This version addresses the security features which
were lacking in the previous two versions by using hash-based MAC with MD5 or SHA for
authentication and DES for privacy. Each SNMPv3 group is defined with a security level that
describes the extent to which the SNMP data will be protected. There are 3 security levels: