Esnmp_Init - Compaq TCP/IP Services for OpenVMS Programming And Reference Manual

Tcp/ip services for openvms
Table of Contents

Advertisement

eSNMP API Routines

esnmp_init

esnmp_init
Initializes the Extensible SNMP (eSNMP) subagent and initiates communication
with the master agent.
Format
int esnmp_init (int *socket,
Arguments
socket
The address of the integer that receives the socket descriptor used by eSNMP.
subagent_identifier
The address of a null-terminated string that uniquely identifies this subagent
(usually a program name).
Description
Call this routine during program initialization or to restart the eSNMP protocol.
If you are restarting, the
subtree must be registered again.
You should attempt to create a unique subagent identifier, perhaps using the
program name
not open communications with a subagent whose subagent identifier is already in
use.
This routine does not block waiting for a response from the master agent. After
calling the
that is to be handled by the subagent.
Return Values
ESNMP_LIB_NO_
CONNECTION
ESNMP_LIB_OK
ESNMP_LIB_NOTOK
Example
#include <esnmp_h>
int socket;
status = esnmp_init(&socket, "gated");
5–2 eSNMP API Routines
char *subagent_identifier ) ;
esnmp_init
argv[0]
and additional descriptive text. The master agent does
esnmp_init
routine, call the
Could not initialize or communicate with the
master agent. Try again after a delay.
The
successfully.
Could not allocate memory for the subagent.
routine clears all registrations so each
esnmp_register
routine for each subtree
routine has completed
esnmp_init

Advertisement

Table of Contents
loading

Table of Contents