[j-nsp] Zombie login session

Sonny Franslay sonnyfranslay@pacific.net.sg
Fri, 26 Jul 2002 17:31:58 +0800 (Malay Peninsula Standard Time)


Hi,

I;ve tried killing the mgd -N process. It respawned automatically but
apprently the stalled login session is still reported whenever I go into
the edit mode.

Anyway, just want to clarify that the problem actually happens when I
actually kill the mgd of the user login session and not the sshd process.

For e.g:
root@juniper1% ps awux | grep user2
root     8252  0.0  0.2  2372 1528  ??  Ss    5:15PM   0:01.30 sshd:
user2@ttyp0 (sshd)
root     8254  0.0  0.5  6052 3632  ??  Is    5:15PM   0:00.02 mgd: (mgd)
(user2)/dev/ttyp0 (mgd)

Then i do "kill 8254". The session user2 will still be perceived online
from the cli.

The only way I manage to clear the zombie session is by rebooting the box.

Sonny I. Franslay
--------------------
Pacific Internet Ltd
DID: 6771-0874
Fax: 6872-6674

On Fri, 26 Jul 2002, Josef Buchsteiner wrote:

> Date: Fri, 26 Jul 2002 11:12:51 +0200
> From: Josef Buchsteiner <josefb@juniper.net>
> To: Joe Lin <jlin@doradosoftware.com>,
>      'Sonny I Franslay' <sonnyfranslay@pacific.net.sg>
> Cc: juniper-nsp@puck.nether.net
> Subject: RE: [j-nsp] Zombie login session
>
> At 10:28 PM 7/25/2002, Joe Lin wrote:
> >You can only restart the mgd with the shell I believe.
>
> correct
>
> >I don't have a very scientific method.  It always worked for me killing
> >the mgd and cli numbers next to each other.
> >
> >If I did a
> >
> >Ps -awwux |grep admin  (admin's the user I use)
> >
> >admin 15107  0.0  0.3 19200 2124  p1  Ss+   4:35PM   0:00.37 -cli (cli)
> >root  15108  0.0  0.8  9336 6268  ??  Is    4:35PM   0:01.99 mgd: (mgd)
> >(admin)/dev/ttyp1 (mgd)
> >
> >then kill both processes, it seem to clean it up..
>
> this should do it. per definition if you have a zombie process
> then you *must* have a parent since this is the one which got
> not notified of the exit() of his child.Without seeing the complete
> process list I can't tell. A restart of the parent mgd ( the one which
> ends with -N in the process list ) doesn't restart the mgd's for each users
> as they are all forked. So try to get all cli and corresponding mgd's
> off the list and then it should work.
>
> thanks
> Josef
>
>
>
> >-----Original Message-----
> >From: Sonny I Franslay [mailto:sonnyfranslay@pacific.net.sg]
> >Sent: Thursday, July 25, 2002 9:52 AM
> >To: Josef Buchsteiner
> >Cc: juniper-nsp@puck.nether.net
> >Subject: Re: [j-nsp] Zombie login session
> >
> >Hi Josef,
> >
> >I actually tried to use the "request system logout ..." which failed
> >before
> >resorting to killing the pid via shell.
> >I could not find any mgd process associated to the zombie login session
> >from
> >the process list. Is there any way to restart the the parent mgd process
> >via
> >cli? Or do i have to use the shell again?
> >
> >thx,
> >sonny
> >----- Original Message -----
> >From: "Josef Buchsteiner" <josefb@juniper.net>
> >To: "Sonny Franslay" <sonnyfranslay@pacific.net.sg>
> >Cc: <juniper-nsp@puck.nether.net>
> >Sent: Thursday, July 25, 2002 7:56 PM
> >Subject: Re: [j-nsp] Zombie login session
> >
> >
> > > At 11:03 AM 7/25/2002, Sonny Franslay wrote:
> > > >Hi Josef,
> > > >
> > > >We are running 5.0R5.1
> > >
> > >
> > > Sonny,
> > >          You may have not killed the correct pid. If you do
> > > it in the shell you need to kill the mgd daemon related
> > > to this user. So we have a master mgd and slaves for
> > > each user and each mgd  is communicating to the cli daemon
> > > which is basically the user-interface/shell. mgd is the
> > > process which touches the configuration database.
> > >
> > > In general you should use the following command from the
> > > CLI.
> > >
> > > josefb@test> request system logout ?
> > > Possible completions:
> > >    <[Enter]>            Execute this command
> > >    pid                  Management (MGD) process id for user
> > >    terminal             Terminal user is on
> > >    user                 User to logout
> > >    |                    Pipe through a command
> > >
> > >
> > > thanks
> > > Josef
> > >
>