[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#700292: netcfg/choose_interface=auto fails to select eth1 when eth0 has no link



On Mon, Feb 11, 2013 at 04:44:50PM +0800, Paul Wise wrote:
> This is because the autoconfig code doesn't check the result of the link
> detection code and return that to upper layers (see below). 

I think I'm missing something. Why is the autoconfig code at fault?
We'll start in GET_INTERFACE, iterate over the interfaces and take
the first one we find that has a link. This one will land in defiface.
netcfg_get_interface will overwrite that if it finds a BOOTIF or
force it to the first interface if no defif was found yet.
If choose_interface is set to auto the interface name in the struct
will be set to defif.

Now I'm not sure why we're checking for a link in netcfg_autoconfig
again without error handling, but why does it try the wrong ifname in
the first place? In the auto selection process we should've picked
one earlier that had a link already in GET_INTERFACE.

Kind regards
Philipp Kern

Attachment: signature.asc
Description: Digital signature


Reply to: