powerbtn.sh assumes acpi-support is installed.
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
acpid (Ubuntu) |
New
|
Undecided
|
Unassigned |
Bug Description
Binary package hint: acpid
As you can see from the transcript below, acpid's power button
event handler has started to assume that acpi-support is installed.
As I only need the power button to be supported, I haven't installed
acpi-support.
# sh -vx /etc/acpi/
#!/bin/sh
# /etc/acpi/
# Initiates a shutdown when the power putton has been
# pressed.
. /usr/share/
+ . /usr/share/
.: 1: Can't open /usr/share/
ProblemType: Bug
Architecture: i386
Date: Tue Mar 16 08:36:30 2010
DistroRelease: Ubuntu 10.04
Package: acpid 1.0.10-5ubuntu2
ProcEnviron:
PATH=(custom, no user)
LANG=
SHELL=/bin/bash
ProcVersionSign
SourcePackage: acpid
Uname: Linux 2.6.32-16-generic i686
I had a problem with power button on my Dell Optiplex GX270 in lucid (Server Edit.). powerbtn. sh
I just copied a old script:
# /etc/acpi/
from another machine (server too) and now it works perfect :)
$ cat /etc/acpi/ powerbtn. sh powerbtn. sh
#!/bin/sh
# /etc/acpi/
# Initiates a shutdown when the power putton has been
# pressed.
# Skip if we just in the middle of resuming.
test -f /var/lock/acpisleep && exit 0
# If gnome-power-manager or kded4 are running, let acpi-support/ policy- funcs' file.
# them handle policy This is effectively the same as 'acpi-support's
# '/usr/share/
if pidof gnome-power-manager kded4 > /dev/null; then
exit
fi
# If all else failed, just initiate a plain shutdown.
/sbin/shutdown -h now "Power button pressed"