|
LTSP Kiosk Introduction
Basic Setup
Additional Features
Advanced Issues |
Booting Clients from ServerTheory of OperationIn some cases you want to force clients to boot. If you make changes to xinitrc this is not needed, since it will be re-read whenever the user logs out (closes the browser). However, there are occasions when more rough methods are needed, like after updating the client kernel in TFTP directory. To achieve this I wrote a small daemon called bootmed (boot-me-daemon). The rationale behind the tool is following:
When using this tool you might want to consider following:
Installation StepsNTP
Boot-Me-Daemon
Add reboot script (e.g. /etc/xinitrc.reboot)The reboot daemon can point directly to qreboot executable, but you can also write a short script in case you want to add some functionality to the reboot process. This small script casts a short notice to the screen using gtk_popup, waits for 10 seconds and then reboots the client. #!/bin/sh cat /usr/local/timeout_popup/reboot.txt | gtk_popup & sleep 10 /usr/sbin/qreboot Edit Your /etc/xinitrcThis step can not be covered in a great detail as it depends on your xinitrc. You have to run the bootmed at the stages you wish to check whether the client should be booted or not. If you want the bootmed to constantly monitor the server's key file you run it without the -s switch. In case you want to check the boot need for example before executing the browser you use the -s. Example 1: daemon # Turn bootmed on /usr/bin/bootmed -m /tmp/bootmed.me -k /etc/bootmed.key \ -e /etc/xinitrc.reboot -p $HOME/bootmed.pid # Authentication USERNAME=`/usr/bin/kiosk_login` # Turn bootmed off kill -TERM `cat $HOME/bootmed.pid` rm $HOME/bootmed.pid Example 2: single pass # Check for need to reboot /usr/bin/bootmed -s -m /tmp/bootmed.me -k /etc/bootmed.key -e /etc/xinitrc.reboot How to Force Boot on ClientsIn the examples above the key file indicating the time stamp of the boot order is located at client's /etc/bootmed.key. When you want to issue a boot request at the server you simply touch the file: touch /opt/lts/i386/etc/bootmed.key or wherever your client's /etc is located. Further IdeasThis solution can also be used to turn the power off from the clients e.g. for the night or weekend. For this you have to have separate key files (e.g. /etc/bootmed.reboot.key and /etc/bootmed.poweroff.key) and run separate bootmed processes to monitor these files and run the corresponding executable. Updated: 9-MAR-2004
|