^Z, which suspends a process without so much as a by-your-leave and
without the process even being notified, is a very bad thing to do to a
GT.M process, akin to a kill -KILL (kill -9) or kill -STOP.

If you inadvertently suspend a process, send it a CONT signal kill -CONT
to resume operation, or an fg to resume it in the foreground (or at
least a bg to resume it in the background).

There are multiple ways to prevent yourself from inadvertently
suspending a process, which have been discussed on this list.  My
favorite is to simply unlink ^Z from suspend, with a stty susp \000
before executing a GT.M process.

If you inadvertently suspend a process and then reboot without resuming
it, or if you kill the process with a -9, as soon as practicable, you
should run a mupip integ on the database.

Under normal conditions, if you want to terminate a GT.M process from
the outside, use mupip stop (which is equivalent to kill -TERM).

-- Bhaskar

On Sat, 2004-12-25 at 03:12, Chris Richardson wrote:
> Kevin;
> 
>   Is the task accumulating and CPU time?
> Do a;
> >ps -ael
> 
>   at the Linux prompt to see if there is any change in the resources
> consumed.
> 
>   I suspect that the task is just a zombie which should go away if you
> reboot, or is just taking up a small bit of memory.
> 
>   See if you can do a mupip rundown.  Then try to stop the process from
> Linux.  Probably needs to have Bhaskar's
> input just to be sure.
> 
> 
> ----- Original Message -----
> From: "Kevin Toppenberg" <[EMAIL PROTECTED]>
> To: <hardhats-members@lists.sourceforge.net>
> Sent: Friday, December 24, 2004 10:29 PM
> Subject: RE: [Hardhats-members] How to abort runaway GTM programs
> 
> 
> > I hadn't had a chance to try this out again until
> > today.  I was in a loop and accidently typed CTRL-Z
> > instead of CTRL-C.  I have tried the methods described
> > to stop the process, bit it doesn't seem to work.
> > Here is a screenlog.
> >
> > [EMAIL PROTECTED] kdt0p]$ ps
> >   PID TTY          TIME CMD
> >  7448 pts/0    00:00:00 bash
> >  7489 pts/0    00:00:00 sh
> >  7490 pts/0    00:00:01 mumps
> >  7864 pts/0    00:00:00 ps
> > [EMAIL PROTECTED] kdt0p]$ /usr/local/gtm/mupip stop
> > 7490
> > STOP issued to process 7490
> > [EMAIL PROTECTED] kdt0p]$ ps
> >   PID TTY          TIME CMD
> >  7448 pts/0    00:00:00 bash
> >  7489 pts/0    00:00:00 sh
> >  7490 pts/0    00:00:01 mumps
> >  7870 pts/0    00:00:00 ps
> > [EMAIL PROTECTED] kdt0p]$ kill -9 7490
> > [EMAIL PROTECTED] kdt0p]$ ps
> >   PID TTY          TIME CMD
> >  7448 pts/0    00:00:00 bash
> >  7489 pts/0    00:00:00 sh
> >  7490 pts/0    00:00:01 mumps <defunct>
> >  7871 pts/0    00:00:00 ps
> > [EMAIL PROTECTED] kdt0p]$ exit
> > logout
> > There are stopped jobs.
> > [EMAIL PROTECTED] kdt0p]$ ps
> >   PID TTY          TIME CMD
> >  7448 pts/0    00:00:00 bash
> >  7489 pts/0    00:00:00 sh
> >  7490 pts/0    00:00:01 mumps <defunct>
> >  7873 pts/0    00:00:00 ps
> > [EMAIL PROTECTED] kdt0p]$ kill -9 7490
> > [EMAIL PROTECTED] kdt0p]$ ps
> >   PID TTY          TIME CMD
> >  7448 pts/0    00:00:00 bash
> >  7489 pts/0    00:00:00 sh
> >  7490 pts/0    00:00:01 mumps <defunct>
> >  7875 pts/0    00:00:00 ps
> > [EMAIL PROTECTED] kdt0p]$ exit
> > logout
> > There are stopped jobs.
> > [EMAIL PROTECTED] kdt0p]$ sh rundown
> > Running down database...
> > %GTM-I-MUFILRNDWNSUC, File
> > /home/kdt0p/OpenVistA_UserData/g/mumps.dat
> > successfully rundown
> > [EMAIL PROTECTED] kdt0p]$ ps
> >   PID TTY          TIME CMD
> >  7448 pts/0    00:00:00 bash
> >  7489 pts/0    00:00:00 sh
> >  7490 pts/0    00:00:01 mumps <defunct>
> >  7879 pts/0    00:00:00 ps
> > [EMAIL PROTECTED] kdt0p]$
> >
> >
> > I'm not sure what will happen if I log off (in this
> > case, I am connecting my ssh, so exit applies).  Will
> > this job keep using up space/cpu resources etc.?  Why
> > won't it stop/exit/dissapear?
> >
> > Thanks
> > Kevin
> >
> >
> >
> > --- "Bhaskar, K.S." <[EMAIL PROTECTED]> wrote:
> >
> > > As usual, David gives excellent advice!  Use kill -9
> > > (or kill -KILL) as a last resort.  SIGSUSP (^Z) is
> > > almost as bad.
> > >
> > > mupip stop PID is designed for exactly this purpose.
> > >  It is also equivalent to kill -15 (kill -TERM)
> > > which you can use.
> > >
> > > Note that with the mupip interrupt capability, you
> > > can set up a process to respond to an interrupt,
> > > and, for example, you can set up a process to break
> > > on interrupt, or to dump diagnostic information.
> > > It's very powerful.
> > >
> > > -- Bhaskar
> > >
> > > -----Original Message-----
> > > From: [EMAIL PROTECTED]
> > > on behalf of [EMAIL PROTECTED]
> > > Sent: Mon 11/29/2004 7:53 PM
> > > To: hardhats-members@lists.sourceforge.net
> > > Cc:
> > > Subject: Re: [Hardhats-members] How to abort runaway
> > > GTM programs
> > > Bhaskar will probably interject,
> > > but there is a command:
> > >  mupip stop PID
> > > which will do what you want safely.
> > > (kill -9 is considered a last resort by most Unix
> > > folks)
> > >
> > > so to kill job 9392 you would use:
> > >
> > >  mupip top 9392
> > >
> > > to find the job (pid=process id) number
> > > you would use in mumps: D ^ZSY
> > > or in Linux:  ps -C mumps
> > > or the command to find the high CPU users (in Linux)
> > > : top
> > >
> > > >
> > > > I can't run GT.M on my PowerBook, so I'm not
> > > speaking from experience
> > > > here, but the first thing I'd try is ctrl-Z (which
> > > sends SIGSTP to the
> > > > process) then type
> > > >
> > > > $ jobs
> > > >
> > > > to see if it comes up. Then, I'd try
> > > >
> > > > $ kill -9 job_number
> > > >
> > > > (The numeric value of SIGKILL, a signal that can
> > > neither be caught nor
> > > > ignored, is 9.)
> > > >
> > > > --- Kevin Toppenberg <[EMAIL PROTECTED]> wrote:
> > > >
> > > > > I have accidentally created an infinite loop
> > > program
> > > > > in GT.M.  How do I abort it?
> > > > >
> > > > > I tried CTRL-C, but no luck.  I was connecting
> > > to the
> > > > > server box via SSH, so I broke the connection,
> > > but
> > > > > when I reconnected, the program was still
> > > running.  I
> > > > > could tell because I have an output log file
> > > that
> > > > > continued to grow.
> > > > >
> > > > > I tried to rundown the mumps.dat file, but got
> > > an
> > > > > error: "File is in use by another process."
> > > > >
> > > > > I know I can reboot the server, but is there a
> > > less
> > > > > drastic way of shutting down a desired GTM job?
> > > > >
> > > > > Thanks
> > > > > Kevin
> > > > >
> > > > >
> > > > >
> > > > >
> > > > >
> > > > > __________________________________
> > > > > Do you Yahoo!?
> > > > > Yahoo! Mail - Helps protect you from nasty
> > > viruses.
> > > > > http://promotions.yahoo.com/new_mail
> > > > >
> > > > >
> > > > >
> > >
> > -------------------------------------------------------
> > > > > SF email is sponsored by - The IT Product Guide
> > > > > Read honest & candid reviews on hundreds of IT
> > > Products from real
> > > > > users.
> > > > > Discover which products truly live up to the
> > > hype. Start reading now.
> > > > >
> > > > > http://productguide.itmanagersjournal.com/
> > > > > _______________________________________________
> > > > > Hardhats-members mailing list
> > > > > Hardhats-members@lists.sourceforge.net
> > > > >
> > >
> > https://lists.sourceforge.net/lists/listinfo/hardhats-members
> > > > >
> > > >
> > > >
> > > > =====
> > > > A practical man is a man who practices the errors
> > > of his forefathers. --Benjamin Disraeli
> > > > ====
> > > > Greg Woodhouse
> > > > [EMAIL PROTECTED]
> > > > [EMAIL PROTECTED]
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > >
> > -------------------------------------------------------
> > > > SF email is sponsored by - The IT Product Guide
> > > > Read honest & candid reviews on hundreds of IT
> > > Products from real users.
> > > > Discover which products truly live up to the hype.
> > > Start reading now.
> > > > http://productguide.itmanagersjournal.com/
> > > > _______________________________________________
> > > > Hardhats-members mailing list
> > > > Hardhats-members@lists.sourceforge.net
> > > >
> > >
> > https://lists.sourceforge.net/lists/listinfo/hardhats-members
> > > >
> > >
> > >
> > >
> > >
> > -------------------------------------------------------
> > > SF email is sponsored by - The IT Product Guide
> > > Read honest & candid reviews on hundreds of IT
> > > Products from real users.
> > > Discover which products truly live up to the hype.
> > > Start reading now.
> > > http://productguide.itmanagersjournal.com/
> > > _______________________________________________
> > > Hardhats-members mailing list
> > > Hardhats-members@lists.sourceforge.net
> > >
> > https://lists.sourceforge.net/lists/listinfo/hardhats-members
> > >
> > >
> > >
> > >
> > >
> >
> ***************************************************************************
> > > This electronic mail transmission contains
> > > confidential and/or privileged information intended
> > > only for the person(s) named.
> > > Any use, distribution, copying or disclosure by
> > > another person is strictly prohibited.
> > >
> >
> ***************************************************************************
> > >
> > > NOTE: Ce courriel est destine exclusivement au(x)
> > > destinataire(s) mentionne(s) ci-dessus et peut
> > > contenir de l'information privilegiee,
> > > confidentielle et/ou dispensee de divulgation aux
> > > termes des lois applicables. Si vous avez recu ce
> > > message par erreur, ou s'il ne vous est pas destine,
> > > veuillez le mentionner immediatement a l'expediteur
> > > et effacer ce courriel.
> > >
> > >
> > >
> > >
> >
> > > ATTACHMENT part 2 application/ms-tnef
> > name=winmail.dat
> >
> >
> >
> >
> >
> > __________________________________
> > Do you Yahoo!?
> > Meet the all-new My Yahoo! - Try it today!
> > http://my.yahoo.com
> >
> >
> >
> >
> > -------------------------------------------------------
> > SF email is sponsored by - The IT Product Guide
> > Read honest & candid reviews on hundreds of IT Products from real users.
> > Discover which products truly live up to the hype. Start reading now.
> > http://productguide.itmanagersjournal.com/
> > _______________________________________________
> > Hardhats-members mailing list
> > Hardhats-members@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/hardhats-members
> >
> >
> 
> 
> 
> 
> -------------------------------------------------------
> SF email is sponsored by - The IT Product Guide
> Read honest & candid reviews on hundreds of IT Products from real users.
> Discover which products truly live up to the hype. Start reading now. 
> http://productguide.itmanagersjournal.com/
> _______________________________________________
> Hardhats-members mailing list
> Hardhats-members@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/hardhats-members


-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now. 
http://productguide.itmanagersjournal.com/
_______________________________________________
Hardhats-members mailing list
Hardhats-members@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/hardhats-members

Reply via email to