From owner-freebsd-hackers Mon Nov 29 2:52: 3 1999 Delivered-To: freebsd-hackers@freebsd.org Received: from tasogare.imasy.or.jp (tasogare.imasy.or.jp [202.227.24.5]) by hub.freebsd.org (Postfix) with ESMTP id A0A2114FE4 for ; Mon, 29 Nov 1999 02:52:00 -0800 (PST) (envelope-from iwasaki@jp.FreeBSD.org) Received: from localhost (isdn53.imasy.or.jp [202.227.24.245]) by tasogare.imasy.or.jp (8.9.3+3.2W/3.7W-tasogare/smtpfeed 1.01) with ESMTP id TAA24550; Mon, 29 Nov 1999 19:51:56 +0900 (JST) (envelope-from iwasaki@jp.FreeBSD.org) Message-Id: <199911291051.TAA24550@tasogare.imasy.or.jp> To: Bryan Collins Cc: hackers@FreeBSD.ORG Subject: Re: more softpower/apm.. X-Mailer: Mew version 1.93 on Emacs 19.34 / Mule 2.3 (SUETSUMUHANA) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Date: Mon, 29 Nov 1999 19:51:49 +0900 From: Mitsuru IWASAKI X-Dispatcher: imput version 980905(IM100) Lines: 26 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Hi, Bryan. > Does anyone know if its possible for FreeBSD to execute a halt from > the powerswitch? > > >From reading the apmd doco, this is what apmd is suppose to do, handle > events from the APM bios and execute according to apmd.conf > > If an ATX powersupply/motherboard is setup to suspend on power button, > (i.e hold down for 5 seconds to turn off) > can FreeBSD pick up this button press and do clean shutdown? > I tried running apmd -dv, but I cant seem to see any events from the power > button pressing. Apmd was developed for you :-) You can reject suspend request on power button and execute shutdown -p instead. For example, My box was setup to suspend on power button and issues USERSUSPENDREQ, so my apmd.conf is like this; apm_event USERSUSPENDREQ { reject; exec "shutdown -p now"; } Have fun! To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message