Skip to main content
186 votes

How to turn off Wireless power management permanently

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 ...
Niko's user avatar
  • 1,884
41 votes

How does the kernel know it's resuming from hibernation, not booting?

Hibernation works by using a swap partition¹ to swap out all processes' memories, the kernel state, finally save some state of CPU and possibly other devices, then power off. On the way, it notes in ...
Marcus Müller's user avatar
40 votes

Turning off power to usb port. Or turn off power to entire usb subsystem

You could use my tool uhubctl - command line utility to control USB power per port for compatible USB hubs. It works only on hubs that support per-port power switching, but note that many modern ...
mvp's user avatar
  • 498
36 votes

Debian 10 — adjust sleep settings via command line

I ran into this with gdm3 after upgrading to Debian 10: whenever the computer was left at the initial login screen, it would go to sleep after a while. To fix this, I had to edit the power settings ...
Stephen Kitt's user avatar
31 votes

Why are some Intel family 6 CPU models (Core 2, Pentium M) not supported by intel_idle?

While researching Core 2 CPU power states ("C-states"), I actually managed to implement support for most of the legacy Intel Core/Core 2 processors. The complete implementation (Linux patch) ...
Parker's user avatar
  • 799
27 votes

Debian 10 — adjust sleep settings via command line

you can try the following based on your needs: Disable suspend and hibernation: sudo systemctl mask To re-enable hibernate and ...
Ahmad Abuhasna's user avatar
26 votes

Why is Ubuntu power consumption lower than non-free Debian?

Part of the reason Ubuntu has gotten a reputation for being easier to install is that it has contained a lot of non-free firmware for a long time. That site even says so (indirectly though). As @...
Henrik supports the community's user avatar
24 votes

What are the implications of setting the CPU governor to "performance"?

For the record, the (up-to-date) cpufreq documentation is here. What does "statically" mean?To me, it contrasts with "dynamic", and implies frequency would never change, i.e. with powersave the ...
don_crissti's user avatar
  • 83.3k
23 votes

How to Reset/Cycle Power to a PCIe Device?

Resets in PCI express are a bit complex. There are two main types of resets - conventional reset, and function-level reset. There are also two types of conventional resets, fundamental resets and ...
alex.forencich's user avatar
18 votes

How to disable the power saving for snd_hda_codec_realtek?

It appears that the snd_hda_codec_realtek module does not support power saving, unlike snd_hda_intel. If you are using PulseAudio, it will suspend any audio sources that have become idle for too long....
Tim's user avatar
  • 198
18 votes

Why is Ubuntu power consumption lower than non-free Debian?

In Linux, power management is completely user-configurable. Without knowing how the power management was configured in each case, the comparison is meaningless. It is possible, for example, that ...
Jörg W Mittag's user avatar
17 votes

Ubuntu Server Continuously "goes to sleep"

On Ubuntu 16.04 LTS, I successfully used the following to disable suspend: sudo systemctl mask And this to re-enable it: sudo ...
Dustin Kirkland's user avatar
17 votes

upowerd consuming 100% cpu

Do you have an iphone connected to the computer? This happens to me whenever I connect my iphone to it. Linux arjun-thinkpad 4.4.7-1-lts #1 SMP Thu Apr 14 17:26:39 CEST 2016 x86_64 GNU/Linux
user128063's user avatar
16 votes

How to poweroff when there's no systemd/init (e.g. using init=/bin/bash)?

I will simply execute below two commands: echo s > /proc/sysrq-trigger <= For sync echo o > /proc/sysrq-trigger <= For shutdown the system Assuming magic key is enabled in kernel
SHW's user avatar
  • 14.9k
15 votes

Shutdown my (backup) hard disk on Linux when I don't use it

Short lookup in gnome-disk-utility repo code, and: udisksctl power-off -b /dev/sdX Works in Ubuntu and Mint. In ArchLinux, /usr/bin/udisksctl is owned by udisks2 package. Source: Superuser SE ...
Croll's user avatar
  • 380
14 votes

How do I make my laptop sleep when it reaches some low battery threshold?

As of Debian ≥ 10 (and comparably recent Linux systems), you can just create a file /etc/cron.d/check-battery that contains: * * * * * root [ "$(cat /sys/class/power_supply/BAT0/status)" != ...
vog's user avatar
  • 409
14 votes

How do I make my laptop sleep when it reaches some low battery threshold?

Instead of hacking your own scripts and if you are using Ubuntu as the tag suggests, you could just install the upower package. It should be available on all Debian derivatives including Ubuntu. By ...
josch's user avatar
  • 365
12 votes

How to set power button to shutdown instead of suspend?

As @don_crissti explained, the situation is silly because it really isn't possible to just shutdown without confirmation using the normal settings. However, there's a workaround: if the chassis type ...
Lorenzo Pistone's user avatar
12 votes

How do I find out which application is disabling sleep?

Under Freedesktop-compliant environments, including XFCE4, sleep inhibition is communicated via D-Bus on the org.freedesktop.PowerManagement bus. I can't find any documentation about this; the xfce4 ...
Gilles 'SO- stop being evil''s user avatar
12 votes

How to poweroff when there's no systemd/init (e.g. using init=/bin/bash)?

Unmount the filesystems that you had mounted. The root filesystem is a special case; for this you can use mount / -o remount,ro. On Linux, umount / also happens to work, because it is effectively ...
sourcejedi's user avatar
12 votes

Is there a better way than this to force monitor blank/off?

If you’re using X, xset dpms force off will switch the display off. Under Wayland with GNOME, you can activate the screensaver, which will blank the screen if it’s configured to do so normally: ...
Stephen Kitt's user avatar
11 votes

How to turn off Wireless power management permanently

It is not sufficient to turn off wireless power management at boot. There are probably hooks like if I plug off power adapter. So one of possible solutions is as follows; step-by-step. Create a ...
Vlastimil Burián's user avatar
11 votes

How to permanently disable EEE (Energy Efficient Ethernet) on Ethernet card?

No such kernel parameter exists. However, there are other ways to achieve your goal than an @reboot cron job. If you're using NetworkManager, you could create a pre-up dispatcher script (e.g. /etc/...
telcoM's user avatar
  • 99.4k
10 votes

How to find reason a notebook wakes up?

For the sake of completeness, there is another solution mentioned in this answer to a similar question. Awakened by power button: $ sudo dmidecode | grep Wake-up Wake-up Type: Power Switch ...
10 votes

Hard disk not going to standby automatically

i'm running ubuntu 18.04 and had this same issue. thanks to @allo's answer, i found out the smartd is indeed the cause. by default the /etc/smartd.conf is configured like this: DEVICESCAN -d removable ...
mo-han's user avatar
  • 211
9 votes

How can I get an alert when my battery is about to die in Linux Mint?

With the help of all the information from all the answers here I created a script and put it in a repository on GitLab. It'll show notifications when: Your cable is unplugged and the battery goes ...
gitaarik's user avatar
  • 589
9 votes

How to turn off Wireless power management permanently

TLP - Linux Advanced Power Management Tool works for me out of the box both in Ubuntu 18.04 and 20.04. shell> grep WIFI /etc/default/tlp WIFI_PWR_ON_AC=off WIFI_PWR_ON_BAT=off shell> iw dev ...
Vladimir Botka's user avatar
9 votes

Automatic shutdown after no activity

You could just edit /etc/systemd/logind.conf, uncommenting these lines: IdleAction=hibernate IdleActionSec=120min If you want to shutdown, then use poweroff instead of hibernate. Note: You need to ...
Quasímodo's user avatar
  • 18.9k
8 votes

Return value of current watt consumption on command line

sudo tlp-stat -b It will show the current power consumption in milli Watt unit. --- TLP 1.1 -------------------------------------------- +++ Battery Status /sys/class/power_supply/BAT1/manufacturer ...
rtnF14's user avatar
  • 81

Only top scored, non community-wiki answers of a minimum length are eligible