Change the power button behavior
To customize the action of the power button, you can change its default behavior both when GNOME is running and when it is not running.
Change the behavior of the power button when GNOME is not running Copy linkLink copied!
To prevent the system from shutting down when you press the power button, modify settings for the non-graphical systemd target. Select the option according to requirement.
Before you begin Copy linkLink copied!
- You have administrative privileges.
Change the behavior of the power button in GNOME Copy linkLink copied!
To prevent the system from suspending when you press the power button, modify settings for the GNOME login screen and user session. You can select one of the options: physically on a system or virtually from a remote console.
Before you begin Copy linkLink copied!
- You have administrative privileges.
Results Copy linkLink copied!
- Press the power button and check if the system performs the action you configured.