Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 22 Nov 2006 15:50:39 +0100
From:      Thierry Lacoste <th.lacoste@wanadoo.fr>
To:        freebsd-questions@freebsd.org
Subject:   problems with check_dhcp in nagios
Message-ID:  <200611221550.40239.th.lacoste@wanadoo.fr>

next in thread | raw e-mail | index | archive | help
Hello,

I'm using nagios-2.4 with nagios-plugins-1.4.3,1 on FreeBSD 6.1-RELEASE-p10.
I have a problem to make check_dhcp work.

dhclient works as expected:
[root@rigel ~]# dhclient em0
DHCPREQUEST on em0 to 255.255.255.255 port 67
DHCPREQUEST on em0 to 255.255.255.255 port 67
DHCPDISCOVER on em0 to 255.255.255.255 port 67 interval 5
DHCPDISCOVER on em0 to 255.255.255.255 port 67 interval 8
DHCPOFFER from 194.214.13.3
DHCPOFFER from 194.214.13.2
DHCPOFFER already seen.
DHCPREQUEST on em0 to 255.255.255.255 port 67
DHCPACK from 194.214.13.3
bound to 194.214.13.6 -- renewal in 21600 seconds.

But check_dhcp doesn't work (with dhclient killed):
[root@rigel ~]# /usr/local/libexec/nagios/check_dhcp -i em0 -v
DHCP socket: 3
Hardware address: 000d56bd84c5
DHCPDISCOVER to 255.255.255.255 port 67
DHCPDISCOVER XID: 1804289383 (0x6B8B4567)
DHCDISCOVER ciaddr:  0.0.0.0
DHCDISCOVER yiaddr:  0.0.0.0
DHCDISCOVER siaddr:  0.0.0.0
DHCDISCOVER giaddr:  0.0.0.0
send_dhcp_packet result: 548




No (more) data received
Result=ERROR
Total responses seen on the wire: 0
Valid responses for this machine: 0
DHCP problem: No DHCPOFFERs were received.

The -s switch to specify the IP of a DHCP server doesn't help.

Using ethereal I can see one "DHCP Discover" packet sent  and
nothing else.
I don't know if it is relevant but I noticed that the source adress
of this packet is the IP of the machine while the source address
of  "DHCP Discover" packets issued by dhclient is 0.0.0.0.

Any tip would be appreciated.

Regards,
Thierry.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200611221550.40239.th.lacoste>