You are not logged in.
Pages: 1
Hi,
The problem is simple. Arch doesn't see that I pressed the power button in any way. I tried xev to see the key-code but nothing shows. If I press any other button it show the code, but not the power button.
How can I make Arch see that I actually pressed the damn key. Turning of my laptop by entering the terminal every time is quite frustrating.
Thanks for any reply
Offline
I used to use acpid for it, but since moving to systemd, I hear that it can replace acpid. --- How ? I am not quite sure since I haven't had the time to change it and also because its not as critical to me as my machine is always on.
There's no such thing as a stupid question, but there sure are a lot of inquisitive idiots !
Offline
Check out logind.conf man pages.
#/etc/systemd/logind.conf
[Login]
...
HandlePowerKey=poweroff
HandleSuspendKey=pm-suspend
...
Offline
If the button is not being recognized at all, make sure you have the 'button' module loaded, as this is typically what is in charge of that function. I have always thought that it is quite the creative name fore a module....
Offline
Confirmed on the T520, with the "button" module loaded. Every other function key will work with systemd out-of-the-box (Fn + F4 suspends to RAM, for example) or can be mapped to a script, but not the power button. I never use the power button, so I don't mind, but it's never worked to my recollection.
Offline
That is interesting indeed. Are you a systemd user, or still sticking with sysv for now? Handling the power button is actually the default I believe., but maybe it would be worth checking? The relevent info is found in the logind.conf man page.
Edit: I have this in my journal, maybe knowing this might help you debug:
Oct 19 23:56:59 arch64-think systemd-logind[291]: Watching system buttons on /dev/input/event3 (Power Button)
There is also another line nearly identical, but indicates /dev/input/event1, so which one is the power button for real? I don't know.
Last edited by WonderWoofy (2012-10-20 14:58:10)
Offline
I'm a systemd user since I had my fresh Arch install nearly a week ago (very glad about my choice btw). Everything else works out of the box (except for suspending...but thats the fault of the intel driver, which is a known bug for my T400). As Šaran advised I looked in my logind.conf. Everything is fine as you showed. Still nothing. The button module is also loaded. Still nothing.
My journal said:
Oct 22 22:15:59 Calenthe kernel: input: Power Button as /devices/LNXSYSTM:0...t3
Oct 22 22:15:59 Calenthe kernel: ACPI: Power Button [PWRF]
So he sees it...looks like my laptop is not blind but stupid.
edit. as ANOKNUSA said this is not just a problem with my configuration only. This may be a bug. The problem is whose fault is that. Is it Acpi's or systemd's or what...
Last edited by Ziomalon (2012-10-22 20:43:27)
Offline
I have a T420S and noticed the same thing. Pressing the Power button has no effect. But, if I hold it down for about 1.5 seconds, then it works as expected. Does this work for others?
Offline
I have a T420S and noticed the same thing. Pressing the Power button has no effect. But, if I hold it down for about 1.5 seconds, then it works as expected. Does this work for others?
Um, no.
A quick press of the button is supposed to send a message to the OS to initiate a controlled operation; sleep, shutdown, ask the user what to do, etc...
Pressing and HOLDING the button tells the hardware to just power off, regardless of whether the OS is ready or not. I recommend you not do this except in rare conditions, with the understanding you are risking the integrity of your file systems.
Nothing is too wonderful to be true, if it be consistent with the laws of nature -- Michael Faraday
Sometimes it is the people no one can imagine anything of who do the things no one can imagine. -- Alan Turing
---
How to Ask Questions the Smart Way
Online
Well, if it is truly reacting to 1.5 seconds, it may actually be that it is sending those OS messages (though I doubt this), as typically it takes ~8 seconds to initiate the hard poweroff.
Offline
You must hold the power button down for at least 5 seconds to trigger a hardware shutdown. That's not what I'm talking about. I'm talking about a much shorter keypress and it definitely does an orderly shutdown by calling the 'poweroff' command.
As the OP mentioned, just hitting the powerbutton quickly does not generate any xev events on my system (and I've seen this reported by other Thinkpad users). I'm using systemd and all the other ACPI events work perfectly. This bug report details a user that had the same issue and 'fixed' it by holding down the power button for smidge longer. Here's another user with the same issue.
Offline
Well...this can be marked as SOLVED. It appears that this works also with my problem. Pressing down the button for 1,5 second turns off the machine by the software not hardware.
It's quite stupid but it works
Thank you all for replying
Offline
That is interesting. My Thinkpad reacts instantaneously onpower button press. Although i have an Edge which some might say is not really a Thinkpad.
Offline
That is interesting. My Thinkpad reacts instantaneously onpower button press. Although i have an Edge which some might say is not really a Thinkpad.
You are right, its not
There's no such thing as a stupid question, but there sure are a lot of inquisitive idiots !
Offline
~3 seconds does the soft reboot on Thinkpad. It was the same with acpid. I assume it is as well in Windows though never had that on this Thinkpad.
Last edited by bassu (2012-11-14 23:43:10)
The greatest threat to knowledge is not ignorance - it is the illusion of knowledge!
Offline
Pages: 1