On server is running XI 2009R1.4B, I only have a handfull of hosts and services configured, and they're all done by cfg files in the static directory that I've copied from our Core server.
For one of the hosts, though, I see 3 services showing in the XI interface that are in a Warning state, saying "could not fetch information from server".
Maybe I'm staring right at it, but I can't seem to find where these services are defined. A grep of all cfg files in the static directory doesn't show the service name defined anywhere. Someone may have tried to add the services with the XI interface, don't know. I tried the XI interface and checking one of these "mystery" services, but I can't delete it, and the Core Configuration Manager only sees services on "localhost".
Any ideas or things I should check? I'll provide screenshots if they would help.
Thanks....Lyle
can't find where "mystery" service is defined
Re: can't find where "mystery" service is defined
This sounds like two copies of Nagios might be running (one with an old configuration). Try the following commands from the shell prompt and see if the problem disappears:
Code: Select all
service nagios stop
killall nagios
service ndo2db restart
service nagios start
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Ethan Galstad
President
Ethan Galstad
President
Re: can't find where "mystery" service is defined
First, lets make sure we've got a clean slate. Run:
killall -9 nagios
service nagios start
Then go to the Core Config Manager and Apply Configuration, this will sync up what you're seeing in the interface with any configs that someone may have attempted to add.
It's possible that someone may have attempted to manually add services to the /usr/local/nagios/etc/hosts or /usr/local/nagios/etc/services directory. I would try looking there as well and see if they were added anywhere.
killall -9 nagios
service nagios start
Then go to the Core Config Manager and Apply Configuration, this will sync up what you're seeing in the interface with any configs that someone may have attempted to add.
It's possible that someone may have attempted to manually add services to the /usr/local/nagios/etc/hosts or /usr/local/nagios/etc/services directory. I would try looking there as well and see if they were added anywhere.
Re: can't find where "mystery" service is defined
I *did* find a config file under /usr/local/nagios/etc/services. Not sure where it came from, since I only operate in the static directory, but no matter...problem is gone now.
After changing configuration files in the static directory, I verify things with:
/usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg
as I would in Core.
But to update XI with my manual configs, do I do "/etc/init.d/nagios reload" or "service nagios restart" or use the XI interface to go to the Core Config Manager and Apply Configuration?
Thanks...Lyle
After changing configuration files in the static directory, I verify things with:
/usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg
as I would in Core.
But to update XI with my manual configs, do I do "/etc/init.d/nagios reload" or "service nagios restart" or use the XI interface to go to the Core Config Manager and Apply Configuration?
Thanks...Lyle
Re: can't find where "mystery" service is defined
The Apply Configuration does the following things:
- imports any new configs from the /usr/local/nagios/etc/import directory (usually config wizard configs)
- write CCM configs from the database to the config files
- verifies all configs (includes those in the static directory)
- restarts nagios with the 'service nagios restart' command.
I typically do 'service nagios restart' if I'm working from the command-line. For your static configuration, you can use whatever method you prefer, either of them will work.
- imports any new configs from the /usr/local/nagios/etc/import directory (usually config wizard configs)
- write CCM configs from the database to the config files
- verifies all configs (includes those in the static directory)
- restarts nagios with the 'service nagios restart' command.
I typically do 'service nagios restart' if I'm working from the command-line. For your static configuration, you can use whatever method you prefer, either of them will work.