udhcp and busybox

Devin Bayer devin at freeshell.org
Mon Mar 27 22:04:06 UTC 2006


Rob Landley wrote:
> On Sunday 26 March 2006 11:58 pm, Devin Bayer wrote:
> 
>>On Mar 26, 2006, at 13:22, Rob Landley wrote:
>>
>>>On Sunday 26 March 2006 3:22 pm, Devin Bayer wrote:
>>>
>>>>If you do what you suggest and set a gateway when another is already
>>>>set, you'll bork the whole system.
>>>
>>>I do it all the time, actually, and the tools I'm using delete the old
>>>gateway.  I can ifconfig the interface down first to be sure, though.
>>>
>>>If somebody runs a dhcp client on eth0 and another one on eth1,
>>>they'll
>>>probably need a script.  That's not my problem.
>>
>>Well that's tough to overcome. What if I make it a config option?
>>Essentially to support multiple network interfaces one needs to do:
> 
> Running a script as a config option, sure.  Supporting multiple simultaneous 
> _upstream_ networking interfaces internally?  Seems overcomplicated for the 
> common use case, and the script is an easy way to punt.

My whole gripe is with the script. The C is only about 3 lines for ifup and udhcpc, how is
that overcomplicated?  If you think more then one interface is too uncommon to
support why does ifconfig, route, ifup, ifdown, and others support interface options?

> Even the common case of a router wouldn't need this, because you only run the 
> dhcp _client_ on one interface.

In the common case of a router, you do need this. If you have a running
system with a gateway and then run udhcpc, it'll create two gateways and knock your
system off all the networks.

Well, that's all I have to say; I won't argue anymore.

-- 
Devin Bayer



More information about the busybox mailing list