Re: Send a message to a user's terminal
That worked really well:
echo "Get the hell off my server!!" > /dev/pts#/#
Thank you.
Bill Marcum wrote:
> On 21 Aug 2006 09:38:24 -0700, gineraso
> <gineraso@gmail.com> wrote:
> > I wrote a scipt to kick unauthorized user's off my Solaris 9
> > workstation. Before I kill their session, I'd like to send a message
> > to their session with something like: "You are not authorized to use
> > this workstation. Your session will be killed."
> >
> > I've tried talk but I just want to send one message from command line
> > Something like:
> >
> > echo "You are not authorized to use this workstation. Your session will
> > be killed." {Session}
> >
> > Any suggestions?
> >
> If your script runs as root, you can get the device name of the user's
> tty, and redirect the echo to that device. Or, if the user is using X,
> open an xterm displaying the message on their display (you'll have to
> use xauth).
>
>
> --
> The less time planning, the more time programming.
|