in power settings I configured the power button to suspend and it works, however the system still shuts down when it is in login screen after pressing the power button. is there anyway to fix this?

  • 1
    Just to confirm, you would like pressing the power button while on the login screen to suspend the machine, correct?
    – linux_tim
    Feb 20, 2018 at 16:26

1 Answer 1


I believe this to be a solution for what you're wanting to do:

  1. Open a Files window as admin by right clicking Files and selecting "New Window as Administrator.

  2. Navigate in the File System to /etc/systemd and open logind.conf with Scratch Text Editor.

  3. Directly below the line reading #HandlePowerKey=poweroff add a new line of text reading:


  4. Close Scratch to save the file then close all other windows and reboot your machine.

Once you reboot, when you are presented the Login Screen you can test the results by pressing the power button which should suspend the machine, not power it off. Now, on my machine at least, when I pressed the power button it took about 3-5 seconds for the machine to suspend.

Hope this answers your question and good luck!!!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.