JMX notifications->snmptrapd->snmptt->Nagios C onfiguation

Karan uk nkaranuk at gmail.com
Mon Dec 19 08:52:04 CET 2005


thanx Thomas for your reply.But the script writing nagios.cmd is
/usr/lib/nagios/plugins/eventhandlers/submit_check_result,it's writing it
just as you said i.e." PROCESS_SERVICE_CHECK_RESULT;winnt_host;TRAP;1;TRAP
RECEIVED;".
I just made a typing mistake in the query :(  .

The case happening here is that the configured nagios is not executing the
entries in the nagios.cmd,though the respective conf in nagios.cfg is---
check_external_commands=1
command_check_interval=1
command_file=/usr/local/nagios/var/rw/nagios.cmd
---
looking fwd for ur thoughts,
nKaranUk

On 12/16/05, Thomas.Zimmer at oppenheim.de <Thomas.Zimmer at oppenheim.de> wrote:
>
> Hi,
> i think you are not using the right syntax for the nagios.cmd file ("1
> PROCESS_SERVICE_CHECK_RESULT :winnt_host:TRAP:1:Trap received")
> It should be:
>
> now=`date +%s`
> commandfile='/usr/local/nagios/var/rw/nagios.cmd'
>
> /bin/printf "[%lu] PROCESS_SERVICE_CHECK_RESULT;host1;service1;0;OK-
> Everything Looks Great\n" $now > $commandfile
>
> See http://www.nagios.org/developerinfo/externalcommands/commandlist.php for
> all commands.
>
> Greetz,
> *Thomas Zimmer*
> Produktservice & Betrieb
> Betrieb & Support
> Sal. Oppenheim jr. & Cie., Frankfurt a. Main
> Telefon: +49 69 7134 0 5192
> Internet: http://www.oppenheim.de
> E-Mail: thomas.zimmer at oppenheim.de
>
>  -----Ursprüngliche Nachricht-----
> *Von:* nagios-users-admin at lists.sourceforge.net [mailto:
> nagios-users-admin at lists.sourceforge.net] *Im Auftrag von *Karan uk
> *Gesendet:* Freitag, 16. Dezember 2005 08:26
> *An:* nagios-users at lists.sourceforge.net
> *Betreff:* [Nagios-users] JMX notifications->snmptrapd->snmptt->Nagios
> Configuation
>
> Hello,
> I was looking to configure Nagios so that it can accept SNMP traps(JMX
> notification thru snmptrapd->snmptt) and send e-mail.
> As per the doc's i've got snmptrapd writing the nagios.cmd file.Butconfigured Nagios seems to not react to the PROCESS_SERVICE_CHECK_RESULT
> entries in the command file.
> The configuration files i'm using are as bellow.Do let me know if i'm
> missing something in the conf. or the way to make nagios execute
> nagios.cmd entries.
> Nagios Version 1.3
> nagios.cmd--
> 1 PROCESS_SERVICE_CHECK_RESULT :winnt_host:TRAP:1:Trap received
>
> Respective conf in nagios.cfg---
> check_external_commands=1
> command_check_interval=1
> command_file=/usr/local/nagios/var/rw/nagios.cmd
> ---
> services.cfg--
> define service{
> use generic-service
> e template to use
>
> host_name winnt_host
> service_description TRAP
> is_volatile 0
> check_period 24x7
> max_check_attempts 3
> normal_check_interval 5
> retry_check_interval 1
> active_checks_enabled 0
> passive_checks_enabled 1
> contact_groups nt-admins
> notification_interval 120
> notification_period 24x7
> notification_options w,u,c,r
> check_command check-host-alive
> }
> ----------
> snmptt.ini---
> dns_enable = 0
> strip_domain = 0
> net_snmp_perl_enable = 0
> translate_value_oids = 0
> translate_enterprise_oid_format = 1
> ----------
> snmptrapd.conf-------
> traphandle default /usr/sbin/snmptt
> -------------
>
> thanks in advance,
> nkaranuk
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.monitoring-lists.org/archive/users/attachments/20051219/8cdacaf1/attachment.html>


More information about the Users mailing list