Kill 'Old' User Process on Login of Same User

Kill 'Old' User Process on Login of Same User

Post by A Tech » Wed, 18 Dec 2002 22:43:05



ALL --

We have a SCO server with a windows based terminal emulation program
for telnet sessions to the server application.

I'd like to find a script which, ideally, upon login of the user,
quickly checks who is on the sco box (who | grep -u), and, if that
user exists already, blows the old user process away or (perhaps more
kinder, gentler) prompts the new user if they want to kill the old
session prior to logging-in.  The prompt would then ensure users
don't automatically kill something they shouldn't be.

I've been searching the sco and unix newsgroups with bits here and
there but nothing that seems like a complete solution.

If my explanation is incomplete in any way as to functionality of
said script, please email me direct as well as post to this group.

Emailing me direct is preferable anyway.

Thanks for any insight you can provide !

-- Boston IT Guy

 
 
 

Kill 'Old' User Process on Login of Same User

Post by John DuBo » Sun, 22 Dec 2002 20:46:55




>ALL --

>We have a SCO server with a windows based terminal emulation program
>for telnet sessions to the server application.

>I'd like to find a script which, ideally, upon login of the user,
>quickly checks who is on the sco box (who | grep -u), and, if that
>user exists already, blows the old user process away or (perhaps more
>kinder, gentler) prompts the new user if they want to kill the old
>session prior to logging-in.  The prompt would then ensure users
>don't automatically kill something they shouldn't be.

You could start with something like

    maim -l!`tty`

which will kill all of the user's processes that are not associated with the
tty that maim is run from.  It has interactive & menu oriented modes, though
they may not ask exactly what you want.

maim is available at: ftp://ftp.armory.com/pub/scripts/maim

        John
--


 
 
 

Kill 'Old' User Process on Login of Same User

Post by Ron! » Sun, 29 Dec 2002 00:46:06





> >ALL --
> >I'd like to find a script which, ideally, upon login of the user,
> >quickly checks who is on the sco box (who | grep -u), and, if that
> >user exists already, blows the old user process away or (perhaps more
> >kinder, gentler) prompts the new user if they want to kill the old
> >session prior to logging-in.  The prompt would then ensure users
> >don't automatically kill something they shouldn't be.
> You could start with something like
>     maim -l!`tty`

    there's another program out there called 'doublekill.' it works
    just like maim but no menus... very simple and effective...

Ron!