WiFi module 8812AU not working with kernel version >= 4.4.0-28-generic
Problem
I had a Linksys WUSB 6300 dual-band USB WiFi adapter happily running on on my desktop PC with driver module 8812AU.
When I first got it to work I used the driver signing method to get it to work with Secure Boot. It worked fine with Kernel version 4.4.0-23-generic and later also with 4.4.0-24-generic where I resigned it after the update.
After the update to 4.4.0-28-generic resigning for some reason does not have the desired effect anymore and it does not seem to load the driver module 8812AU.
After updating to 4.4.0-38-generic the behavior remains the same.
The Additional Drivers tool now shows me this, so I am not sure if somehow the module files got messed up. I am pretty new to Ubuntu, so I wouldn't know how to tell. When it was still working it showed me this.
So in consequence the network adapter is not working and I am out of ideas what to check or do in order to get it back to work.
Details
lsusb
shows me that the adapter is recognized as USB device:
Bus 002 Device 002: ID 13b1:003f Linksys WUSB6300 802.11a/b/g/n/ac Wireless Adapter [Realtek RTL8812AU]
sudo lshw -C network
only shows me the Ethernet and the internal WiFi (it has a very similar name). It is an integrated WiFi adapter which is working poorly under Ubuntu and is thus not useful for me.
Note: 8821AE is the internal WiFi. I am trying to get 8812AU to run which is not listed here because it does not seem to be loaded.
*-network
description: Ethernet interface
product: RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller
vendor: Realtek Semiconductor Co., Ltd.
physical id: 0
bus info: pci@0000:03:00.0
logical name: enp3s0
version: 11
serial: 54:a0:50:d5:4b:0b
size: 10Mbit/s
capacity: 1Gbit/s
width: 64 bits
clock: 33MHz
capabilities: pm msi pciexpress msix vpd bus_master cap_list ethernet physical tp mii 10bt 10bt-fd 100bt 100bt-fd 1000bt 1000bt-fd autonegotiation
configuration: autonegotiation=on broadcast=yes driver=r8169 driverversion=2.3LK-NAPI duplex=half firmware=rtl8168g-2_0.0.1 02/06/13 latency=0 link=no multicast=yes port=MII speed=10Mbit/s
resources: irq:42 ioport:e000(size=256) memory:f7d00000-f7d00fff memory:f0000000-f0003fff
*-network
description: Wireless interface
product: RTL8821AE 802.11ac PCIe Wireless Network Adapter
vendor: Realtek Semiconductor Co., Ltd.
physical id: 0
bus info: pci@0000:04:00.0
logical name: wlp4s0
version: 00
serial: 54:27:1e:d6:91:8d
width: 64 bits
clock: 33MHz
capabilities: pm msi pciexpress bus_master cap_list ethernet physical wireless
configuration: broadcast=yes driver=rtl8821ae driverversion=4.4.0-22-generic firmware=N/A ip=192.168.0.20 latency=0 link=yes multicast=yes wireless=IEEE 802.11abgn
resources: irq:46 ioport:d000(size=256) memory:f7c00000-f7c03fff
Running rfkill list all
shows that nothing seems to be blocked:
0: hci0: Bluetooth
Soft blocked: no
Hard blocked: no
1: phy0: Wireless LAN
Soft blocked: no
Hard blocked: no
Any help would be greatly appreciated!
Many thanks.
This package can be fixed by editing the dkms.conf files...
sudo -H gedit /usr/src/rtl8812au-4.3.8.12175.20140902+dfsg/dkms.conf
Then change line 4 from MAKE="'make' all"
to MAKE="'make' all KVER=${kernelver}"
Save and exit the editor then do the same with:
sudo -H gedit /var/lib/dkms/rtl8812au/4.3.8.12175.20140902+dfsg/build/dkms.conf
As a similar problem was reported on Ubuntu Forums and my edits have worked for the last kernel update I got.
For your current kernel you should be able to:
dkms build rtl8812au/4.3.8.12175.20140902+dfsg -k $(uname -r)
dkms install rtl8812au/4.3.8.12175.20140902+dfsg -k $(uname -r)
Reboot
Here is a quick script that I wrote to manually fix a broken rtl8812au-dkms driver issue that occurs after every kernel software update. Run the script with sudo
after a kernel software update has occurred. The problem with this driver is that dkms builds it for the wrong kernel. It's a problem with dkms.conf, in the source code. I may have a permanent fix pending.
You can tell if you've got a kernel module load error
in /var/log/syslog at boot time. In terminal, a modinfo 8812au
will show vermagic as incorrect.
#!/bin/bash
# save as ~/Desktop/fix_8812au.sh
# in terminal: chmod +x ~/Desktop/fix_8812au.sh
# in terminal, run with: sudo ~/Desktop/fix_8812au.sh
cd /var/lib/dkms
# rtl8812au
dkms remove rtl8812au/4.3.8.12175.20140902+dfsg -k "$(uname -r)/$(uname -p)"
dkms build rtl8812au/4.3.8.12175.20140902+dfsg -k "$(uname -r)/$(uname -p)"
dkms install rtl8812au/4.3.8.12175.20140902+dfsg -k "$(uname -r)/$(uname -p)"
Update: the user was also using an older version of the 8812au driver, so we installed the current version of rtl8812au-dkms
from the repositories, and it all worked. The script will be required immediately after the next kernel software update.
Update #2: the proper fix (thanks @Jeremy31) for this bug is to edit these two files:
gksudo gedit /usr/src/rtl8812au-4.3.8.12175.20140902+dfsg/dkms.conf gksudo gedit /var/lib/dkms/rtl8812au/4.3.8.12175.20140902+dfsg/build/dkms.conf and replace MAKE="'make' all" with this line: MAKE[0]="'make' all KVER=${kernelver}"