7

When I am on wifi and then plug in the Ethernet cable the internet connection switches to the latter (three-box symbol), but after pause it is back to wifi and I do not know how to return to Ethernet (which I want since much faster). Unplugging and reconnecting the cable doesn't affect the selection of wifi. I only found older (pre-18.04) recipes that do not work.

I switched wifi off, took USB-C adapter out and back in, got network icon symbol, am on network (500 Mbps download) but the icon symbol changed to ?.

Output of sudo lshw -C network

  *-network DISABLED        
       description: Wireless interface
       product: Wireless 8265 / 8275
       vendor: Intel Corporation
       physical id: 0
       bus info: pci@0000:02:00.0
       logical name: wlp2s0
       version: 78
       serial: f8:34:41:49:8c:e3
       width: 64 bits
       clock: 33MHz
       capabilities: pm msi pciexpress bus_master cap_list ethernet physical wireless
       configuration: broadcast=yes driver=iwlwifi driverversion=5.0.0-29-generic firmware=36.9f0a2d68.0 latency=0 link=no multicast=yes wireless=IEEE 802.11
       resources: irq:135 memory:d0000000-d0001fff
  *-network:0 DISABLED
       description: Ethernet interface
       physical id: 3
       logical name: wwp0s20f0u2i12
       serial: 12:c1:b8:08:68:e9
       capabilities: ethernet physical
       configuration: broadcast=yes driver=cdc_mbim driverversion=22-Aug-2005 firmware=CDC MBIM link=no multicast=yes
  *-network:1
       description: Ethernet interface
       physical id: 4
       logical name: enx0050b692363f
       serial: 00:50:b6:92:36:3f
       size: 1Gbit/s
       capacity: 1Gbit/s
       capabilities: ethernet physical tp mii 10bt 10bt-fd 100bt 100bt-fd 1000bt 1000bt-fd autonegotiation
       configuration: autonegotiation=on broadcast=yes driver=r8152 driverversion=v1.09.9 duplex=full ip=192.168.178.10 link=yes multicast=yes port=MII speed=1Gbit/s

3 Answers3

15

Open the terminal application and type:

nm-connection-editor

On the window that opens, select your Wired Connection and click the gear icon at the bottom of the window to edit it. You need to select the General tab, enable "Connect automatically with priority", and change the priority to 1. This will prioritize the ethernet connection.

Understand that:

  • Ubuntu normally auto-selects the connection with the best performance.

  • If you have an ethernet connectivity problem, that would explain why your connections keep on switching.

  • Check that your USB-C port doesn't power itself down at idle... you may have to check BIOS settings for that.

enter image description here

heynnema
  • 73,649
2

It was hardware: my Toshiba USB-C Travel adaptor (PA5272U-2PRP). The problem persisted many weeks in which I worked mostly on wifi. After much hesitation (expense) I bought a similar adaptor: Goobay USB-C Premium Multiport dock. It works flawlessly.

0

When you plug in your Ethernet cable, turn on Airplane Mode. The wireless network will not be used. When you unplug the Ethernet cable, turn off Airplane Mode.

Airplane Mode is a setting that is easily toggled on and off in Ubuntu using just a few clicks.

For GNOME, open your Wi-Fi settings and switch "Airplane Mode" to ON

See also: Turn Airplane Mode on/off via terminal

You are probably searching for an automated solution, but this is a solution nonetheless that will work 100% (and there's nothing automated about physically connecting and disconnecting an Ethernet cable anyway)

Nmath
  • 12,664