Meir Kriheli <[EMAIL PROTECTED]> writes: > Is there a way to log in and start a X session (I prefer not to use > KDM/GDM etc. I know I can use them-at least KDM), and when exiting > the session shutdown the machine ?
Maybe you want a system that logs you on when switched on and powers down on logout? You may be able to build it like this (untested, check man pages): Install rungetty and configure it to start an X session for your user instead of running login. Then configure your X session to run "sudo shutdown -h now" after the window manager. You could do this in /etc/X11/Xsession but there should be a better place for it. If you want to have the ability to switch the system off by pressing a button on the case you have to work on the hardware. One solution for those having a game port but no use for it is to stick the wires of the reset switch into button1 of the game port, install jslaunch and configure "shutdown -h now" as an action for a single press of button1. There should be equivalent solutions for other ports like the serial port - as I think about it, it could be possible to configure a UPS monitor program like upsd to recognize the button press as a signal to shut down the machine since many UPS devices signal a power lossage via a status line of a serial port. So this should be nearly plug&play. :-) [x] ulf -- Artificial Intelligence is no match for Natural Stupidity.