From owner-freebsd-net@FreeBSD.ORG Tue Apr 7 21:08:04 2015 Return-Path: Delivered-To: net@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 59A7DF99; Tue, 7 Apr 2015 21:08:04 +0000 (UTC) Received: from shell1.rawbw.com (shell1.rawbw.com [198.144.192.42]) by mx1.freebsd.org (Postfix) with ESMTP id 42036AE2; Tue, 7 Apr 2015 21:08:04 +0000 (UTC) Received: from yuri.doctorlan.com (c-50-184-63-128.hsd1.ca.comcast.net [50.184.63.128]) (authenticated bits=0) by shell1.rawbw.com (8.14.9/8.14.9) with ESMTP id t37L7vjd055834 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES128-SHA bits=128 verify=NO); Tue, 7 Apr 2015 14:07:58 -0700 (PDT) (envelope-from yuri@rawbw.com) X-Authentication-Warning: shell1.rawbw.com: Host c-50-184-63-128.hsd1.ca.comcast.net [50.184.63.128] claimed to be yuri.doctorlan.com Message-ID: <5524472C.1050905@rawbw.com> Date: Tue, 07 Apr 2015 14:07:56 -0700 From: Yuri User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:31.0) Gecko/20100101 Thunderbird/31.6.0 MIME-Version: 1.0 To: net@freebsd.org Subject: Re: [BUG?] dhclient sends packets with source IP address that has been deleted References: <55234B74.5020506@rawbw.com> <20150407145354.GA9746@spindle.one-eyed-alien.net> In-Reply-To: <20150407145354.GA9746@spindle.one-eyed-alien.net> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Cc: Brooks Davis X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 07 Apr 2015 21:08:04 -0000 On 04/07/2015 07:53, Brooks Davis wrote: > I suppose that since dhclient has been killed and restarted it can't > know it's on the same network, but in practice you want to try to get > the same lease again and fall back if it turns out you've moved or your dhcp > server is broken and lost state. I don't see how this would hurt anything. Let's say dhclient is restarted after a while (ex. after the reboot), when some other host already has that same IP address. dhclient sends the broadcast with it, and the response will be sent to another host, which currently has that address, and that other host will discard this response. dhclient keeps trying for many seconds, doesn't get any response. Then it falls back to sending from 0.0.0.0->255.255.255.255 (as it should have done in the first place), and immediately gets the valid response. The problem delays DHCP handshake, this is how this can hurt. dhclient comes from OpenBSD upstream. It has been discontinued in OpenBSD, due to them thinking it has a lot of problems. Maybe FreeBSD should also replace dhclient? Yuri