Combining some info here:
# Onboard adapter that doesn't work
enp6s0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 192.168.0.10 netmask 255.255.255.0 broadcast 192.168.0.255
net driver: name = r8169, path = /bus/pci/drivers/r8169
E: ID_PCI_SUBCLASS_FROM_DATABASE=Ethernet controller
E: ID_VENDOR_FROM_DATABASE=Realtek Semiconductor Co., Ltd.
E: ID_MODEL_FROM_DATABASE=RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller (Onboard Ethernet)
# USB that does work
enxa0cec8041c6a: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 192.168.0.15 netmask 255.255.255.0 broadcast 192.168.0.255
net driver: name = ax88179_178a, path = /bus/usb/drivers/ax88179_178a
E: ID_USB_SUBCLASS_FROM_DATABASE=Vendor Specific Subclass
E: ID_VENDOR_FROM_DATABASE=ASIX Electronics Corp.
E: ID_MODEL_FROM_DATABASE=AX88179 Gigabit Ethernet
Diagnosing this using a static IP adds more plausible issues it could be, i’d strongly recommend going back to DHCP for diagnosis.
As a simple thing to start with, try pinging your router:
# Get router IP if you don have it:
ip r | grep default
ping ROUTER_IP_HERE
What’s interesting is the id model is: RTL8111/8168/8411
But the driver it’s using is: r8169
The r8168-dkms package is bingo on all the model#'s in your device:
"r8168 is the Linux device driver released by RealTek for their network
controllers with PCI-Express interface:
- 10/100/1000M Gigabit Ethernet: RTL8111B, RTL8111C, RTL8111D, RTL8111E,
RTL8111F, RTL8111G(S), RTL8111H(S), RTL8118(A)(S), RTL8119i, RTL8111L,
RTL8168B, RTL8168E, RTL8168H, RTL8111DP, RTL8111EP, RTL8111FP, RTL8411,
RTL8411B"
Try installing it and do a reset:
sudo apt install r8168-dkms
Confirm it’s in use after reset:
hwinfo | grep "net driver: name ="
It should not say: net driver: name = r8169, path = /bus/pci/drivers/r8169
If that doesn’t work, please give me the result from the following command so I can dig a bit more:
sudo lspci | grep "Ethernet controller"