Slow WiFi with Ubuntu 18.04 and Intel Dual Band Wireless-AC 3168

This is my story with an Intel Dual Band Wireless-AC 3168 (M.2 2230) and Ubuntu Linux:

  1. I decide to manually update Ubuntu 16.04 LTS, including the kernel/dist-upgrade thing.
  2. Reboot.
  3. No WiFi connection, iwconfig command returns no adapters.
  4. While testing several reboots, I notice the wireless adapter sometimes appears and works.
  5. I decide to install Ubuntu 18.04 LTS from scratch in another hard drive.
  6. Boot live USB image (18.04.0 Desktop), go to desktop.
  7. I try Internet connection, I notice WiFi is very slow, like ancient times.
  8. I plug Ethernet cable and perform a minimal Ubuntu installation with last downloaded updates.
  9. Reboot, unplug Ethernet cable.
  10. I try Internet connection, WiFi is very slow.
  11. I search for solutions, I disable 802.11n (iwlwifi 11n_disable=1), WiFi works (connection speed is lower than 11Mbps), even after reboots.
  12. Not satisfied with solution, I decide to ask here and run Ubuntu forums network script.
  13. Network script result is HERE.

Related question threads I found:

  • Wireless Internet Issues - Intel Wireless, Ubuntu 18.04
  • Slow wifi since updating to 18.04
  • iwlwifi Wifi Microcode SW error detected (Ubuntu 18.04 x64)
  • Wifi Issue with Ubuntu 18.04
  • Internet Connection

Solution 1:

What I did to solve this issue is installing the latest stable kernel, according to kernel.org that is at the time of writing 4.17.13.

I installed ukuu, the ubuntu kernel update utility using the ppa from "Tony George" (https://launchpad.net/~teejee2008/+archive/ubuntu/ppa):

sudo add-apt-repository ppa:teejee2008/ppa
sudo apt update
sudo apt install ukuu

Then run ukuu either through the console (ukuu --help) or use the graphical version which can be found in the menu. Install the latest stable kernel and reboot.

Warning: There might be some issues; if they persist after a reboot, during the boot sequence, select your old kernel version (4.15 on my machine).

Solution 2:

tldr; Fix your drivers before you attempt to update your kernel.

My laptop has:

  • Ubuntu 18.04 with xubuntu-desktop
  • 32GB RAM
  • 3TB HD
  • 1070 GTX Cuda Core
  • Intel 9560 Wireless AC + BT5

I too had no better than 3.8 Mbps connection speeds after completing the base installation of Ubuntu 18.04 LTS.

With ample support of a Linux Driver Engineer at Intel, a solution! <-- Full Bugzilla Ticket.

I don't want to have to enumerate the steps comprehensively, but... don't update your kernel. Kernel updates have a nasty way of trouble-making. Besides, that's boiling the ocean. After all, your drivers are just not quite in the right state.

Instead, try this:

  1. Clone https://git.kernel.org/pub/scm/linux/kernel/git/iwlwifi/linux-firmware.git/
  2. Clone https://git.kernel.org/pub/scm/linux/kernel/git/iwlwifi/backport-iwlwifi.git/
  3. Install the latest driver on your system.

    $ cd backport-iwlwifi
    $ sudo make && make install
    # Fix any errors by installing any missing pkgs. Ignore warnings.
    # The system will tell you to reboot on success, DON'T ... yet.
    # Keep reading. Copy some firmware first! :)
    
  4. For Intel users: Delete all the firmware files for your Intel wireless from /lib/firmware/. It will be all the iwlwifi-*.ucode files that must go. Copy them away if you feel like having a backup is wisest, so why the heck not?

  5. Copy the newest firmware from the linux-firmware repo to your firmware directory (/lib/firmware/). These should also be iwlwifi-*.ucode files, like so:

    $ cd /path/to/linux-firmware
    $ sudo cp iwlwifi-9260-th-b0-jf-b0-38.ucode /lib/firmware/
    $ sudo cp iwlwifi-9000-pu-b0-jf-b0-38.ucode /lib/firmware/
    # NOTE: I run a 9560 M.2 NIC, but you may not...
    
  6. Now, reboot. You should be in business. You may run speedtest.net and rejoice.

<3 and :)