Subject: Re: Power button shutdown
To: NetBSD Users <netbsd-users@NetBSD.org>
From: Chuck Yerkes <chuck+nbsd@2004.snew.com>
List: netbsd-users
Date: 07/28/2004 22:56:44
Quoting Brian Rose (lists@brianrose.net):
> I just upgraded my file server (NetBSD 1.6.2) from a Pentium 200 to an
> Athlon 1400.
welcome out of the 90s :)
> I am looking for a simple way to shut down the machine by pressing the
> power button on the front of the box. I have been looking around and it
You can also get something to listen to (say) a second serial port.
DTR goes high (button pressed), script kicks off (and halts).
Perl can do it, but since unix does it, a "shut me down" program
called from /etc/ttys might cover you.