How to remove the host from monitoring

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
Pratapa
Posts: 144
Joined: Tue Oct 01, 2019 1:33 am

How to remove the host from monitoring

Post by Pratapa »

Hi,

We have a requirement. We need to remove host1 from monitoring. But host1 is the parent to host2.
When we remove host1 from monitoring we are getting error.

host1 is in Unreachable state. There is one service on host1 and it is showing Unknown state.
host2 is in OK state and all the services on host2 are in OK state.

Following are the host definitions of the host1 and host2

define host {
use switch-host-template
host_name host1
alias ad Switch
address x.x.x.x
parents host3
}


define host {
use ups-host-template
host_name host2
alias ad UPS
address x.x.x.x
parents host1
}


Please suggest how to proceed.


Regards,
Pratap.
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: How to remove the host from monitoring

Post by scottwilkerson »

Remove the parent line from host2 and remove host1

Change the config you showed to

Code: Select all

define host {
use ups-host-template
host_name host2
alias ad UPS
address x.x.x.x
}
Former Nagios employee
Creator:
ahumandesign.com
enneagrams.com
Pratapa
Posts: 144
Joined: Tue Oct 01, 2019 1:33 am

Re: How to remove the host from monitoring

Post by Pratapa »

Thanks. I did the same.

I commented out parent line and then removed host1 and it got removed sucessfully.

Thank you.
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: How to remove the host from monitoring

Post by scottwilkerson »

Pratapa wrote:Thanks. I did the same.

I commented out parent line and then removed host1 and it got removed sucessfully.

Thank you.
Great!

Locking thread
Former Nagios employee
Creator:
ahumandesign.com
enneagrams.com
Locked