Bug 454315

Summary: nss_ldap EPIPE when forking process
Product: Red Hat Enterprise Linux 5 Reporter: Brian Buesker <bbuesker>
Component: nss_ldapAssignee: Nalin Dahyabhai <nalin>
Status: CLOSED ERRATA QA Contact: Ondrej Moriš <omoris>
Severity: high Docs Contact:
Priority: high    
Version: 5.2CC: dpal, jon, jplans, moshiro, ofourdan, omoris, syeghiay
Target Milestone: rc   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: nss_ldap-253-23.el5 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
: 621586 (view as bug list) Environment:
Last Closed: 2010-03-30 08:34:25 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: 621586    
Attachments:
Description Flags
strace of shell that is exhibiting this problem
none
unblock sigpipe while closing the connection in the child none

Description Brian Buesker 2008-07-07 16:59:03 UTC
Description of problem:
With nss_ldap-253-12, after a few commands in a shell, the shell stops working
(ie. any command executed returns immediately without performing any work).
Attaching to the shell process via strace shows that after the fork, there is a
write to a socket that should be connected to the LDAP server, but that is not
connected and thus results in EPIPE being returned. Falling back to version
253-5 eliminates this issue. 

Version-Release number of selected component (if applicable):
253-12


How reproducible:
Typically after executing a few commands in a shell of an LDAP user, the problem
starts occurring. Once it starts occurring, there is no way to recover other
than to exit the shell and start a new one.


Steps to Reproduce:
1. Login as an LDAP user
2. Execute some commands until the shell stops working
3. Attach to the shell process via strace to verify that it is indeed due to
SIGPIPE that the child process exits abnormally
  
Actual results:
Simple commands, such as ls, do nothing.


Expected results:
Commands should continue to work properly.


Additional info:

Comment 1 Brian Buesker 2008-07-07 16:59:03 UTC
Created attachment 311193 [details]
strace of shell that is exhibiting this problem

Comment 2 Brian Buesker 2008-07-31 15:07:21 UTC
This appears to be fixed with nss_ldap-253-13.el5_2.1. See bug #448014 and bug
#455271 for more details. I think this report can be closed.

Comment 3 Jonathan Barber 2008-10-03 09:59:36 UTC
I'm running centos 5.2 with nss_ldap-253-13.el5_2.1 and see the same problem, but it only affects systems intermittently.

Comment 4 Nalin Dahyabhai 2009-12-08 17:41:37 UTC
Created attachment 376957 [details]
unblock sigpipe while closing the connection in the child

Jonathan, is there any chance that when you're seeing this, there's signal blocking involved?  I'm attaching a patch to try to work around that.

Comment 14 Jonathan Barber 2009-12-30 16:22:58 UTC
(In reply to comment #4)
> Created an attachment (id=376957) [details]
> unblock sigpipe while closing the connection in the child
> 
> Jonathan, is there any chance that when you're seeing this, there's signal
> blocking involved?  I'm attaching a patch to try to work around that.  

I can't as I don't work at the place anymore - but I've forwarded a note of this ticket to my old employees to let them know that there's a patch available.

Comment 15 Ondrej Moriš 2010-01-17 22:30:59 UTC
Successfully verified.

RHEL5.5-Client-20100112.nightly (i386, x86_64)
RHEL5.5-Server-20100112.nightly (all archs)

RHTS test created, see QA whiteboard.

Comment 17 errata-xmlrpc 2010-03-30 08:34:25 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 therefore 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-2010-0260.html