Removing an host ?

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Locked
nissim
Posts: 4
Joined: Thu May 04, 2017 9:17 am

Removing an host ?

Post by nissim »

Hi,

How can I remove an HOST from Nagios Core ?
Last edited by dwhitfield on Mon May 08, 2017 8:58 am, edited 1 time in total.
Reason: marking with green check mark
tmcdonald
Posts: 9117
Joined: Mon Sep 23, 2013 8:40 am

Re: Removing an host ?

Post by tmcdonald »

You will need to also remove any services which are attached to that host, as well as any children or dependencies. But basically you either remove the config entry or delete the file altogether.
Former Nagios employee
nissim
Posts: 4
Joined: Thu May 04, 2017 9:17 am

Re: Removing an host ?

Post by nissim »

Thank you for the quick answer.

Could you mention which files are they to be modified/removed ?

Thanks.
tmcdonald
Posts: 9117
Joined: Mon Sep 23, 2013 8:40 am

Re: Removing an host ?

Post by tmcdonald »

I can't really answer that for you because I did not set up your system. Did someone else set this up and you are now in charge of maintaining it? If so, I would talk to that person and try to get some documentation on how they have it set up. Otherwise, you will want to do a grep or otherwise search in the config files to find your host definition.

Our documentation on object definitions might be of use: https://assets.nagios.com/downloads/nag ... tions.html
Former Nagios employee
nissim
Posts: 4
Joined: Thu May 04, 2017 9:17 am

Re: Removing an host ?

Post by nissim »

thanks again.

I have managed to:
- removed host's file from: /etc/nagios/host directory
- removed host from /etc/nagios/hostgroup/webserver.cfg file
- /etc/rc.d/init.d/nagios reload

it maybe help some people, eventhough the strauczture can be different.

Regards Nissim
dwhitfield
Former Nagios Staff
Posts: 4583
Joined: Wed Sep 21, 2016 10:29 am
Location: NoLo, Minneapolis, MN
Contact:

Re: Removing an host ?

Post by dwhitfield »

Thanks so much for posting. Did you have any other questions or are we ready to lock the thread?
nissim
Posts: 4
Joined: Thu May 04, 2017 9:17 am

Re: Removing an host ?

Post by nissim »

you can close... I will surely have more questions, as I'm new to Nagios...

Thanks & Regards

Nissim
Locked