When you have an Intel WiFi chipset that's not too ancient, it'll run on the iwlwifi driver (old Intel chipsets might use the iwlegacy driver of the ipw2200 driver).
In certain circumstances you may need a newer iwlwifi driver for your Intel wireless card, than the one that's available by default in Linux Mint and Ubuntu. For getting that, you have the following options:
Contents of this page:
- 1. Check whether you're using the iwlwifi driver
- 2. Bad wireless connection: generic measure for improving it
- 3. Try toggling some iwlwifi driver options
- 4. Preparation for installing a newer iwlwifi driver
- 5. The officially backported iwlwifi driver
- 6. The iwlwifi driver straight from upstream
Check whether you're using the iwlwifi driver
1. First check whether your WiFi chipset actually runs on the iwlwifi driver:a. Launch a terminal window.
(You can launch a terminal window like this: *Click*)
b. Use copy/paste to transfer this line into the terminal:
lsmod | grep iwlwifi
Press Enter.
Does the terminal output contain the word iwlwifi (in red letters)? If so, proceed with the next step.
Bad wireless connection: generic measure for improving it
2. This applies when you do have a connection, at least from time to time, but the quality stinks: low speed, unstable or flaky.In some cases a simple tweak is sufficient for increasing the connection quality a lot. Namely disabling the power management for the wireless chipset. The speed of your wireless internet may then increase also.
No worries: this tweak won't disable power management for your entire machine. It'll only disable it for the WiFi chipset.
a. First you need to find out whether Mint applies power management to your WiFi chipset. For this, launch a terminal window.
(You can launch a terminal window like this: *Click*)
b. Type in the terminal:
iwconfig
Press Enter.
You can then not only see the name for your wireless chipset (for example: wlp2s0), but also whether Power Management is on for it. When it's off, you still need to apply the hack mentioned below, because installing a newer driver might turn it on after all.
Proceed as follows:
c. Use copy/paste for transferring the following blue line into the terminal (don't try to type it!):
sudo sed -i 's/3/2/' /etc/NetworkManager/conf.d/default-wifi-powersave-on.conf
Press Enter. Type your password when prompted. In Ubuntu this remains entirely invisible, not even dots will show when you type it, that's normal. In Mint this has changed: you'll see asterisks when you type. Press Enter again.
d. Reboot your computer.
e. Then check in the terminal, by the command iwconfig, whether Power Management for the wireless chipset is off now.
If so, and if your connection is better now, you're done! If it's not better, proceed with item 3 below.
Try toggling some iwlwifi driver options
3. In certain cases your current iwlwifi driver already performs better when certain options are toggled, in which case it doesn't need to be replaced. Which is why you should try that first.You can do that as follows:
a. Launch a terminal window.
(You can launch a terminal window like this: *Click*)
b. Copy/paste the following blue command line into the terminal (this is one long line, don't chop it up!):
echo "options iwlwifi bt_coex_active=0 swcrypto=1 11n_disable=8" | sudo tee /etc/modprobe.d/iwlwifi-3options.conf
Press Enter. Type your password when prompted. In Ubuntu this remains entirely invisible, not even dots will show when you type it, that's normal. Press Enter again.
Hereby you achieve three things:
- With bt_coex_active=0 you disable the Bluetooth feature of the WiFi chipset, which sometimes interferes;
- With swcrypto=1 you shift the signal encryption from the hardware (WiFi chipset) to the software, thus taking some load off the WiFi chipset;
- With 11n_disable=8 you enable antenna aggregation (Tx AMPDU). Don't be confused because of the option name 11n_disable: when its value is set to 8 it does not disable anything, but enables transmission antenna aggregation (Tx AMPDU).
c. Reboot your computer.
d. No improvement? Then undo this hack, by removing the file that contains the toggled options, with this terminal command:
sudo rm -v /etc/modprobe.d/iwlwifi-3options.conf
Reboot your computer and proceed with item 3.1 below.
Waking sleeping hardware (PCIe card)
3.1. Certain hardware parts (PCIe cards) might be sent into an eternal sleep by an overly active power management. Among the known victims are some Intel wireless cards.In those cases it might help to disable power management for all PCIe cards. The obvious trade-off of this hack is of course, that this'll increase the power consumption of your computer. Anyway, this is how to do it, if your wireless chipset is a PCIe card from Intel:
a. Launch a terminal window.
(You can launch a terminal window like this: *Click*)
b. Use copy/paste to transfer this command line into the terminal (avoid typos, so don't try to type it):
dmesg | grep D3cold
Press Enter.
Does the output show one or more lines with Unable to change power state in it? Then proceed as follows:
c. Use copy/paste to transfer this command line into the terminal:
xed admin:///etc/default/grub
(the three consecutive slashes are intended and no typo!)
Press Enter. Type your password when prompted.
d. In the text file that opens, find the following line:
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"
Add the parameter pcie_port_pm=off, so that it becomes:
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash pcie_port_pm=off"
Save the modified file and close it.
e. Use copy/paste to transfer this command line into the terminal:
sudo update-grub
(note the dash between update and grub!)
Press Enter.
f. Reboot your computer and test.
No avail? Then undo it (remove pcie_port_pm=off from the line in /etc/default/grub and run sudo update-grub again) and proceed with step 4 below.
Preparation for installing a newer iwlwifi driver
4. Now you need to prepare your system for installing a newer driver. Proceed like this:a. First establish temporary internet connection for your computer by means of your cell phone.
b. Launch a terminal window.
(You can launch a terminal window like this: *Click*)
c. Copy/paste the following command line into the terminal:
sudo apt-get install mokutil && mokutil --sb-state
Press Enter. Type your password when prompted. In Ubuntu this remains entirely invisible, not even dots will show when you type it, that's normal. In Mint this has changed: you'll see asterisks when you type. Press Enter again.
If it reports that Secure Boot is enabled: reboot and disable Secure Boot in the BIOS. In order to do this, you might need to set an administrator password in the BIOS first.
Disabling Secure Boot is no loss: it adds no meaningful security anyway. It's primarily a means for Microsoft to enforce its vendor lock-in on your computer...
Proceed with the next step.
The officially backported iwlwifi driver
5. The first replacement driver version to try is the officially backported iwlwifi driver. Install it like this:a. First establish temporary internet connection for your computer by means of your cell phone.
b. Launch a terminal window.
(You can launch a terminal window like this: *Click*)
c. Copy/paste the following command line into the terminal, in order to install it:
sudo apt-get install backport-iwlwifi-dkms
Press Enter. Type your password when prompted. In Ubuntu this remains entirely invisible, not even dots will show when you type it, that's normal. In Mint this has changed: you'll see asterisks when you type. Press Enter again.
d. Reboot your computer.
The iwlwifi driver straight from upstream
6. Still no avail? The final option is the iwlwifi driver straight from upstream at kernel.org. For installing that, you can proceed as follows:a. First establish temporary internet connection for your computer by means of your cell phone.
b. Launch a terminal window.
(You can launch a terminal window like this: *Click*)
c. First copy/paste the following command line into the terminal, in order to install the application git:
sudo apt-get install git
Press Enter. Type your password when prompted. In Ubuntu this remains entirely invisible, not even dots will show when you type it, that's normal. In Mint this has changed: you'll see asterisks when you type. Press Enter again.
d. Then download the driver packages with the following command (use copy/paste):
git clone git://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git
Press Enter. Note: it's a big download of several hundred MB's, so this may take a while!
e. Now go to the folder with the driver, by executing this command:
cd linux-firmware
Press Enter.
f. Then from that folder, move the new driver to the right location, with this command (use copy/paste):
sudo cp -v -u iwlwifi* /lib/firmware
Press Enter.
g. Now acquaint your system with the new driver, by means of this terminal command (use copy/paste):
sudo update-initramfs -uk all
Press Enter.
h. Reboot your computer. Your wireless Intel card should now run on the new driver.
i. Then launch a terminal and clean up the considerable amount of debris with this command (use copy/paste):
rm -v -r -f ~/linux-firmware
Press Enter.
j. Finally, use the following command to lock the package linux-firmware to its current version, in order to prevent potential future problems by updates:
sudo apt-mark hold linux-firmware
Press Enter.
Want more tips?
Do you want more tips and tweaks? There's a lot more of them on this website!
For example:
Speed up your Linux Mint!
Clean your Linux Mint safely
Avoid 10 fatal mistakes
To the content of this website applies a Creative Commons license.
Back to the home page
Disclaimer