Vero4k, latest OSMC running.
When connecting WiFi and Ethernet, routing table was showing that route to local network preferred WiFi instead of ethernet. Whereas default route was preferring ethernet. This would be extremely confusing to someone checking throughput, having an issue with wifi and then trying to stream media from a local or remote media server.
As a workaround, i put the following into /etc/rc.local (after “apt install ifmetric”)
ifmetric eth0 10
ifmetric wlan0 20
I think this is probably a good final solution too, except that it shouldn’t be in /etc/rc.local, but some system config file, ideally where the interface is brought up, so it works not only after boot, but after configuring either interface via kodi or plugging in the ethernet when the box is already booted.
Routing is handled by ConnMan (our connection manager).
It’s pretty niche to connect both interfaces at once – so this is probably a good enough workaround.
ConnMan doesn’t implement ifup.d support – so the best solution would be to create a systemd unit that executes after ConnMan is online. You can see the wait for network target which we have.
Not sure if it is such a niche. I figure that one wants to use WiFi and then if it turns out to be too slow, and then hook up ethernet. But why unconfigure wifi at that moment ? I don’t think a normal user would think about that. So, if its not too difficult for you to add the workaround you describe, that would be peachy.
I of course hooked up ethrnet only because the 3D studdering issue, so i thought it was a network issue (too little throughput on wifi), but after going through the chores with ethernet, i also reproduced from local disk.
After a reboot, we should only connect to Ethernet as the preferred technology.
I guess for the lay person its certainly easier to understand that only ethernet will be used if ethernet is plugged in, so yes, you could change the startup so that wifi would not be enabled if ethernet is running.
I am a fan of automatic redundancy. For a long time i had rasperrys as set top boxes where actually the ethernet started to fail unexpectedly (extended via powerline adapters that sucked). And the user had no IT certificate, so automatically switching back to wifi was nice in that case. But definitely a more advanced case.
WiFi is not enabled on boot if Ethernet is active. There is no behaviour to change here.
If the Ethernet cable is removed, WiFi will then be activated.