On Mon, Sep 10, 2001 at 09:35:24AM -0700, Ulf Zimmermann wrote:
> > Come to think of it, it might be as easy as: [**UNTESTED**]
> >
> > case ${ifconfig_args}; in
> > [Dd][Hh][Cc][Pp]*)
> > set $ifconfig_args
> > shift
> > ifconfig_add_args="$*"
> > ......
> >
> > ..provided there is a requirement that the ifconfig_args should *start*
> > with 'dhcp' (which would be easy enough to meet - right now, the args
> > have to *be* 'dhcp', so any additional arguments would be stapled on at
> > the end).
>
> This sounds as the best solution. This would allow to set an interface
> to be DHCP (variable dhcp_interfaces get set) and take the rest of the
> arguments (like media/mediaopt) and apply them to the interface before
> the dhclient gets started.
If you want to go this route, make dhcp be the last argument not the
first one. If ifconfig understood dhcp (on my todo list) it would have
to be the last argument if you wanted it to work reliably because args
are processed in order and if your interface requires that you set the
media before it works, it's not going to work very well to run dhcp and
then fix the media. At least making dhcp be last insures that it will
continue to work once ifconfig grows dhcp support[*].
-- Brooks
[*] No ifconfig will not contain any DHCP code, it will simply call a
script which calls your choice of dhcp clients. It's just lame that we
have variables that are supposidly ifconfig commands, but which won't
actually work.
--
Any statement of the form "X is the one, true Y" is FALSE.
PGP fingerprint 655D 519C 26A7 82E7 2529 9BF0 5D8E 8BE9 F238 1AD4
PGP signature