SNMP Traps

Giles Coochey gcoochey at sapphire.gi
Wed Oct 17 12:37:19 CEST 2007


Hi,

 

Nagios 2.9

 

I'm looking at the document to handle SNMP traps which I found here:

 

http://www.samag.com/documents/s=9559/sam0503g/

 

I've got all the SNMP parts configured and I think I won't have problems
doing the external command part.

 

The Nagios configuration is, however, giving me some grief; this is my
first use of passive checks however, so maybe I'm being plain stupid. I
found an earlier thread which assisted me with some errors, but the
pre-flight-check now returns:

 

Nagios 2.9

Copyright (c) 1999-2007 Ethan Galstad (http://www.nagios.org)

Last Modified: 04-10-2007

License: GPL

 

Reading configuration data...

 

Error: Invalid max_attempts, check_interval, retry_interval, or
notification_interval value for service 'TRAP-CRITICAL' on host
'32Red-VPN'

Error: Could not register service (config file
'/opt/nagios/etc/generic.cfg', starting on line 942)

 

***> One or more problems was encountered while processing the config
files...

 

     Check your configuration file(s) to ensure that they contain valid

     directives and data defintions.  If you are upgrading from a
previous

     version of Nagios, you should be aware that some
variables/definitions

     may have been removed or modified in this version.  Make sure to
read

     the HTML documentation regarding the config files, as well as the

     'Whats New' section to find out what has changed.

 

 

I don't believe I have a max_attempts at all (anywhere in the file),
check_interval / retry_interval is presumably either
normal_check_interval or retry_check_interval.

 

Can anyone see where I've gone wrong?

 

Relevant Service Configuration:

 

define service{

        name                            generic-passive-service

        active_checks_enabled           0

        passive_checks_enabled          1

        parallelize_check               1

        obsess_over_service             1

        check_freshness                 0

        notifications_enabled           1

        event_handler_enabled           1

        flap_detection_enabled          1

        failure_prediction_enabled      1

        process_perf_data               1

        retain_status_information       1

        retain_nonstatus_information    1

        register                        0

        retry_check_interval            1

        }

 

define service{

        name                            passive-check-template

        use                             generic-passive-service

        check_freshness                 1

        check_period                    none

        passive_checks_enabled          1

        max_check_attempts              1

        check_command                   passive_check_missing

        freshness_threshold             600

        register                        0

        }

 

define service{

        use                             passive-check-template

        name                            generic-snmptrap

        service_description             snmp_trap_handling

        is_volatile                     1

        check_period                    none

        notification_interval           120

        notification_options            w,u,c,r

        notification_period             24x7

        check_command                   passive_check_missing

        max_check_attempts              1

        check_freshness                 0

        stalking_options                o,w,u,c

        register                        0

        }

 

 

define service {

        use                             generic-snmptrap

        host_name                       *

        contact_groups                  testing

        service_description             TRAP-OK

        }

 

define service {

        use                             generic-snmptrap

        host_name                       *

        contact_groups                  testing

        service_description             TRAP-WARNING

        }

 

define service {

        use                             generic-snmptrap

        host_name                       *

        contact_groups                  testing

        service_description             TRAP-CRITICAL

}

 

 

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.monitoring-lists.org/archive/users/attachments/20071017/435db816/attachment.html>
-------------- next part --------------
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
-------------- next part --------------
_______________________________________________
Nagios-users mailing list
Nagios-users at 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


More information about the Users mailing list