Re: Unkillable process

From: Vladimir Grebenschikov <vova_at_sw.ru>
Date: Wed, 27 Oct 2004 14:00:19 +0400
В ср, 27/10/2004 в 13:47 +0400, Vladimir Grebenschikov пишет:
> 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 ?)

ok, I can to stop debugging with gdb, but is it "right" way ? And if I
have no gdb ?

# gdb httpd 56647
GNU gdb 6.1.1 [FreeBSD]
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you
are
welcome to change it and/or distribute copies of it under certain
conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for
details.
This GDB was configured as "i386-marcel-freebsd"...
Attaching to program: /usr/local/sbin/httpd, process 56647
Reading symbols from /lib/libz.so.2...done.
Loaded symbols for /lib/libz.so.2
...
0x2809e7b4 in r_debug_state () from /libexec/ld-elf.so.1
(gdb) q
The program is running.  Quit anyway (and detach it)? (y or n) y
Detaching from program: /usr/local/sbin/httpd, process 56647
# ps alxx | fgrep htt
# 

-- 
Vladimir B. Grebenschikov
SWsoft Inc. vova_at_sw-soft.com
Received on Wed Oct 27 2004 - 08:00:21 UTC

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