Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 19 Oct 2009 11:56:34 -0400
From:      David Horn <dhorn2000@gmail.com>
To:        Doug Barton <dougb@freebsd.org>
Cc:        freebsd-net@freebsd.org, Brooks Davis <brooks@freebsd.org>
Subject:   Re: Wacky DHCP values that work in windows but not in FreeBSD
Message-ID:  <25ff90d60910190856t6d0df42cn7e75fc14046220d9@mail.gmail.com>
In-Reply-To: <4ADBFA55.9060601@FreeBSD.org>
References:  <4AD3ABD0.7010603@FreeBSD.org> <25ff90d60910122030r1f8511e9ued9535024fa3078a@mail.gmail.com> <4AD410CB.2060105@FreeBSD.org> <25ff90d60910122255j5ccae96ar7c58488209768956@mail.gmail.com> <4ADBFA55.9060601@FreeBSD.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, Oct 19, 2009 at 1:34 AM, Doug Barton <dougb@freebsd.org> wrote:
> I'm adding Brooks to the cc list since he is mr. dhcp lately. :)
>
> David Horn wrote:
>> On Tue, Oct 13, 2009 at 1:31 AM, Doug Barton <dougb@freebsd.org> wrote:
>>> David Horn wrote:
>>>> Without seeing the actual tcpdump of the dhcp packets, I would guess
>>>> that this is the Classless Static Route option in DHCPv4 (option 121).
>>> Ok, I will give the tcpdump option a go as soon as I have a chance.
>
> I finally had a chance to look at this again (with your revised
> tcpdump command line from another mail of yours) and I think you're
> right. The log (http://people.freebsd.org/~dougb/tcpdump.log)
> definitely mentions Classless-Static-Route. This was with the stock
> dhclient in -current. I also tried ISC's 4.1.1b3 just to be sure, and
> that did not work either.
>

According to the tcpdump, the client does specify that it supports
option 121 in the request, but the server does not in the reply, so my
guess was inaccurate.

> I also tried the various incarnations of route that were suggested on
> this thread, including all 4 combinations with/without -iface and
> -hopcount, and none of that worked either.
>
> Quick recap, I got the following from dhcp:
> Your-IP 76.244.161.xxx
> Subnet-Mask Option 1, length 4: 255.255.0.0
> Default-Gateway Option 3, length 4: 151.164.184.xxx
>
> Now what DID work was something I tried on a whim. Actually two things
> worked, 'route add default 76.244.161.1' and (after rebooting) 'route
> add default 76.244.0.1'. With either of those I could reach things
> both inside the network (like the name server) and out in the wide world.
>
> I have no idea WHY those worked, I suspect that Mike Smith was right
> and there is some sort of proxy-arp going on, but I'm far from a
> networking expert.
>
> I'll leave the tcpdump log up for a while if y'all think it's useful.
> I can also test patches for this if someone comes up with a fix.
>
>
> Doug
>
>
>>> Meanwhile, if this is in fact the case how would we make it work in
>>> FreeBSD? Is there a newer version of DHCP that handles this properly?
>>
>> I thought that dhclient originated from ISC, but looking at the
>> 4.1.1b2 ISC DHCP source and at the OpenBSD dhclient, I did not see
>> option 121 handling in dhclient. =A0The freebsd copy of both dhclient.c,
>> and /sbin/dhclient-script there is code for handling this option. =A0 I
>> guess the FreeBSD version split from the ISC version at some point,
>> and option 121 handling was added (2+ years ago).
>>
>> As far as fixing/debugging, it all depends on the exact dhcp options
>> and values. =A0It might just be a tweak to /sbin/dhclient-script, or it
>> may be more complicated.
>>
>> http://www.freebsd.org/cgi/cvsweb.cgi/src/sbin/dhclient/dhclient.c
>> Revision 1.21: download - view: text, markup, annotated - select for dif=
fs
>> Fri Feb 9 17:50:26 2007 UTC (2 years, 8 months ago) by emaste
>> Branches: MAIN
>> CVS tags: RELENG_7_BP, RELENG_7_0_BP, RELENG_7_0_0_RELEASE, RELENG_7_0
>> Branch point for: RELENG_7
>> Diff to: previous 1.20: preferred, colored
>> Changes since revision 1.20: +68 -0 lines
>>
>> Implement RFC3442, the Classless Static Route option.
>>
>> The original DHCP specification includes a route option but it supports
>> only class-based routes. =A0RFC3442 adds support for specifying the netm=
ask
>> width for each static route. =A0A variable length encoding is used to mi=
nimize
>> the size of this option.
>>
>> PR: =A0 =A0 =A0 =A0 =A0 =A0 bin/99534
>> Submitted by: =A0 Andrey V. Elsukov <bu7cher@yandex.ru>
>> Reviewed by: =A0 =A0brooks
>>
>> ---Dave H
>>
>
>
> --
>
> =A0 =A0 =A0 =A0Improve the effectiveness of your Internet presence with
> =A0 =A0 =A0 =A0a domain name makeover! =A0 =A0http://SupersetSolutions.co=
m/
>
>



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