*Synopsis*: Subshell doesn't exit, holds pipe open preventing callers from 
exiting

CR 6881017 changed on Oct 28 2009 by <User 1-5HNZ8F>

=== Field ============ === New Value ============= === Old Value =============

Commit to Fix in Build snv_128                     snv_127                    
Fixed in Build         snv_128                                                
Status                 8-Fix Available             7-Fix in Progress          
====================== =========================== ===========================

     
*Change Request ID*: 6881017

*Synopsis*: Subshell doesn't exit, holds pipe open preventing callers from 
exiting

  Product: solaris
  Category: shell
  Subcategory: korn93
  Type: Defect
  Subtype: 
  Status: 8-Fix Available
  Substatus: 
  Priority: 2-High
  Introduced In Release: solaris_nevada
  Introduced In Build: snv_72
  Responsible Engineer: <User 1-7MTUEB>
  Keywords: oss-request, oss-sponsor

=== *Description* ============================================================
The following scenario hangs with snv_122, 100% reproducible:

Create a script hangit:
-----
#!/bin/ksh
( sleep 100000 </dev/null >/dev/null 2>&1 & )
exit 0
-----

Run the following command:
hangit | tee -a /tmp/log

The hang can be eliminated either by removing the "exit 0" line (?!?), or by
redirecting the subshell output to /dev/null.

This is pretty nasty. I've whittled it down to this simple case but am seeing
it in a much more subtle and complex environment where there are several
intermediate calling scripts which have exited and eventually the parent pipes
the output and hangs on the open pipe. It was hard to track down.

*** (#1 of 1): 2009-09-11 01:13:39 GMT+00:00 <User 1-5Q-13134>


=== *Public Comments* ========================================================
Also filed at:
http://bugs.grommit.com/show_bug.cgi?id=631

I was requested to open up this issue in bugster by Roland Mainz.

*** (#1 of 1): 2009-09-11 01:14:51 GMT+00:00 <User 1-5Q-13134>
*** Last Edit: 2009-09-11 01:16:27 GMT+00:00 <User 1-5Q-13134>


=== *Workaround* =============================================================

=== *Additional Details* =====================================================
        Targeted Release: solaris_nevada
        Commit To Fix In Build: snv_128
        Fixed In Build: snv_128
        Integrated In Build: 
        Verified In Build: 
  See Also: 6437624, 6793763
  Duplicate of: 
  Hooks:
        Hook1: 
        Hook2: 
        Hook3: 
        Hook4: 
        Hook5: <email address omitted>
        Hook6: <email address omitted>
  Program Management: 
  Root Cause: Insufficient Testing
  Fix Affects Documentation: No
  Fix Affects Localization: No

=== *History* ================================================================
        Date Submitted: 2009-09-11 01:13:38 GMT+00:00
        Submitted By: <User 1-5Q-13134>

        Status Changed    Date Updated                  Updated By
        3-Accepted        2009-09-11 07:00:53 GMT+00:00 <User 1-16P5I3>
        7-Fix in Progress 2009-10-23 18:45:03 GMT+00:00 <User 1-7MTUEB>
        8-Fix Available   2009-10-28 18:23:39 GMT+00:00 <User 1-5HNZ8F>


=== *Service Request* ========================================================
        Impact: Critical
        Functionality: Secondary
        Severity: 2
        Product Name: solaris
        Product Release: solaris_nevada
        Product Build: snv_122
        Operating System: snv_122
        Hardware: x86
        Submitted Date: 2009-09-11 01:13:39 GMT+00:00


=== *Multiple Release (MR) Cluster* - 0 ======================================

Reply via email to