Bug 174599

Summary: ftp leaks socket fds when it fails to open a file
Product: Red Hat Enterprise Linux 3 Reporter: Bastien Nocera <bnocera>
Component: ftpAssignee: Miroslav Lichvar <mlichvar>
Status: CLOSED ERRATA QA Contact: Ben Levenson <benl>
Severity: medium Docs Contact:
Priority: medium    
Version: 3.0CC: tao
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: RHBA-2006-0409 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2006-05-10 21:36:26 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---
Bug Depends On:    
Bug Blocks: 187539    
Attachments:
Description Flags
netkit-ftp-close-files-on-no-file.patch none

Description Bastien Nocera 2005-11-30 17:00:31 UTC
ftp-0.17-22

1. Connect to an ftp site using ftp
2. Count the number of opened sockets using lsof
3. Try to "get" an inexistant file a good number of times
4. See the number of file descriptors increase compared to 2.

Patch attached.

Comment 1 Bastien Nocera 2005-11-30 17:00:32 UTC
Created attachment 121638 [details]
netkit-ftp-close-files-on-no-file.patch

Comment 3 Petr Raszyk 2005-12-02 15:54:52 UTC
Thanks for hints above.
ftp does not close socket descriptor in other cases too.
I hope to cover all.

NOTE: 'passive off' helps for issue above.

Comment 4 Petr Raszyk 2005-12-02 15:56:34 UTC
Fixed in current release
ftp-0.17 Release 31

Comment 11 Red Hat Bugzilla 2006-05-10 21:36:27 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/RHBA-2006-0409.html