OS - RHEL 7
Nagios XI 5.7.2
Have removed host out of hosts and services. But they remain. I get this when trying to delete them out of the dashboard
Could not find a unique id for this host
Host cannot be deleted using this method
I've seen a LOT of responses on this - but so far nothing has worked
Manually went to /usr/local/nagios/etc/services and /usr/local/nagios/etc/hosts - there are no config files there
Ran this command /usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg - no errors or warnings
Went into config file management - delete files, write configs - restart Nagios Core - no errors
Ran this command /usr/local/nagiosxi/scripts/repairmysql.sh nagios - no change
Ran this command mysqlcheck -f -r -u root -p --database nagios - no change
Host cannot be deleted using this method
Re: Host cannot be deleted using this method
Can you try deleting the Host in the Core Configuration Manager instead of the dashboard?
If a host or service exists in Nagios, it should have a corresponding configuration file in one of the two folders.
Is it possible that this host or service was renamed at some point? It could be that the configuration file is not named what you would expect it to be.
It never hurts to send ( PM ) us a profile either! We can find lots of information about your system in there. You can download the profile by navigating to System Profile under System Config on the left pane > and clicking the Download Profile button on that page.
If a host or service exists in Nagios, it should have a corresponding configuration file in one of the two folders.
Code: Select all
/usr/local/nagios/etc/hosts
/usr/local/nagios/etc/servicesCode: Select all
cat /usr/local/nagios/etc/hosts/* | grep host_name
cat /usr/local/nagios/etc/services/* | grep host_nameAs of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Be sure to check out our Knowledgebase for helpful articles and solutions!
Be sure to check out our Knowledgebase for helpful articles and solutions!
-
seaward1983
- Posts: 69
- Joined: Wed Jul 17, 2019 2:09 pm
Re: Host cannot be deleted using this method
We ended up hacking the database. I think we're just going to have to restore from database.
Re: Host cannot be deleted using this method
Yes, if you have the skill to do it that way, it is probably the best method.
Thankyou for letting me know. May I lock this thread for editing?
Thankyou for letting me know. May I lock this thread for editing?
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Be sure to check out our Knowledgebase for helpful articles and solutions!
Be sure to check out our Knowledgebase for helpful articles and solutions!
-
seaward1983
- Posts: 69
- Joined: Wed Jul 17, 2019 2:09 pm
-
scottwilkerson
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: Host cannot be deleted using this method
Great!seaward1983 wrote:yes
Locking thread