• Disable power button


    Hi, everyone! I’m trying to disable power button on my laptop. Currently if I press it, my system suspends. I’ve tried to google and find out that systemd should be able to do just that. All I had to do - is just edit /etc/systemd/logind.conf. From logind.conf man page I find out, that in order to disable power button I should set “HandlePowerKey” to “ignore”. I rebooted but it didn’t work, so I thought maybe system sees button not like “PowerKey” but like “SuspendKey” or “HibernateKey” so just to be sure I set both of them to “ignore”. But nothing changed - after I press “power button” system suspends. I started to think maybe this file is ignored by “systemd-logind” for some reason, but then I tried to change “HandleLidSwitch” to “lock” and it worked! (well, kind of - default action when I close the lid is suspend now it locks but the screen turns off). So it means that logind.conf is not ignored but for some reason it doesn’t work for power button.

    Edit: Couldn’t figure out how to add proper “solved” badge, so I just edited question’s title.
    Sorry for my poor English.

  • It should be posssible to change through your desktop environment settings, which one do you use?

  • Thank you! While I was typing you the reply that there is no such option in Gnome’s settings I remembered about gnome-tweak-tool and turns out that it has what I’m looking for! I still don’t understand why this option is not included in settings. Thank you again)

systemd30 logind.conf2 systemd-logind1 Posts 3Views 1231
Bloom Email Optin Plugin

Looks like your connection to Antergos Community Forum was lost, please wait while we try to reconnect.