When I attempt to apply a new configuration, I get the following error:
Error: There are no services defined!
Error: There are no hosts defined!
Error: There are no contacts defined!
I can view the hosts/services in the DB, and the configuration files for them are on the server.
I can also see the services in the DB.
However, a bunch of the configuration files are blank on the server
Code: Select all
[/usr/local/nagios/etc]
$ ll
total 48K
drwxrwxr-x. 8 apache nagios 4.0K Sep 2 12:00 .
drwxr-xr-x 10 root root 4.0K Oct 15 2018 ..
-rw-rw-r-- 1 apache nagios 0 Sep 2 04:30 cgi.cfg
-rw-rw-r-- 1 apache nagios 0 Sep 2 11:02 commands.cfg
-rw-rw-r-- 1 apache nagios 0 Sep 2 11:02 contactgroups.cfg
-rw-rw-r-- 1 apache nagios 0 Sep 2 11:02 contacts.cfg
-rw-rw-r-- 1 apache nagios 0 Sep 2 11:02 contacttemplates.cfg
-rw-rw-r-- 1 apache nagios 0 Sep 2 11:02 hostdependencies.cfg
-rw-rw-r-- 1 apache nagios 0 Sep 2 11:02 hostescalations.cfg
-rw-rw-r-- 1 apache nagios 0 Sep 2 11:02 hostextinfo.cfg
-rw-rw-r-- 1 apache nagios 0 Sep 2 11:02 hostgroups.cfg
drwxrwxr-x. 2 apache nagios 4.0K Sep 2 11:57 hosts
-rw-rw-r-- 1 apache nagios 0 Sep 2 11:02 hosttemplates.cfg
drwxrwxr-x. 2 apache nagios 4.0K Sep 2 11:59 import
-rw-rw-r-- 1 apache nagios 0 Sep 2 11:57 nagios.cfg
-rw-rw-r-- 1 apache nagios 5.6K Sep 2 11:29 nagios.log
-rw-rw-r-- 1 apache nagios 0 Jun 1 2018 ndo2db.bak
-rw-rw-r-- 1 apache nagios 0 Nov 28 2018 ndo2db.cfg
-rw-rw-r-- 1 apache nagios 0 Nov 28 2018 ndomod.cfg
-rw-rw-r-- 1 apache nagios 0 Jul 23 2018 nrpe.cfg
-rw-rw-r-- 1 apache nagios 0 Jun 26 2018 nrpe.cfg.old
-rw-rw-r-- 1 apache nagios 5.3K Jun 20 2018 nsca.cfg
drwxrwxr-x. 4 apache nagios 4.0K Sep 2 11:57 pnp
-rw-rw-r-- 1 apache nagios 0 Nov 29 2018 recurringdowntime.cfg
-rw-rw-r-- 1 apache nagios 0 Apr 9 2018 resource.cfg
-rw-rw-r-- 1 apache nagios 0 Aug 27 04:33 sedkWKH3S
-rw-rw-r-- 1 apache nagios 0 Sep 2 10:53 sedPoBMRf
-rw-rw-r-- 1 apache nagios 0 Apr 9 2018 send_nsca.cfg
-rw-rw-r-- 1 apache nagios 0 Sep 2 11:02 servicedependencies.cfg
-rw-rw-r-- 1 apache nagios 0 Sep 2 11:02 serviceescalations.cfg
-rw-rw-r-- 1 apache nagios 0 Sep 2 11:02 serviceextinfo.cfg
-rw-rw-r-- 1 apache nagios 0 Sep 2 11:02 servicegroups.cfg
drwxrwxr-x. 2 apache nagios 4.0K Sep 2 11:57 services
-rw-rw-r-- 1 apache nagios 0 Sep 2 11:02 servicetemplates.cfg
drwxrwxr-x. 5 apache nagios 4.0K Sep 2 11:57 ssl
drwxrwxr-x. 2 apache nagios 4.0K Sep 2 11:57 static
-rw-rw-r-- 1 apache nagios 0 Sep 2 11:02 timeperiods.cfg
Every time I try deleting the files from the GUI and writing them, they come back blank.
If I try importing them into the DB from a good snapshot through the GUI, it says it completes, then comes back blank when I delete/write or when I try to apply a new configuration.
I have also attempted to restore from a snapshot, but I still can't write any changes.
Any suggestions would be appreciated.
I have run repair_database and it comes back and says no problems found.
I have tried reconfigure_nagios and it comes back warning that no Contacts/Services/Hosts are found, even though I see them in the GUI and in the Database.