Compaq TCP/IP Services for OpenVMS Programming And Reference Manual page 62

Tcp/ip services for openvms
Table of Contents

Advertisement

eSNMP API Routines
esnmp_register
A subtree is identified by the base MIB name and the corresponding
of the node that is the parent of all MIB variables contained in the subtree. For
example: The MIB II
subordinate to this have the same first seven digits and are included in the
subtree's object table. The subtree can also be a single MIB object (a leaf node) or
even a specific instance.
By registering a subtree, the subagent indicates that it will process eSNMP
requests for all MIB variables (or
a subagent should register the most fully qualified (longest) subtree that still
contains its instrumented MIB variables.
The master agent does not permit a subagent to register the same subtree more
than once. However, subagents can register subtrees with ranges that overlap
the
OID
subtrees registered by other subagents.
For example, TCP/IP Services supports MIB II. In the eSNMP environment, the
os_mibs
TCP/IP Services also provides the
ipRouteEntry
These MIBs are registered at priority 1. Any subagent that registers at a higher
priority (greater than 1) overrides these registrations.
A request for
subagent. Requests for other
1.3.5.1.2.1.4.22.1.1) are passed to the
terminates or unregisters the
ipRouteIfIndex
subtree, which includes all
region of requests for
Return Values
SNMP_LIB_OK
ESNMP_LIB_BAD_REG
ESNMP_LIB_LOST_
CONNECTION
Note that the return value indicates only the initiation of the request. The actual status returned
in the master agent's response will be returned in a subsequent call to the
the
field.
state
Example
#include <esnmp.h>
#define RESPONSE_TIMEOUT
#define REGISTRATION_PRIORITY 10 /* priority at which subtrees
int status;
extern SUBTREE ipRouteEntry_subtree;
5–4 eSNMP API Routines
subtree has an
tcp
ranges of subtrees previously registered, and subagents can also register
subagent registers the MIB II subtree
MIB subtree (OID 1.3.6.1.2.1.4.21.1).
(OID 1.3.5.1.2.1.4.21.1.2) is passed to the
IpRouteIfIndex
ip
ipRouteEntry
will go to the
os_mibs
ipRouteEntry
ipRouteIfIndex
of
OID
1.3.6.1.2.1.6
) within that subtree's range. Therefore,
OIDs
ip
(OID 1.3.6.1.2.1.4).
subagent, which registers the
gated
variables, such as
ipNetToMediaIfIndex
subagent. If the
os_mibs
subtree, subsequent requests for
subagent. This occurs because the
variables, is now the authoritative
.
The
esnmp_register
routine has completed
successfully.
The
routine has not been called, the
esnmp_init
timeout parameter is invalid, or the subtree has
already been queued for registration.
The subagent has lost communications with the
master agent.
0
/* use the default time set
in OPEN message */
will register */
number
OID
. All elements
gated
(OID
subagent
gated
ip
esnmp_poll
routine in

Advertisement

Table of Contents
loading

Table of Contents