FVWM: strange shutdown behaviour

From: <f.kater_at_gmx.net>
Date: Mon, 6 Jan 2003 09:39:01 +0100

Hi,

does anybody have an idea for the following behaviour:

I shutdown the computer using /sbin/shutdown -h 0 in the same script
that was calling /usr/local/bin/fvwm2. So, when fvwm2 exits shutdown is
called (see below). This works fine when I (1) use my fvwm menu to log
off from fvwm *and* (2) if I had an xterm open on the screen. In this
case some shutdown messages even appear in the xterm (which I also find
strange since fvwm "quit" is called prior...), then xdm and X and the
computer shutdown like it was expected.

In case that there was *no* xterm in fvwm - then fvwm, xdm and X
shutdown, then I see the log in screen on console 1 but the computer is
*not* shutdown. Nothing happens since I switch to Alt-F7. Then the
"rest" of the shutdown commands appear and 3 sec. later the computer
shutsdown...

What may be the difference between having an xterm running or not before
calling /sbin/shutdown ?

Below there are the commands I use to shutdown (I posted them some days
ago).

Thanks
 Felix



DestroyFunc func_restart
AddtoFunc func_restart
+ I Exec exec echo '1' > /tmp/fvwm_exit_reboot
+ I Quit

DestroyFunc func_shutdown
AddToFunc func_shutdown
+ I Exec exec echo '1' > /tmp/fvwm_exit_shutdown
+ I Quit


Change the file which starts your window manager (in my case using
a gentoo distribution it's: /etc/X11/Session/fvwm2):

#!/bin/bash
/usr/local/bin/fvwm2
#add the following lines:

#sleep may help if this script is two quick
sleep 2

if [ -e /tmp/fvwm_exit_reboot ]
then
        rm /tmp/fvwm_exit_reboot
        /sbin/shutdown -r 0
fi

if [ -e /tmp/fvwm_exit_shutdown ]
then
        rm /tmp/fvwm_exit_shutdown
        /sbin/shutdown -h 0
fi
--
Visit the official FVWM web page at <URL: http://www.fvwm.org/>.
To unsubscribe from the list, send "unsubscribe fvwm" in the body of a
message to majordomo_at_fvwm.org.
To report problems, send mail to fvwm-owner_at_fvwm.org.
Received on Mon Jan 06 2003 - 02:31:01 GMT

This archive was generated by hypermail 2.3.0 : Mon Aug 29 2016 - 19:37:54 BST