From owner-freebsd-questions@FreeBSD.ORG Wed Nov 22 14:52:30 2006 Return-Path: X-Original-To: freebsd-questions@freebsd.org Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 4C7AB16A415 for ; Wed, 22 Nov 2006 14:52:30 +0000 (UTC) (envelope-from th.lacoste@wanadoo.fr) Received: from ultra1.univ-paris12.fr (ultra1.univ-paris12.fr [193.51.100.100]) by mx1.FreeBSD.org (Postfix) with ESMTP id F13D343D82 for ; Wed, 22 Nov 2006 14:50:22 +0000 (GMT) (envelope-from th.lacoste@wanadoo.fr) Received: from st-simon.miage.univ-paris12.fr (localhost [127.0.0.1]) by ultra1.univ-paris12.fr (8.13.8/8.13.8) with ESMTP id kAMEof1g018286 for ; Wed, 22 Nov 2006 15:50:45 +0100 (MET) Received: from sirius.miage.univ-paris12.fr (sirius.miage.univ-paris12.fr [194.214.13.28]) by st-simon.miage.univ-paris12.fr (Postfix) with ESMTP id 02F6847281A for ; Wed, 22 Nov 2006 15:50:41 +0100 (CET) From: Thierry Lacoste To: freebsd-questions@freebsd.org Date: Wed, 22 Nov 2006 15:50:39 +0100 User-Agent: KMail/1.9.4 MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200611221550.40239.th.lacoste@wanadoo.fr> Subject: problems with check_dhcp in nagios X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 22 Nov 2006 14:52:30 -0000 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.