This didn't work. I got these files in /var/lib/nagios/export in the neutron-api/0 unit, for example:
host__juju-machine-1-lxc-1.cfg
service__region1-neutron-api-0_check_apache2.cfg
service__region1-neutron-api-0_check_haproxy.cfg
service__region1-neutron-api-0_check_haproxy_queue.cfg
service__region1-neutron-api-0_check_haproxy_servers.cfg
service__region1-neutron-api-0_check_neutron-server.cfg
The host one has these contents:
define host {
address 10.245.201.104
host_name juju-machine-1-lxc-1
use server
hostgroups machines,
}
The service ones, though, don't use that host_name. For example, service__region1-neutron-api-0_check_neutron-server.cfg:
define service {
use active-service
host_name region1-neutron-api-0
service_description region1-neutron-api-0[neutron-server] process check {neutron-api/0}
check_command check_nrpe!check_neutron-server
servicegroups region1
}
So service startup is still failing on the master:
Processing object config file '/etc/nagios3/cloud.d/service__region1-neutron-api-0_check_haproxy_servers.cfg'...
Error: Could not find any host matching 'region1-neutron-api-0' (config file '/etc/nagios3/cloud.d/service__region1-neutron-api-0_check_haproxy_servers.cfg', starting on line 5)
Error: Could not expand hostgroups and/or hosts specified in service (config file '/etc/nagios3/cloud.d/service__region1-neutron-api-0_check_haproxy_servers.cfg', starting on line 5)
Error processing object config files!
This didn't work. I got these files in /var/lib/ nagios/ export in the neutron-api/0 unit, for example: machine- 1-lxc-1. cfg _region1- neutron- api-0_check_ apache2. cfg _region1- neutron- api-0_check_ haproxy. cfg _region1- neutron- api-0_check_ haproxy_ queue.cfg _region1- neutron- api-0_check_ haproxy_ servers. cfg _region1- neutron- api-0_check_ neutron- server. cfg
host__juju-
service_
service_
service_
service_
service_
The host one has these contents: 1-lxc-1
define host {
address 10.245.201.104
host_name juju-machine-
use server
hostgroups machines,
}
The service ones, though, don't use that host_name. For example, service_ _region1- neutron- api-0_check_ neutron- server. cfg: neutron- api-0 description region1- neutron- api-0[neutron- server] process check {neutron-api/0} check_neutron- server
define service {
use active-service
host_name region1-
service_
check_command check_nrpe!
servicegroups region1
}
So service startup is still failing on the master: cloud.d/ service_ _region1- neutron- api-0_check_ haproxy_ servers. cfg'... neutron- api-0' (config file '/etc/nagios3/ cloud.d/ service_ _region1- neutron- api-0_check_ haproxy_ servers. cfg', starting on line 5) cloud.d/ service_ _region1- neutron- api-0_check_ haproxy_ servers. cfg', starting on line 5)
Processing object config file '/etc/nagios3/
Error: Could not find any host matching 'region1-
Error: Could not expand hostgroups and/or hosts specified in service (config file '/etc/nagios3/
Error processing object config files!