Multiple NICs

David Kelly dkelly at
Mon Nov 29 14:20:20 PST 2004

> None of the above work  (ie: they both make the default route go through
>  an0 - wifi - and i suspect this is because the wifi dhcp is slower to
> answer than the ethernet one), so i ended up commenting out the wifi
> line (an0) and activating it by hand when needed... However this is
> quite troublesome as it means killing the dhclient running, before
> running another dhclient an0... If anybody has a better suggestion for
> me I would be quite grateful!

A good place to start surfing in looking for solutions to this sort of
thing is /etc/defaults/rc.conf.

As you have discovered, the order of items listed in /etc/rc.conf doesn't
matter. That is because one literally is setting values of variables
there. Its some time later before those variables are actually used. If
you wish to continue this direction you might kill your dhclient process
which is running on fxp0 then manually start it again "dhclient fxp0". If
that results in the route you wish then you might be able to control the
start order with this in /etc/rc.conf:

network_interfaces="lo0 an0 fxp0"

Another thought from /etc/defaults/rc.conf is to set
defaultrotuer="" (change to the real address your ISP provides. But
reading "man dhclient.conf" I think dhclient will clobber any static route
on lease renewal no matter if you set it by hand or with crafted interface
start order. So go read that man page and edit your /etc/dhclient.conf

The solution may lie in "man dhcp-options"

More information about the freebsd-questions mailing list