Disabling Sleep / Hybernate / Suspend not working

I want to disable sleep / hybernate / suspend on i3. I found How to Completely disable sleep/hibernate/suspend? which tells me to do

sudo systemctl mask sleep.target suspend.target hibernate.target hybrid-sleep.target

However, my screen still goes blank after a while. How can i prevent this?
I’m on a fresh install, my pc does not use a password at login (checked that in the installer), just in case that matters.

Thank you very much!

There might be other (better) ways to do this but I installed xfce4-power-manager to manage the power settings of the system:

Set the desired values or disable altogether.

two different things :wink:

Display powermanagement is not handled by resume it is handled by xset in ~/.config/i3/config:

Modify DPMS and screensaver settings with a command

It is possible to turn off your monitor with the xset command which is provided by the xorg-xset package.


Command Description
xset s off Disable screen saver blanking
xset s 3600 3600 Change blank time to 1 hour
xset -dpms Turn off DPMS
xset s off -dpms Disable DPMS and prevent screen from blanking
xset dpms force off Turn off screen immediately
xset dpms force standby Standby screen
xset dpms force suspend Suspend screen

There are better ways to do this.

1 Like

your way works too i would bet?
But seems a bit “bloated” to install power management GUI to disable it in its own settings :melting_face:

1 Like

It does.


1 Like

Thank you, this seems to have done the trick!

Do i need to undo

sudo systemctl mask sleep.target suspend.target hibernate.target hybrid-sleep.target

If i recall correctly, this just creates symlinks, should i delete them?

If you are not going to use suspension, hibernation etc. you could leave it as it is.
systemctl mask just creates links into /dev/null, that is into “nothingness” sort of.
At anytime later on, you can enable them as needed.

What do i need to to in case that i want to use suspension / hibernation again?

You could unmask them at any time (systemctl unmask) enable them and set up the service you need.
Please refer to ArchWiki for power management, suspension, hibernation etc.

1 Like

Thank you!

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.