Message from root script to users?

Ghodmode ghodmode at ghodmode.com
Fri May 18 15:46:53 UTC 2007


On 5/18/07, Dave M <DaveM at mich.com> wrote:
>
> I have a daily backup script that is by cron each night. If there is a
> failure during the backup process I would like to have the script to
> notify
> the user and, if possible, allow the user to choose to cancel or re-try.
> Is
> there a way to launch a message box or a dialog box (using zenity?) on a
> user from the script that is running as root?
>

Hi Dave,
    One way would be to change the script and add another one to be run when
the user logs in.  Change the backup script so that, upon failure, it sets a
flag or even a whole error message in a file that the user can read.  Then,
in the user's .bash_profile, run another script that checks for the presence
of the file and generates the Zenity error message.

I've never used Zenity, so I don't know about any of its specific
functionality.

-- Vince
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ubuntu.com/archives/ubuntu-users/attachments/20070519/a7c8a18a/attachment.html>


More information about the ubuntu-users mailing list