Page 2 of 2

Re: check_dhcp failing after 2.1 upgrade

Posted: Tue Dec 23, 2014 3:16 pm
by cmerchant
Sorry if i'm repeating myself, could you tell us if a schedule a force immediate check works? Could you show us the view text config from:

Config --> Services --> select your service --> Click on Diskette Icon (view text config) and show us the output. Thanks.

Re: check_dhcp failing after 2.1 upgrade

Posted: Mon Jan 05, 2015 10:25 am
by XenoPhage
cmerchant wrote:Sorry if i'm repeating myself, could you tell us if a schedule a force immediate check works?
No, that doesn't work either.
cmerchant wrote:Could you show us the view text config from:

Config --> Services --> select your service --> Click on Diskette Icon (view text config) and show us the output. Thanks.

Code: Select all

define service {
	service_description		DHCP Service Check
	use				service-server-standard
	hostgroup_name			dhcp-server-standard
	servicegroups			dhcp-server-standard
	check_command			check_dhcp!192.168.1.1!"c0:ff:ee:15:c0:01"!!!!!!
	register			1
	}
Yes, I have changed the IP and the MAC here. No, that's not the IP of the DHCP server, that is the IP I'm requesting. This does work via CLI, and it does work via the "Test Check Command" interface. It simply does not work for a normal check, forced or otherwise.

Here's the output from "Test Check Command" :

Code: Select all

COMMAND: /usr/local/nagios/libexec/check_dhcp -u -s 192.168.0.1 -r 192.168.1.1 -m "c0:ff:ee:15:c0:01" -t 5
OUTPUT: OK: Received 1 DHCPOFFER(s), 1 of 1 requested servers responded, requested address (192.168.1.1) was offered, max lease time = 86400 sec.

Re: check_dhcp failing after 2.1 upgrade

Posted: Mon Jan 05, 2015 10:57 am
by bdgoecke
We were able to duplicate your issue, and am looking into the cause. We will post a fix as soon as we can.

In the mean time if you can use 7 or less arguments that command should work correctly.

==>brian.

Re: check_dhcp failing after 2.1 upgrade

Posted: Mon Jan 05, 2015 11:18 am
by XenoPhage
bdgoecke wrote:We were able to duplicate your issue, and am looking into the cause. We will post a fix as soon as we can.

In the mean time if you can use 7 or less arguments that command should work correctly.

==>brian.
Hrm.. ok. That doesn't seem to be working, though. I dropped the "-t 5" argument which should put me at exactly 7 arguments. Forcing a check doesn't work. Test Check Command doesn't work either.

Note : I upgraded to R2.3 this morning and that broke the Test Check Command again, though..

Re: check_dhcp failing after 2.1 upgrade

Posted: Mon Jan 05, 2015 1:20 pm
by bdgoecke
Sorry. I was off by 1, that should be 6 or less arguments.

==>brian.

Re: check_dhcp failing after 2.1 upgrade

Posted: Mon Jan 05, 2015 1:25 pm
by scottwilkerson
Ok, we have narrowed this down and have a fix.

Open /usr/local/nagiosxi/scripts/restart_nagios_with_export.sh
On line 44 replace

Code: Select all

sudo ./manage_services.sh restart nagios
with

Code: Select all

./manage_services.sh restart nagios
Also, unzip the attachment and place file in /usr/local/nagiosxi/cron
cmdsubsys.zip
Finally, apply configuration through the Web UI

Re: check_dhcp failing after 2.1 upgrade

Posted: Mon Jan 05, 2015 2:23 pm
by XenoPhage
scottwilkerson wrote:Ok, we have narrowed this down and have a fix.
Ah, excellent. That worked. This fix will make it into R2.4?

Re: check_dhcp failing after 2.1 upgrade

Posted: Mon Jan 05, 2015 3:30 pm
by lmiltchev
This fix will make it into R2.4?
Most probably - it's a small change.

I am glad your issue has been resolved! I am locking this topic.