Page 1 of 1

Nagios IP Change

Posted: Mon Jun 18, 2018 8:47 am
by donnyforbes
I notice something yesterday. Somehow on Centos 7x my ip address changed for my nagios server not sure how this happened since the server was set to "static" and NOT dhcp. Anyhow since it change I was getting all kinds of email alerts etc and even calls from PagerDuty. I need to change the IP to something different then what it is. What is the best way to do this so there is no issues with nagios?

Re: Nagios IP Change

Posted: Mon Jun 18, 2018 1:02 pm
by scottwilkerson
Nagios doesn't actually care one your system is registered. (although agents expecting connections from a specific IP will complain).

You simply modify the IP per standard procedure for the OS you are using.

Re: Nagios IP Change

Posted: Mon Jun 18, 2018 4:48 pm
by donnyforbes
Do I need to do anything to the agents? We have both Linux and windows?

Re: Nagios IP Change

Posted: Mon Jun 18, 2018 5:05 pm
by scottwilkerson
donnyforbes wrote:Do I need to do anything to the agents? We have both Linux and windows?
If you are changing back to the IP you had before no. Otherwise you will need to modify the allowed_from or only from addressed if configured on the agents

Re: Nagios IP Change

Posted: Tue Jun 19, 2018 9:27 am
by donnyforbes
scottwilkerson wrote:
donnyforbes wrote:Do I need to do anything to the agents? We have both Linux and windows?
If you are changing back to the IP you had before no. Otherwise you will need to modify the allowed_from or only from addressed if configured on the agents
Does the allowed hostsname need to be an ip address or can it be a DNS name? This is what I have now see attachment.

Re: Nagios IP Change

Posted: Tue Jun 19, 2018 9:56 am
by scottwilkerson
I believe IP only but you can add multiple with mask such as

Code: Select all

allowed_hosts=192.168.1.0/24,192.168.5.0/25,192.168.10.0/24

Re: Nagios IP Change

Posted: Tue Jun 19, 2018 10:12 am
by donnyforbes
scottwilkerson wrote:I believe IP only but you can add multiple with mask such as

Code: Select all

allowed_hosts=192.168.1.0/24,192.168.5.0/25,192.168.10.0/24
ok thank you.

Re: Nagios IP Change

Posted: Tue Jun 19, 2018 11:00 am
by scottwilkerson
Are we ok to mark this issue resolved?