I have a Rock960 board running Ubuntu server. It suffers from a "bug" where SSH is extremely laggy because WiFi power management is turned on.
I've tried various solutions to permanently disable it:
- Wifi power management turns back on when connecting
- How can I prevent iwconfig power management from being turned on?
- Adding a
powersave
option to my specific SSID configuration
None of them work (permanently). Something on the system is forcing power management on a few seconds after it's turned off, whether manually or through some config file. I've fixed this by running a bash script via rc.local
which polls iw
every few seconds and disables power management if it's turned on. This works, but it's frustrating not knowing what the actual problem is. Even running a cronjob every minute isn't enough.
The system is using NetworkManager as far as I can tell, but none of the configuration overrides seem to work.
Is there a way of figuring out what's enabling power management (perhaps via a log)?
The script, in case anyone finds it useful:
#!/bin/bash
management_off="Power Management: off"
while true; do
status=`/sbin/iw wlan0 | grep "Power Management"`
if [ "$status" != "$management_off" ]; then
/sbin/iw wlan0 set power_save off
fi
sleep 5
done
tlp
? https://askubuntu.com/questions/545841/installing-tlp-power-save-stopped-my-wifi-adapter-from-working – WinEunuuchs2Unix Jun 17 '19 at 15:18/etc/default/tlp
hasWIFI_PWR_ON_AC=off
andWIFI_PWR_ON_BAT=off
. – Josh Jun 18 '19 at 16:26cron
job to turn it off every minute: https://unix.stackexchange.com/questions/269661/how-to-turn-off-wireless-power-management-permanently – WinEunuuchs2Unix Jun 18 '19 at 17:19