本人一台 Headless CentOS 5.3机器。 平时都是远程.ssh去shutdow.n关机。 [成人用品]
如果笔记本.没开,想直接按电源键触.发Linux关机指令 (和按住电源键5,6秒关电源不同)。我应该做些什么操作呢?虚拟主机
稍微查了些资料,和A.CPI有关,看了比较.早的帖子说要内核支持,还有开系统服务。 来龙去脉有点迷糊。 美容
下面是看到的一文
for s.hort, here is how i added shutting d.own via power button (o.n redhat 9):域名
1. comp.ile the kernel with acpi support .(be sure to include as built in 电子
or module :.. ospm_busmgr, ospm_button,ospm_system) 美容
2. either disable apm in kernel or add 'apm=off' t..o grub/lilo学习
3. get acpmd and install i.t (.got rpms from sourceforge:服务器
http://acpid.sourceforge.net/ ) 乙肝
4. if you have compiled the a.cpi modules as modules, be sure to insm.od学习
them before /etc/inid.d./acpi.d runs.
( what i did is .add .a 'modprobe' for them at the 'start()' in.
/etc/init.d./acpid ) 外汇
5.create a file : /etc/acpi./events/powerbtn with. the following lines:--------------彩票
event=.button[ /]power.
action.=/sbin/poweroff电影
6. reboot
硬件不太懂, 还没试验,有经验的人可.否说下要注意的地方.?谢先。.