From owner-freebsd-questions@FreeBSD.ORG Thu Sep 8 20:36:34 2005 Return-Path: X-Original-To: freebsd-questions@freebsd.org Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6845D16A41F for ; Thu, 8 Sep 2005 20:36:34 +0000 (GMT) (envelope-from ihsan@dogan.ch) Received: from mail.blastwave.org (mail.blastwave.org [147.87.98.10]) by mx1.FreeBSD.org (Postfix) with ESMTP id B58E743D49 for ; Thu, 8 Sep 2005 20:36:33 +0000 (GMT) (envelope-from ihsan@dogan.ch) Received: from localhost (localhost [127.0.0.1]) by mail.blastwave.org (Postfix) with ESMTP id C51EBF8AE for ; Thu, 8 Sep 2005 22:36:31 +0200 (MEST) Received: from mail.blastwave.org ([127.0.0.1]) by localhost (enterprise [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 00742-04 for ; Thu, 8 Sep 2005 22:36:24 +0200 (MEST) Received: from defiant.dogan.ch (defiant.dogan.ch [213.144.141.146]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.blastwave.org (Postfix) with ESMTP id B7521F8A9 for ; Thu, 8 Sep 2005 22:36:23 +0200 (MEST) Received: by defiant.dogan.ch (Postfix, from userid 1000) id D0AEF17AC3; Thu, 8 Sep 2005 22:36:22 +0200 (CEST) Date: Thu, 8 Sep 2005 22:36:22 +0200 From: Ihsan Dogan To: FreeBSD Questions Message-ID: <20050908203622.GA13974@dogan.ch> Mail-Followup-To: FreeBSD Questions References: <20050905214641.GA28018@dogan.ch> <44fyshnf9l.fsf@be-well.ilk.org> <20050907142749.GA16981@dogan.ch> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20050907142749.GA16981@dogan.ch> User-Agent: Mutt/1.4.2.1i X-Operating-System: NetBSD/i386 1.6.2 X-Uptime: 10:30PM up 33 days, 1:32, 11 users, load averages: 2.97, 2.15, 2.00 X-Binford: 6100 (more power) X-Editor: Vim-603 http://www.vim.org X-Virus-Scanned: amavisd-new at blastwave.org Subject: Re: dhcrelay is setting the relay ip address wrong 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: Thu, 08 Sep 2005 20:36:34 -0000 On Wednesday, 07 Sep 2005 16:27 +0200, Ihsan Dogan wrote: > > The relay agent is acting exactly the way it should. When it gets a > > DHCP request in from a client, it uses its own address ON THE CLIENT'S > > NETWORK for the relay agent address. This way, the DHCP server can > > tell which network the client is on, and thus which set of addresses > > to use for assigning an address to the client. > > > > What is the problem? > > Perhaps I've sent this e-mail too early. I did some further > investigation and saw that: > select(7,{4 5 6},{},{},0x0) = 2 (0x2) > gettimeofday({1126033610 52754},0x0) = 0 (0x0) > read(0x6,0x806e000,0x1000) = 360 (0x168) > sendto(0x4,0xbfbfd950,0,0x0,{ AF_INET 213.144.141.146:67 },0x10) = 300 (0x12c) > write(2,0x8066cc0,62) = 62 (0x3e) > write(2,0x80620b8,1) = 1 (0x1) > recvfrom(0x4,0xbfbfe3a0,0,0x0,{ AF_INET 0.0.0.0:68 },0xbfbfe38c) = 300 (0x12c) > select(7,{4 5 6},{},{},0x0) = 1 (0x1) > gettimeofday({1126033610 72933},0x0) = 0 (0x0) > recvfrom(0x4,0xbfbfe3a0,0,0x0,{ AF_INET 213.144.141.146:67 },0xbfbfe38c) = 300 (0x12c) > > The dhcrelay is forwarding the request from the client correctly > to the server, but it does not forward the reply from the server > to the client. I've asked also on the ISC's dhcp server list and this is the answer I've got: ---------------------------------------------------------------- No, input from this socket is dropped. See 'fallback_discard' in common/socket.c. You're railing against a very commonly reported problem. The IO system was designed for the server and client (mostly for the server). It is poorly suited to the relay. Enhancements are on the wishlist for 3.1. ---------------------------------------------------------------- Ihsan... -- ihsan@dogan.ch http://ihsan.dogan.ch/