NonStop NET/MASTER Trap Subagent
SNMP Configuration and Management Manual — 424777-006
10 -10
Modifying GENTRAP
Example 10-2. Initial Contents of GENTRAP
(page 1 of 2)
gentrap: procedure nofold
/*
procedure: gentrap
synopsis: gentrap <snmp-agent-processname>
description:
This procedure is intended to be invoked from RMS. GENTRAP
assembles an SNMP trap from the EMS event and writes it to
the #TRAP interface of the specified SNMP agent.
The agent is specified as &1 on the "NCL Proc Name" field of
page 5 of RMS : System Action screen.
This procedure opens and closes the agent each time it is called.
To improve efficiency, the procedure could open the agent and set
a global flag first time it is called, then check the flag each
time to decide whether to open the agent or not.
This procedure assumes that the NCL variables for the event exist
and are set correctly. Do not run this procedure from an
environment that does not have the event (OCS, for example).
*/
%%include nnmtrap
&err = openagent(&1, myagt);
if &err \= 0 then do
say "error "&err" from openagent call. &sys.file.rc = ",
&sys.file.rc
say " &sys.file.error = "&sys.file.error
say " &sysmsg = "&sysmsg
flush;
end;
control shrvars=&trap.*
&trap.oid.1 = 1.3.6.1.4.1.169.3.12.1 ; /* SSID */
&trap.value.1 = &zzzmssid;
&trap.oid.2 = 1.3.6.1.4.1.169.3.12.2 ; /* event number */
&trap.value.2 = d2c(&$ems.spi.tandem.zems_tkn_eventnumber) ;
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 ...