Re: Unkillable process

From: Vladimir Grebenschikov <vova_at_sw.ru>
Date: Wed, 27 Oct 2004 16:37:27 +0400
В ср, 27/10/2004 в 16:35 +0400, Vladimir Grebenschikov пишет:
> В ср, 27/10/2004 в 20:28 +0800, David Xu пишет:
> > Can you tell me which revision of sys/kern/kern_exit.c you are using ?
> 
> % cvs status sys/kern/kern_exit.c
> ===================================================================
> File: kern_exit.c       Status: Needs Patch
> 
>    Working revision:    1.250   Thu Oct 21 09:04:25 2004
>    Repository revision: 1.251   /ext/ncvs/src/sys/kern/kern_exit.c,v
>    Sticky Tag:          (none)
>    Sticky Date:         (none)
>    Sticky Options:      (none)
> %

Looks like I should upgrade to 1.251:

diff -u -r1.251 -r1.250
--- sys/kern/kern_exit.c        23 Oct 2004 11:20:26 -0000      1.251
+++ sys/kern/kern_exit.c        5 Oct 2004 18:51:11 -0000       1.250
_at__at_ -403,7 +403,7 _at__at_
                 * since their existence means someone is screwing up.
                 */
                if (q->p_flag & P_TRACED) {
-                       q->p_flag &= ~(P_TRACED | P_STOPPED_TRACE);
+                       q->p_flag &= ~P_TRACED;
                        psignal(q, SIGKILL);
                }
                PROC_UNLOCK(q);

> 
> > Vladimir Grebenschikov wrote:
> > 
> > >Hi
> > >
> > >FreeBSD -CURRENT
> > >
> > >After gdb crash on httpd process, process still present, and listen
> > >sockets but it is in T state and can't be killed.
> > >
> > ># ps alxx | fgrep htt
> > >    0 56647     1   0  76  0  5044 2720 -      T     p9-
> > >0:00.14 /usr/local/sbin/httpd -X
> > ># kill -CONT 56647
> > ># ps alxx | fgrep htt
> > >    0 56647     1   0  76  0  5044 2720 -      T     p9-
> > >0:00.14 /usr/local/sbin/httpd -X
> > ># kill -9 56647
> > ># ps alxx | fgrep htt
> > >    0 56647     1   0  76  0  5044 2720 -      T     p9-
> > >0:00.14 /usr/local/sbin/httpd -X
> > ># procctl 56647
> > ># kill -9 56647
> > ># ps alxx | fgrep htt
> > >    0 56647     1   0  76  0  5044 2720 -      T     p9-
> > >0:00.14 /usr/local/sbin/httpd -X
> > ># mount /proc
> > ># cat /proc/56647/status 
> > >httpd 56647 1 56647 0 5,9 noflags 1098869811,34135 0,119132 0,21623
> > >nochan 0 0 0,0,0,2,3,4,5,20 -
> > ># 
> > >
> > >How to deal with such processes (except reboot ?)
> > >
> > >  
> > >
-- 
Vladimir B. Grebenschikov
SWsoft Inc. vova_at_sw-soft.com
Received on Wed Oct 27 2004 - 10:37:30 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:38:19 UTC