Linux – How to Turn Off Wireless Power Management Permanently

linuxpower-managementwifi

In Linux Mint 17.3 / 18 iwconfig says the power management of my wireless card is turned on. I want to turn it off permanently or some workaround on this issue.

sudo iwconfig wlan0 power off works, until I reboot the laptop.

Also, if I randomly check iwconfig, sometimes it's on, despite I did run this command.

I read some articles about making the fix permanent. All of them contained the first step "Go to directory /etc/pm/power.d", which in my case did not exist.

I followed these steps:

sudo mkdir -p /etc/pm/power.d
sudo nano /etc/pm/power.d/wireless_power_management_off

I entered these two lines into the file:

#!/bin/bash

/sbin/iwconfig wlan0 power off

And I finished with setting proper user rights:

sudo chmod 700 /etc/pm/power.d/wireless_power_management_off

But after reboot the power management is back on.

iwconfig after manually turning power management off

eth0      no wireless extensions.

wlan0     IEEE 802.11abgn  ESSID:"SSID"  
          Mode:Managed  Frequency:2.462 GHz  Access Point: 00:00:00:00:00:00   
          Bit Rate=24 Mb/s   Tx-Power=22 dBm   
          Retry short limit:7   RTS thr:off   Fragment thr:off
          Power Management:off
          Link Quality=42/70  Signal level=-68 dBm  
          Rx invalid nwid:0  Rx invalid crypt:0  Rx invalid frag:0
          Tx excessive retries:2  Invalid misc:18   Missed beacon:0

lo        no wireless extensions.

I don't think this question applies only to Linux Mint, it is a general issue of particular wireless adapters.

Best Answer

Open this file with your favorite text editor, I use nano here:

sudo nano /etc/NetworkManager/conf.d/default-wifi-powersave-on.conf

By default there is:

[connection]
wifi.powersave = 3

Change the value to 2. Reboot for the change to take effect.


Possible values for the wifi.powersave field are:

NM_SETTING_WIRELESS_POWERSAVE_DEFAULT (0): use the default value
NM_SETTING_WIRELESS_POWERSAVE_IGNORE  (1): don't touch existing setting
NM_SETTING_WIRELESS_POWERSAVE_DISABLE (2): disable powersave
NM_SETTING_WIRELESS_POWERSAVE_ENABLE  (3): enable powersave

(Informal source on GitHub for these values.)

Related Question