Your snmptrap command would look something like this: /usr/bin/snmptrap -v 2c -c public snmpmanager '' \ .1.3.6.1.4.1.20006.1.5 \ .1.3.6.1.4.1.20006.1.1.1.2 s $HOSTNAME$ \ .1.3.6.1.4.1.20006.1.2.1.1 i $HOSTSTATEID$ \ [OID] [TYPE] [VALUE]...
If you had a server "MyServer" go down, and notifications via snmptrap configured as above, your trap manager would recieve the following: TrapOID: HostEvent Hostname = "MyServer" HostStateID = 1 The syntax and options for snmptrap can be found the the net-snmp docs. http://net-snmp.sourceforge.net/ OIDs and descriptions can be found in the Nagios MIB. http://sourceforge.net/project/showfiles.php?group_id=29880&package_id=15331 5 > -----Original Message----- > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] > Sent: Wednesday, January 04, 2006 8:05 AM > To: nagios-users@lists.sourceforge.net > Subject: [Nagios-users] Sending SNMP traps from Nagios > > > Dear all, > > I need to send traps from Nagios to another NMS, in the > ocurrence of some > events. I have read all the documentation about snmptrap and the MIB > notification, but I have not been able to put it to work, > because I do not > see the exact syntax of the snmptrap command I have to issue > in the event > handler. Any of you is using this notification method? > > Any hints will be greatly appreciatted... > > Un saludo, > > > Pablo Espinar > > Barcelona (Spain) > > > > > > > ------------------------------------------------------- > This SF.net email is sponsored by: Splunk Inc. Do you grep > through log files > for problems? Stop! Download the new AJAX search engine that makes > searching your log files as easy as surfing the web. > DOWNLOAD SPLUNK! > http://ads.osdn.com/?ad_idv37&alloc_id865&op=click > _______________________________________________ > Nagios-users mailing list > Nagios-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/nagios-users > ::: Please include Nagios version, plugin version (-v) and OS > when reporting any issue. > ::: Messages without supporting info will risk being sent to /dev/null > ------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://ads.osdn.com/?ad_id=7637&alloc_id=16865&op=click _______________________________________________ Nagios-users mailing list Nagios-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/nagios-users ::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. ::: Messages without supporting info will risk being sent to /dev/null