Ubuntu – Wireless issues on 16.04 with RTL8821AE, ASUS E202S

kernelnetwork-managernetworking

I've recently purchased an Asus E202S desktop computer and tried to install Ubuntu 16.04 on it. I had no problems to install or make a dualboot with Windows 10, but the real problems started to show up almost an hour after I've finished the system installation.

Basically, my wifi is periodically "freezing" (The wifi signal shows that everything is ok, but I do not have Internet connection), and I am forced to restart the network-manager. Even after restarting the manager, sometimes my wifi won't show up on the list of available networks or will not work at all. I don't have any of these problems on Windows 10, and also my Internet speed is much faster.

I've been trying to find the problem for almost one week, and here are some of the dozens of cases which seemed to be the closest to mine:

 https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1482979
 http://askubuntu.com/questions/730430/wifi-connection-keeps-dropping-in-ubuntu-15-10-rtl8821ae
 https://ubuntuforums.org/showthread.php?t=2245164
 http://askubuntu.com/questions/797213/wireless-disconnect-issues-ubuntu-16-04-with-rtl8821ae
 http://askubuntu.com/questions/730430/wifi-connection-keeps-dropping-in-ubuntu-15-10-rtl8821ae

Even though I could find several people that had the same problem that I'm having, their solutions did not do me any good, and as a newbie ubuntu user, I'm not sure about how I should proceed in this situation.

Problem affects immediately if I uploading information like on Dropbox or via "scp" file transfer.
When freezing, ping command answer:

 ping: sendmsg: No buffer space available

My wireless information:
https://paste.ubuntu.com/23806837/

Also I've tried:

a.)

  sudo add-apt-repository ppa:hanipouspilot/rtlwifi
  sudo apt-get update
  sudo apt-get install rtlwifi-new-dkms

It makes connection a little bit stable, with this driver I can upload 30-40 mb instead of only 5mb, but after upload freezes again.

b.) If I boot with older kernel (3.19.8) networking is working perfect and two times faster. But!, only in shell because Xorg fail to start on this kernel with error:

 [   113.698] 003f:1bdf: 3F ILLEGAL EXTENDED X86 OPCODE!
 [   113.698] (II) VESA(0): Setting up VESA Mode 0x17F (1366x768)
 [   113.698] 0000:1fcf: 3F ILLEGAL EXTENDED X86 OPCODE!
 [   113.698] (II) VESA(0): VBESetVBEMode failed0000:1fcf: 3F ILLEGAL EXTENDED X86 OPCODE!
 [   113.698]
 [   113.698] (EE)
 Fatal server error:
 [   113.699] (EE) AddScreen/ScreenInit failed for driver 0
 [   113.699] (EE)

Can anyone help me to solve these issues?

Best Answer

RTL8821AE wifi drivers in Ubuntu 16.04 First thing first, you need to identify which device is being used in your hardware, to find it, I opened a terminal and wrote the following:

lspci | grep Wireless

The system replies with the following line 03:00.0 Network controller: Realtek Semiconductor Co., Ltd. RTL8821AE 802.11ac PCIe Wireless Network Adapter The model of the device (RTL8821AE) is very important, we will come back to this later. For some reason, realtek adapters have had a history of disconnects and signal drops, but, lucky for us there is an answer.

sudo apt-get install linux-headers-generic build-essential git 
git clone http://github.com/lwfinger/rtlwifi_new.git
cd rtlwifi_new
make
sudo make install

These commands build and install the drivers for rtl8192ce, rtl8192se, rtl8192de, rtl8188ee, rtl8192ee, rtl8723ae, rtl8723be, and rtl8821ae, all in one go. Just in case the system doesn’t load the appropriate kernel module, you can execute the following command from within your rtlwifi_new directory

sudo modprobe rtl8821ae

and reboot your system. Congratulations your Ubuntu Linux kernel now has working Realtek wireless drivers.