Description of problem: If the debuggee is killed while gdb is attached a pair of zombies remain until the parent gdb process exits: # ps ax | grep sleep 16425 pts/3 T 0:00 sleep 300 16430 pts/3 R+ 0:00 grep sleep # kill -9 16425 # ps ax | grep sleep 16425 pts/3 Z 0:00 [sleep] <defunct> 16432 pts/3 R+ 0:00 grep sleep # ps ax | grep gdb 16426 pts/4 S+ 0:00 gdb -p 16425 16428 pts/4 Z+ 0:00 [gdb] <defunct> 16434 pts/3 R+ 0:00 grep gdb Version-Release number of selected component (if applicable): gdb-6.3.0.0-1.143.el4 How reproducible: 100% Steps to Reproduce: 1. In one terminal start a process running, e.g.: # sleep 300 & [1] 16425 2. In another terminal attach the debugger: # gdb -p 16425 GNU gdb Red Hat Linux (6.3.0.0-1.143.el4rh) Copyright 2004 Free Software Foundation, Inc. [...] 0x0081d7a2 in _dl_sysinfo_int80 () from /lib/ld-linux.so.2 (gdb) 3. Kill the debuggee: # kill -9 16425 Actual results: Two zombie processes now exist: # ps ax | grep sleep 16425 pts/3 Z 0:00 [sleep] <defunct> 16432 pts/3 R+ 0:00 grep sleep # ps ax | grep gdb 16426 pts/4 S+ 0:00 gdb -p 16425 16428 pts/4 Z+ 0:00 [gdb] <defunct> 16434 pts/3 R+ 0:00 grep gdb Expected results: No defunct processes remain. Additional info: The defunct processes are cleaned up when the parent GDB exits (pid 16426 in the above examples). This does not happen with the GDB in RHEL3 or FC6/F7.
This request was evaluated by Red Hat Product Management for inclusion in a Red Hat Enterprise Linux maintenance release. Product Management has requested further review of this request by Red Hat Engineering, for potential inclusion in a Red Hat Enterprise Linux Update release for currently deployed products. This request is not yet committed for inclusion in an Update release.
An advisory has been issued which should help the problem described in this bug report. This report is therefore being closed with a resolution of ERRATA. For more information on the solution and/or where to find the updated files, please follow the link below. You may reopen this bug report if the solution does not work for you. http://rhn.redhat.com/errata/RHBA-2007-0811.html