When attempting to remove a host from nagios monitoring, I get this message:
Host Deletion Error
Could not find a unique id for this host
Host cannot be deleted using this method
One or more errors were detected that prevent the host from being deleted.
Possible causes include...
The host is associated with other hosts, services, or objects that need to be deleted first
The host is maintained in a static or external configuration file
To resolve this issue...
Use the Nagios Core Configuration Manager to delete the host - or -
Manually delete the host definition from the appropriate external configuration file
However, when I look at the configuration manager. That server is not listed there. Where is configuration file located and what is the best way to edit that file?
Unable to delete Host
-
benjaminsmith
- Posts: 5324
- Joined: Wed Aug 22, 2018 4:39 pm
- Location: saint paul
Re: Unable to delete Host
Hi @Kxfrancois,
Let's make sure you do not have multiple Nagios processes running. Run the following commands on the server:
Then go to the Configure > CCM > Tools > Config File Management, and click on Write and Verify to check for config errors.
If you don't have any errors, click on Delete to remove all host and service configuration files.
Next, apply configuration. The configs will be recreated with whatever is in the database.
Let me know this resolves the issue. If you're getting any error messages on Verify, please post the error messages or upload a screenshot.
Nagios XI - Host Still Visible After Deletion (Ghost Hosts)
https://support.nagios.com/kb/article.php?id=27
Let's make sure you do not have multiple Nagios processes running. Run the following commands on the server:
Code: Select all
service nagios stop
pkill -9 nagios
service nagios start
If you don't have any errors, click on Delete to remove all host and service configuration files.
Next, apply configuration. The configs will be recreated with whatever is in the database.
Let me know this resolves the issue. If you're getting any error messages on Verify, please post the error messages or upload a screenshot.
Nagios XI - Host Still Visible After Deletion (Ghost Hosts)
https://support.nagios.com/kb/article.php?id=27
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!
-
Kxfrancois
- Posts: 48
- Joined: Mon Nov 19, 2018 9:38 am
Re: Unable to delete Host
I get this message when I click on verify files:
Error: Service has no hosts and/or service_description (config file '/usr/local/nagios/etc/services/COMMON-SERVER-SERVICE.cfg', starting on line 48)
Nagios Core 4.4.2
Copyright (c) 2009-present Nagios Core Development Team and Community Contributors
Copyright (c) 1999-2009 Ethan Galstad
Last Modified: 2018-08-16
License: GPL
Website: https://www.nagios.org
Reading configuration data...
Read main config file okay...
Error: Service has no hosts and/or service_description (config file '/usr/local/nagios/etc/services/COMMON-SERVER-SERVICE.cfg', starting on line 48)
Error processing object config files!
***> One or more problems was encountered while processing the config files...
Check your configuration file(s) to ensure that they contain valid
directives and data definitions. If you are upgrading from a previous
version of Nagios, you should be aware that some variables/definitions
may have been removed or modified in this version. Make sure to read
the HTML documentation regarding the config files, as well as the
'Whats New' section to find out what has changed.
Error: Service has no hosts and/or service_description (config file '/usr/local/nagios/etc/services/COMMON-SERVER-SERVICE.cfg', starting on line 48)
Nagios Core 4.4.2
Copyright (c) 2009-present Nagios Core Development Team and Community Contributors
Copyright (c) 1999-2009 Ethan Galstad
Last Modified: 2018-08-16
License: GPL
Website: https://www.nagios.org
Reading configuration data...
Read main config file okay...
Error: Service has no hosts and/or service_description (config file '/usr/local/nagios/etc/services/COMMON-SERVER-SERVICE.cfg', starting on line 48)
Error processing object config files!
***> One or more problems was encountered while processing the config files...
Check your configuration file(s) to ensure that they contain valid
directives and data definitions. If you are upgrading from a previous
version of Nagios, you should be aware that some variables/definitions
may have been removed or modified in this version. Make sure to read
the HTML documentation regarding the config files, as well as the
'Whats New' section to find out what has changed.
-
benjaminsmith
- Posts: 5324
- Joined: Wed Aug 22, 2018 4:39 pm
- Location: saint paul
Re: Unable to delete Host
Hi @Kxfrancois
Before making any other changes, I would recommend making a backup of your system or taking a VM snapshot.
https://assets.nagios.com/downloads/nag ... ios-XI.pdf
Make sure there is nothing in the import directory:
Open the file /usr/local/nagios/etc/services/COMMON-SERVER-SERVICE.cfg', and take a look a the service definition on line 48 for the errors described. Go to the CCM > Monitoring > Services and delete or correct this service, then go to to Configure > CCM > Tools > Config File Management, and click on Write and Verify to check for config errors. Repeat this process if necessary.
If you don't have any errors, click on Delete to remove all host and service configuration files. Next, apply configuration. The configs will be recreated with whatever is in the database.
If your not able to get it resolved, please PM me your system profile:
Login to the Nagios XI GUI using a web browser.
Click the "Admin" > "System Profile" Menu
Click the "Download Profile" button
Save the profile.zip file and upload it to a cloud storage of your choice. You can share a link with me in a personal message.
After you upload the profile please post something in this thread to bring it up in the support queue.
Before making any other changes, I would recommend making a backup of your system or taking a VM snapshot.
https://assets.nagios.com/downloads/nag ... ios-XI.pdf
Make sure there is nothing in the import directory:
Code: Select all
ls /usr/local/nagios/etc/import
If you don't have any errors, click on Delete to remove all host and service configuration files. Next, apply configuration. The configs will be recreated with whatever is in the database.
If your not able to get it resolved, please PM me your system profile:
Login to the Nagios XI GUI using a web browser.
Click the "Admin" > "System Profile" Menu
Click the "Download Profile" button
Save the profile.zip file and upload it to a cloud storage of your choice. You can share a link with me in a personal message.
After you upload the profile please post something in this thread to bring it up in the support queue.
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!
-
Kxfrancois
- Posts: 48
- Joined: Mon Nov 19, 2018 9:38 am
Re: Unable to delete Host
That Worked! Thank you so much for your help!
-
benjaminsmith
- Posts: 5324
- Joined: Wed Aug 22, 2018 4:39 pm
- Location: saint paul
Re: Unable to delete Host
Hi @Kxfrancois,
Great, and thanks for letting us know. Did you have any other questions or is it OK to close this post?That Worked! Thank you so much for your help!
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!
-
Kxfrancois
- Posts: 48
- Joined: Mon Nov 19, 2018 9:38 am
Re: Unable to delete Host
You can close this ticket.