[CentOS] Display a warning message at a certain time ?

2010-02-02 Thread Niki Kovacs
Hi, I'm currently installing a CentOS 5 desktop as a public internet access point. The machine shuts down every day automatically at 22:30. Is there a way I can display a message in GNOME at 22:15 warning the user that the machine will shutdown in 15 minutes ? Any suggestions ? Niki Kovacs __

Re: [CentOS] Display a warning message at a certain time ?

2010-02-02 Thread Frank Cox
On Tue, 2010-02-02 at 21:47 +0100, Niki Kovacs wrote: > Is there > a way I can display a message in GNOME at 22:15 warning the user that > the machine will shutdown in 15 minutes ? kalarm -- MELVILLE THEATRE ~ Melville Sask ~ http://www.melvilletheatre.com ___

Re: [CentOS] Display a warning message at a certain time ?

2010-02-02 Thread m . roth
> Hi, > > I'm currently installing a CentOS 5 desktop as a public internet access > point. The machine shuts down every day automatically at 22:30. Is there > a way I can display a message in GNOME at 22:15 warning the user that > the machine will shutdown in 15 minutes ? > > Any suggestions ? > cr

Re: [CentOS] Display a warning message at a certain time ?

2010-02-02 Thread Frank Cox
On Tue, 2010-02-02 at 14:57 -0600, Frank Cox wrote: > On Tue, 2010-02-02 at 21:47 +0100, Niki Kovacs wrote: > > Is there > > a way I can display a message in GNOME at 22:15 warning the user that > > the machine will shutdown in 15 minutes ? > > kalarm On second thought, a bash file calling zen

Re: [CentOS] Display a warning message at a certain time ?

2010-02-02 Thread Per Qvindesland
Hi Not sure but I seem to remember the old write command it could to the trick. Regards Per On Tue, 2010-02-02 at 21:47 +0100, Niki Kovacs wrote: > Hi, > > I'm currently installing a CentOS 5 desktop as a public internet access > point. The machine shuts down every day automatically at 22:30. I

Re: [CentOS] Display a warning message at a certain time ?

2010-02-02 Thread Les Mikesell
On 2/2/2010 3:03 PM, Per Qvindesland wrote: > Hi > > Not sure but I seem to remember the old write command it could to the > trick. > write or wall will work with open terminal windows - but shutdown offers the option to send such a message itself with a grace period before the actual shutdown.

Re: [CentOS] Display a warning message at a certain time ?

2010-02-02 Thread Geoff Galitz
xmessage is another option. I use it from time to time. It would need minimal dependencies if that is a consideration. -geoff - Geoff Galitz Blankenheim NRW, Germany http://www.galitz.org/ http://german-way.com/blog/ > > > > I'm currently installing a CentOS 5

Re: [CentOS] Display a warning message at a certain time ?

2010-02-02 Thread Jobst Schmalenbach
cron and xmessage. Jobst On Tue, Feb 02, 2010 at 09:47:20PM +0100, Niki Kovacs (cont...@kikinovak.net) wrote: > Hi, > > I'm currently installing a CentOS 5 desktop as a public internet access > point. The machine shuts down every day automatically at 22:30. Is there > a way I can display

Re: [CentOS] Display a warning message at a certain time ?

2010-02-02 Thread Robert Heller
At Tue, 02 Feb 2010 21:47:20 +0100 CentOS mailing list wrote: > > Hi, > > I'm currently installing a CentOS 5 desktop as a public internet access > point. The machine shuts down every day automatically at 22:30. Is there > a way I can display a message in GNOME at 22:15 warning the user that

Re: [CentOS] Display a warning message at a certain time ?

2010-02-02 Thread Frank Cox
On Tue, 2010-02-02 at 18:30 -0500, Robert Heller wrote: > I believe the shutdown command automagically generates warning. I > would > *guess* that GNOME would have some applet that monitors these sorts of > warnings and creates popups. I haven't seen one, unless the user happens to have a gnome-

Re: [CentOS] Display a warning message at a certain time ?

2010-02-02 Thread Jobst Schmalenbach
That's only on terminals (tty's, xterm, console) OR if you have xconsole open. jobst On Tue, Feb 02, 2010 at 06:30:15PM -0500, Robert Heller (hel...@deepsoft.com) wrote: > At Tue, 02 Feb 2010 21:47:20 +0100 CentOS mailing list > wrote: > > > > > Hi, > > > > I'm currently installing a Cent

Re: [CentOS] Display a warning message at a certain time ?

2010-02-04 Thread Niki Kovacs
Frank Cox a écrit : > > On second thought, a bash file calling zenity in a cronjob will be > better. You can have zenity show any message you want in a window on > the desktop and the only option available in that window can be "ok". > kalarm would allow the user to change the alarm, and that's n

Re: [CentOS] Display a warning message at a certain time ?

2010-02-04 Thread Geoff Galitz
> 3) But when I add it to crontab like this : > > # crontab -e > > 15 22 * * * /usr/local/sbin/warning.sh > > ... nothing happens at the given time (10:15 PM). > > Any idea what's wrong here? Any errors from a cron run go to your root mailbox (or whatever user's crontab it is, when applicable

Re: [CentOS] Display a warning message at a certain time ?

2010-02-04 Thread Niki Kovacs
Geoff Galitz a écrit : > Any errors from a cron run go to your root mailbox (or whatever user's > crontab it is, when applicable). Check your root mailbox for an error, I'm > assuming the PATH to zenity is not set correctly. That is the usual culprit > in a case like this. > No mail for root.

Re: [CentOS] Display a warning message at a certain time ?

2010-02-04 Thread m . roth
> Geoff Galitz a écrit : > >> Any errors from a cron run go to your root mailbox (or whatever user's >> crontab it is, when applicable). Check your root mailbox for an error, >> I'm assuming the PATH to zenity is not set correctly. That is the usual >> culprit in a case like this. >> > No mail fo

Re: [CentOS] Display a warning message at a certain time ?

2010-02-04 Thread Niki Kovacs
m.r...@5-cent.us a écrit : > > I assume you've checked /var/log/cron, to make sure it ran. Yes, it looks so. > > On further thought, here's a nasty one: on that line, echo $PATH. I wonder > if you need all the X paths, and maybe LD_LIBRARY_PATH set, for zenity to > run. > I think I do grasp i

Re: [CentOS] Display a warning message at a certain time ?

2010-02-04 Thread Niki Kovacs
m.r...@5-cent.us a écrit : > > I assume you've checked /var/log/cron, to make sure it ran. > I think the problem boils down to this : "How can I run a graphical application from crontab ?" I gave it a shot with a simple one (/usr/bin/gcalctool) and didn't succeed either. Phew, how I hate

Re: [CentOS] Display a warning message at a certain time ?

2010-02-04 Thread Geoff Galitz
> I think the problem boils down to this : > > "How can I run a graphical application from crontab ?" > > I gave it a shot with a simple one (/usr/bin/gcalctool) and didn't > succeed either. > I think if you did something like this: -- #!/bin/sh # set DISPLAY export DISPLAY="local

Re: [CentOS] Display a warning message at a certain time ?

2010-02-04 Thread m . roth
You wrote: > m.r...@5-cent.us a écrit : >> >> On further thought, here's a nasty one: on that line, echo $PATH. I >> wonder if you need all the X paths, and maybe LD_LIBRARY_PATH set, for >> zenity to run. >> > I think I do grasp in theory what you suggest, but I wouldn't know how > to get it into

Re: [CentOS] Display a warning message at a certain time ?

2010-02-04 Thread Marko A. Jennings
On Thu, February 4, 2010 11:26 am, Geoff Galitz wrote: > >> I think the problem boils down to this : >> >> "How can I run a graphical application from crontab ?" >> >> I gave it a shot with a simple one (/usr/bin/gcalctool) and didn't >> succeed either. >> > > > > I think if you did something like

Re: [CentOS] Display a warning message at a certain time ?

2010-02-04 Thread Niki Kovacs
I'm really grateful for all the responses. But could someone please just simply write down a *working* crontab line for this ? Thanks, Niki ___ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos

Re: [CentOS] Display a warning message at a certain time ?

2010-02-04 Thread Marko A. Jennings
On Thu, February 4, 2010 12:07 pm, Niki Kovacs wrote: > I'm really grateful for all the responses. But could someone please just > simply write down a *working* crontab line for this ? *If* the issue has to do with one user trying to display the message on a desktop owned by another user, that mig

Re: [CentOS] Display a warning message at a certain time ?

2010-02-04 Thread Niki Kovacs
Marko A. Jennings a écrit : > > Since the crontab entry I posted earlier works for me, I would concentrate > on trying to determine why exactly yours is failing. Oooops. According to Murphy's law, your initial message is the only one I had been overlooking... and it's also a *working* example

Re: [CentOS] Display a warning message at a certain time ?

2010-02-04 Thread Frank Cox
On Thu, 2010-02-04 at 18:45 +0100, Niki Kovacs wrote: > The solution being simply to define the cronjob for the user... since > there's only one on the machine :o) You may want to beautify it a bit and have the script check to see if the user is actually logged in before trying to bring up the m