Trap Multiplexer Subagent/Manager
SNMP Configuration and Management Manual — 424777-006
12 -66
Application Source Code
default : printf ("Type : UNKNOWN \n");
break;
} /* end of case */
/* exit from the current list */
spi_err = EMSGETTKN ((short*)event_buf, ZSPI_TKN_ENDLIST);
if (spi_err !=ZSPI_ERR_OK)
DEBUG();
} /* end of for loop */
} /* end while */
} /* end getevent_loop */
/************************************************************************/
#pragma PAGE "main program code"
/*
Starts an EMS consumer distributor and calls procedures that use
SPI commands to connect to the source collector, to load a filter
and to position the distributor within the log files. Then the
getevent_loop procedure is called to retrieve and process event
messages.
*/
main(int argc, char**argv) <-- 34
{
short error;
short startup_msg_actual_len;
startup_msg_type ci_startup;
char *cptr;
int ccval = 0;
#define proc_name_len 40
char proc_name[proc_name_len];
char* whoami,opt;
short err_detail;
short proc_len;
char* startup_default_str;
char* coll_name = "$0"; /* default collector name */
char* filt_name = "tmxfo"; /* default event filter */
#define file_name_Dxx_maxlen 36
char filt_name_Dxx[file_name_Dxx_maxlen]; /* D series filename */
char filt_name_Cxx[24]; /* C series filename */
char coll_name_Dxx[file_name_Dxx_maxlen];
char coll_name_Cxx[24];
short file_name_len;
short distr; /* distributor file number */
char* spi_buf;
char usage[] = "Usage: %s [-c <collector-name>] [-f <filter-name>]\n\n";
/* Get the default vol and subvol to set up the internal filenames later */
startup_default_str = getenv ("DEFAULTS");
whoami = *argv++;
argc--;
Example 12-3. Sample Application Source Code
(page 11 of 14)
Summary of Contents for T9576G06
Page 24: ...Contents SNMP Configuration and Management Manual 424777 006 xxii Tables continued ...
Page 38: ...Part I Installing and Configuring SNMP SNMP Configuration and Management Manual 424777 006 ...
Page 140: ...Part II SCF for the SNMP Agent SNMP Configuration and Management Manual 424777 006 ...
Page 208: ...Part III Troubleshooting SNMP Configuration and Management Manual 424777 006 ...
Page 230: ...Part IV SNMP Subagents SNMP Configuration and Management Manual 424777 006 ...
Page 704: ...Part V Appendices SNMP Configuration and Management Manual 424777 006 ...
Page 778: ...Index SNMP Configuration and Management Manual 424777 006 Index 32 Special Characters ...