Networking Question

Matt Graham mhgraham at crow202.org
Mon Dec 9 20:26:31 MST 2019


On 2019-12-09 19:39, Michael Butash wrote:
> Linux networkmanager will assign a higher metric on non-ethernet
> interfaces (ideally) to de-preference wireless over wired, but they
> still both get an address.  In the same subnet, the metric is what
> determines preference.  You can tweak metrics, but usually depend on
> the network interface and system preferences.

This makes sense.  The machine where I had 2 NICs on the same subnet, 1 
wired, 1 wireless, had the wired NIC with metric 203 and the wireless 
one with metric 304 in the output from "route -n".  Network Manager was 
not involved; just dhcpcd.  OTOH, dhcpcd probably understands what 
"wired" and "wireless" are and sets up the routes and metrics 
accordingly.  I think that if I set the metrics for enp1s0 and wlp3s0 to 
the same number, I'd get the terrible network problems I described 
earlier.

> This has been a problem for decades, but generally managed by
> networking stack setting metric preference on routes.  Wired == best,
> wireless, vpn, others, less. [...] This is standard networking.

This is actually the first time I've heard of the "metric" thing in the 
kernel routing table.  This is probably because almost all of the 
machines I've dealt with over the last 20 years have had pretty simple 
networking configurations.

-- 
Crow202 Blog: http://crow202.org/wordpress
There is no Darkness in Eternity
But only Light too dim for us to see.


More information about the PLUG-discuss mailing list