nagios -->> ndo2db -->> centreon

James Pifer jep at obrien-pifer.com
Tue Jun 9 14:53:41 CEST 2009


> Thanks for all the help!!! Was able to get everything working. 
> 
> James

I spoke a little bit too soon. Although a couple of the hosts showed up,
that's all I can get to work. I've added more, and the nagios configs
get updated, yet nagios doesn't show any changes. So I'm missing
something on the nagios/configuration side.

If I take a bracket out of one of the configs, then nagios won't
restart, so I know it's reading these cfg files. In the files
below, srv-xen02.mydomain.com and srv-xen03.mydomain.com are working,
but none of the others are. 

If I remove one of these hosts (using centreon frontend) it removes it
from the configs, nagios is restarted, but nagios is not updated. It
still shows the same two hosts.

Anyone know what I might be missing? Here are some of my configs. The
contacts listed in these configs all exist. 

Thanks,
James

For example, my config files are at /etc/nagios
#####################################################################
# cat hostgroups.cfg
define hostgroup{
        hostgroup_name                  Linux_Servers
        alias                           All linux servers
        members                         srv-xen02.mydomain.com, srv-xen03.mydomain.com, srv-xen04.mydomain.com, srv-xen05.mydomain.com
}

define hostgroup{
        hostgroup_name                  MY_routers
        alias                           MY routers
        members                         SLW-E11.mydomain.com
}


####################################################################
# cat hosts.cfg

define host{
        name                            generic-host
        alias                           generic-host
        check_command                   check_host_alive
        max_check_attempts                      5
        active_checks_enabled           1
        passive_checks_enabled          0
        check_period                    24x7
        contact_groups                  netcool, Supervisors
        notification_interval           0
        notification_period             24x7
        notification_options            d,r
        notifications_enabled           0
        register                                0
}

define host{
        name                            Servers-Linux
        use                             generic-host
        alias                           Linux Servers
        register                                0
}

define host{
        host_name                               srv-xen02.mydomain.com
        use                             Servers-Linux
        alias                           srv-xen02
        address                         192.168.4.152
        hostgroups                      Linux_Servers
        check_command                   check_host_alive
        max_check_attempts                      10
        check_interval                  1
        active_checks_enabled           1
        passive_checks_enabled          1
        check_period                    24x7
        obsess_over_host                        0
        check_freshness                 0
        flap_detection_enabled          0
        process_perf_data                       0
        retain_status_information               0
        retain_nonstatus_information    0
        contact_groups                  netcool
        notification_interval           1
        notification_period             24x7
        notification_options            d,u
        notifications_enabled           1
}

define host{
        host_name                               srv-xen03.mydomain.com
        use                             Servers-Linux
        alias                           srv-xen03
        address                         192.168.4.153
        hostgroups                      Linux_Servers
        check_command                   check_host_alive
        max_check_attempts                      10
        check_interval                  1
        active_checks_enabled           0
        passive_checks_enabled          0
        check_period                    24x7
        obsess_over_host                        0
        check_freshness                 0
        flap_detection_enabled          0
        process_perf_data                       0
        retain_status_information               0
        retain_nonstatus_information    0
        contact_groups                  netcool
        notification_interval           1
        notification_period             24x7
        notification_options            d,u
        notifications_enabled           1
}

define host{
        host_name                               srv-xen04.mydomain.com
        use                             Servers-Linux
        alias                           srv-xen04
        address                         192.168.4.154
        hostgroups                      Linux_Servers
        check_command                   check_host_alive
        max_check_attempts                      10
        check_interval                  1
        active_checks_enabled           1
        passive_checks_enabled          1
        check_period                    24x7
        obsess_over_host                        0
        check_freshness                 0
        flap_detection_enabled          0
        process_perf_data                       0
        retain_status_information               0
        retain_nonstatus_information    0
        contact_groups                  netcool
        notification_interval           1
        notification_period             24x7
        notification_options            d,u
        notifications_enabled           1
}

define host{
        host_name                               srv-xen05.mydomain.com
        use                             Servers-Linux
        alias                           srv-xen05
        address                         192.168.4.155
        hostgroups                      Linux_Servers
        check_command                   check_host_alive
        max_check_attempts                      10
        check_interval                  1
        active_checks_enabled           0
        passive_checks_enabled          0
        check_period                    24x7
        obsess_over_host                        0
        check_freshness                 0
        flap_detection_enabled          0
        process_perf_data                       0
        retain_status_information               0
        retain_nonstatus_information    0
        contact_groups                  netcool
        notification_interval           1
        notification_period             24x7
        notification_options            d,u
        notifications_enabled           1
}

define host{
        host_name                       SLW-E11.mydomain.com
        use                             generic-host
        alias                           SLW-E11
        address                         10.65.42.1
        hostgroups                      MY_routers
        check_command                   check_host_alive
        check_interval                  1
        check_period                    24x7
        contact_groups                  netcool
        notification_interval           1
        notification_options            d,u
}

####################################################################
# cat services.cfg

define service{
        name                            generic-service
        service_description             generic-service
        is_volatile                     0
        max_check_attempts                      3
        normal_check_interval           5
        retry_check_interval            1
        active_checks_enabled           1
        passive_checks_enabled          0
        check_period                    24x7
        notification_interval           0
        notification_period             24x7
        notification_options            w,c,r
        notifications_enabled           0
        contact_groups                  Supervisors
        register                                0
}

define service{
        name                            Ping-LAN
        service_description             ping
        use                             generic-service
        check_command                   check_centreon_ping!3!200,20%!400,50%
        register                                0
        ;TEMPLATE-HOST-LINK             generic-host
}

define service{
        host_name                               srv-xen03.mydomain.com
        service_description             ping
        use                             Ping-LAN
}

define service{
        host_name                               srv-xen02.mydomain.com
        service_description             ping
        use                             Ping-LAN
}

define service{
        host_name                               srv-xen04.mydomain.com
        service_description             ping
        use                             Ping-LAN
}

define service{
        host_name                               srv-xen05.mydomain.com
        service_description             ping
        use                             Ping-LAN
}

define service{
        host_name                               SLW-E11.mydomain.com
        service_description             ping
        use                             Ping-LAN
}




------------------------------------------------------------------------------
Crystal Reports - New Free Runtime and 30 Day Trial
Check out the new simplified licensing option that enables unlimited
royalty-free distribution of the report engine for externally facing 
server and web deployment.
http://p.sf.net/sfu/businessobjects
_______________________________________________
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