Bug 143073

Summary: traced process cannot be killed
Product: Red Hat Enterprise Linux 4 Reporter: Yoav Zach <yoav.zach>
Component: kernelAssignee: Roland McGrath <roland>
Status: CLOSED ERRATA QA Contact: Brian Brock <bbrock>
Severity: medium Docs Contact:
Priority: medium    
Version: 4.0CC: davej, halligan, jbaron, jturner, nagahama, roland, tao
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2005-06-08 15:13:12 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 137160, 139815, 145334, 147461    
Attachments:
Description Flags
test case to demonstrate the problem
none
machine-independent version of the test case
none
three-thread version of the test case none

Description Yoav Zach 2004-12-16 11:46:30 UTC
Description of problem:
when a process is traced it cannot be killed by sending it a signal

Version-Release number of selected component (if applicable):
RHEL4 pre RC1

How reproducible:
consistently

Steps to Reproduce:
1.Build the attaced file by doing "gcc -o suspend suspend_thread.c -lpthread -
D_REENTRANT"

2. run ./suspend
3.
  
Actual results:
On EL4 pre-rc1:

[~/tests/64/thread_suspension]./suspend_thread 
Thread 13742720(7344) is started.
thread 7344 is stopped
(the application is hanged and cannot be killed)



Expected results:
On EL3 U3:
[~/tests/64/thread_suspension]./suspend 
Thread 13662416(4942) is started.
thread 4942 is stopped
Segmentation fault



Additional info: this is the rootcause of bugzilla #139815

Comment 1 Yoav Zach 2004-12-16 11:46:30 UTC
Created attachment 108684 [details]
test case to demonstrate the problem

Comment 3 Roland McGrath 2004-12-24 22:42:58 UTC
Created attachment 109114 [details]
machine-independent version of the test case

This is a modified version of the given test case, that can be compiled on any
architecture and demonstrates the problem on x86 using the current upstream
kernel.  This version can also take a signal number argument on its command
line.
Using this with non-coredump signals demonstrates that there is no problem
except in the coredump case.

Comment 4 Roland McGrath 2004-12-25 00:01:40 UTC
Created attachment 109116 [details]
three-thread version of the test case

This version of the test case has three threads, so that the ptracer, the
ptracee, and the thread causing the core dump and all separate.  Some
approaches to the fix work for the prior test case but not for this one.

Comment 9 Tim Powers 2005-06-08 15:13:12 UTC
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/RHSA-2005-420.html