I use the attached script to send a broadcast message to my clients using zenity. Thanks to Scott Balneaves and others who helped me with it on #ltsp - If you save it to /usr/bin then the usage is:

announce  "The server is going down!"

-Michael

Tomasz Lewicki wrote:
Hello!

I'm using LTSP 4.2u4 with openSUSE 10.2 (64-bit version) and KDE as desktop environment with success - thank you LTSP guys! :) System is installed in university library. 10 terminals have very limited environment - after power in they log in users (named opac001...opac010) automatically, open Konqueror in fullscreen mode, turn off all window decorations, Kicker, applets and keyboard shortcuts. Web browser has only few buttons, no menu, no address field etc. Home page (one and only possible page) is library's search system web page. Machines turn off automatically (using ltspinfo -h=wsxxx --shutdown) 5 minutes before library closing time.

Another 4 terminals have less limited environment. People use them for web browsing in search of scientifical materials, for simple wordprocessing [Ctrl+C -> Ctrl+V ;)] and for printing some documents. These four machines are using KDE too.

It would be great to automagically send some messages to logged in clients, especially at the end of day. Let's say library closes at 7pm. I want to inform people standing before terminals' screens at 6:45pm with some dialog window that they should end their work because terminals will shut down in 10 minutes. I want do it with cron and native KDE's 'kdialog' preferably. I'm not sitting in front of terminal server, but control it with SSH session.

How can I make it? ------------------------------------------------------------------------

-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
------------------------------------------------------------------------

_____________________________________________________________________
Ltsp-discuss mailing list.   To un-subscribe, or change prefs, goto:
      https://lists.sourceforge.net/lists/listinfo/ltsp-discuss
For additional LTSP help,   try #ltsp channel on irc.freenode.net

--


CONFIDENTIALITY NOTICE:
This message, and any attachments that may accompany it, contain information that is intended for the use of the individual or entity to which it is addressed and may contain information that is privileged, confidential, or otherwise exempt from disclosure under applicable law. If the recipient of this message is not the intended recipient, any disclosure, copying, or other use of this communication or any of the information, which it contains is unauthorized and prohibited. If you have received this message in error, please notify the original sender by return mail and delete this message, along with any attachments, from your computer. Thank you.
#!/bin/bash

for PID in $(pgrep metacity); do
   DISPLAY=$(cat /proc/${PID}/environ | tr '\0' '\n' | grep DISPLAY | sed -e 
's/DISPLAY=//')
   XAUTHORITY=$(cat /proc/${PID}/environ | tr '\0' '\n' | grep XAUTH | sed -e 
's/XAUTHORITY=//')
   zenity --info --text="$1" &
done
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_____________________________________________________________________
Ltsp-discuss mailing list.   To un-subscribe, or change prefs, goto:
      https://lists.sourceforge.net/lists/listinfo/ltsp-discuss
For additional LTSP help,   try #ltsp channel on irc.freenode.net

Reply via email to