Simple Network Management Protocol (SNMP) Manager APIs
The SNMP manager APIs are:
- snmpDiscover_v3() (SNMP Version 3 Discovery) allows an SNMP management application to discover authentication information about an SNMP version 3 (SNMPv3) agent.
- snmpFreeAuthCB_v3() (SNMP Version 3 Free Authentication Control Block) allows an SNMP management application to free the authentication information about an SNMP version 3 (SNMPv3) agent.
- snmpGet() (Retrieve MIB objects) is used to get one or more management information base (MIB) objects from an SNMP agent or subagent on a local or remote system.
- snmpGetbulk_v3() (Retrieve bulk MIB objects using SNMP version 3) allows you to get the value of one or more MIB objects from an SNMP agent or subagent on a local or remote system via an SNMP get bulk request.
- snmpGetnext() (Retrieve next MIB object) is used to get the value of one or more management information base (MIB) objects from an SNMP agent or subagent on a local or remote system.
- snmpGetnext_v3() (Retrieve next MIB object using SNMP version 3) allows an SNMP management application to retrieve the next MIB object using SNMP version 3 (SNMPv3).
- snmpGet_v3() (Retrieve MIB objects using SNMP version 3) allows an SNMP management application to retrieve MIB objects using SNMP version 3 (SNMPv3).
- snmpSet() (Set MIB objects) is used to set one or more management information base (MIB) objects in an SNMP agent or subagent on a local or remote system.
- snmpSetContext_v3() (SNMP Version 3 Set Context for SNMP Messages) is used to set the context name in the authentication block.
- snmpSet_v3() (Set MIB objects using SNMP Version 3) is used to set one or more management information base (MIB) objects in an SNMP agent or subagent on a local or remote system.
Note: These functions use header (include) files from the library QSYSINC, which is optionally installable. Make sure QSYSINC is installed on your system before using any of the functions. All of the SNMP manager APIs use header file qtomeapi.h. You can see this source in source file H, member name QTOMEAPI, in the QSYSINC library.
For examples that use the SNMP manager APIs, see Using SNMP Manager APIs--Example.
For information about trap support, see SNMP Trap Support.
SNMP managing applications typically use APIs to establish communication with local or remote SNMP agents, and then call other APIs to retrieve or modify MIB objects managed by those agents. The IBM® i SNMP manager APIs accomplish both of these tasks within the same API. Three manager APIs are provided to perform the SNMP GET, GETNEXT, and SET operations. In general, all three APIs are blocked. That is, when the application calls these APIs, the API constructs a proper SNMP message, delivers it to the proper SNMP agent, waits, decodes the response from the agent, and delivers the information to the application. No processing occurs in the application until the API delivers this information or times out. The communications mechanism between the manager APIs and agents uses sockets. Therefore, both systems need to support sockets.
Application programmers who are writing network management applications can use the snmpGet(), snmpGetnext(), and snmpSet() SNMP APIs to retrieve and set management information base (MIB) data so that they can manage their systems and networks. Programmers should have a strong understanding of network management, SNMP, and some transport protocol such as Transmission Control Protocol/Internet Protocol (TCP/IP).