Sample Header Ad - 728x90

How to make Realtek nic use r8168 driver

1 vote
1 answer
4300 views
I've been trying (unsuccessfully) for the last few days to make my Realtek ethernet card to work. I have no problems with my wireless connection: only the ethernet connection doesn't work. I have Ubuntu 16.10 on a Dell Inspiron, with a RTL8101/2/6E PCI Express card. The card used the r8169 driver, which seems to be buggy and unreliable (as in [here](https://unix.stackexchange.com/questions/134878/make-linux-load-specific-driver-for-given-device-realtek-nic)) . Since the solution seems to be to use the r8168 driver, I: * installed the package r8168-dkms via apt-get, * blacklisted the r8169 module in /etc/modprobe.d/ * rebooted. It didn't work, as lsmod still listed the module as in use, and lspci -v still told me that the card was using the r8169 driver and module. I finally managed to blacklist the module passing the option to grub, by adding modprobe.blacklist=r8169 to the default command line in /etc/default/grub. The problem is that the r8168 module loads fine (I see it in lsmod), but it's not associated with the card so it doesn't show up in ifconfig (exactly as it happened to [lumi](https://unix.stackexchange.com/users/27995/lumi) in https://unix.stackexchange.com/questions/134878/make-linux-load-specific-driver-for-given-device-realtek-nic) . This is the relevant portion of my lshw -C network: *-network UNCLAIMED description: Ethernet controller product: RTL8101/2/6E PCI Express Fast/Gigabit Ethernet controller vendor: Realtek Semiconductor Co., Ltd. physical id: 0 bus info: pci@0000:01:00.0 version: 07 width: 64 bits clock: 33MHz capabilities: pm msi pciexpress msix vpd bus_master cap_list configuration: latency=0 resources: ioport:3000(size=256) memory:b0600000-b0600fff memory:b0400000-b0403fff My device: > lspci -v -s 01:00 01:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8101/2/6E PCI Express Fast/Gigabit Ethernet controller (rev 07) Subsystem: Dell RTL8101/2/6E PCI Express Fast/Gigabit Ethernet controller Flags: bus master, fast devsel, latency 0, IRQ 11 I/O ports at 3000 [size=256] Memory at b0600000 (64-bit, non-prefetchable) [size=4K] Memory at b0400000 (64-bit, prefetchable) [size=16K] Capabilities: Please note that in the output above lspci does not show any drivers nor kernel modules in use. Finally, I tried to make my NIC to use the r8168 driver (as explained in this [answer](https://unix.stackexchange.com/a/141414)) , to no avail: % sudo echo 10ec 8168 > /sys/bus/pci/drivers/r8168/new_id /sys/bus/pci/drivers/r8168/new_id: File exists. % sudo echo "0000:01:00.0" > /sys/bus/pci/drivers/r8168/bind /sys/bus/pci/drivers/r8168/bind: File exists. What am I missing? Is there another way to tell a device to use a driver? Any links, clues or indications about what to read next would be helpful and very much appreciated.
Asked by cristianbravolillo (11 rep)
May 29, 2017, 05:12 PM
Last activity: Jun 1, 2025, 09:04 PM