php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #30953 "Unable to fork" warnings after long periods of uptime - file descriptors leaked
Submitted: 2004-12-01 23:43 UTC Modified: 2005-01-30 01:00 UTC
Votes:8
Avg. Score:3.5 ± 0.9
Reproduced:6 of 7 (85.7%)
Same Version:1 (16.7%)
Same OS:1 (16.7%)
From: brett_hollon at adp dot com Assigned:
Status: No Feedback Package: Program Execution
PHP Version: 4.3.8 OS: Linux 2.4.18-27.8.0-5
Private report: No CVE-ID: None
Have you experienced this issue?
Rate the importance of this bug to you:

 [2004-12-01 23:43 UTC] brett_hollon at adp dot com
Description:
------------
After several days of uptime on our apache server, PHP system() calls will begin to fail with "Unable to fork" warnings.  A stop and start of apache clears the issue.

Our apache server is configured with a large number 70-80 of listen ports.

Additional system configuration information:

Apache: 1.3.31
RAM 1.2GB
Dual XEON 2.0 GHz
/proc/sys/fs/file-max 70000

./configure' '--target='
'--enable-memory-limit' '--with-apxs=/adp/home/www_serv/bin/apxs' '--with-gd' '--with-zlib' '--with-zlib-dir=/releases/SW809/target/SW' '--with-jpeg' '--with-jpeg-dir=/releases/SW809/target/SW' '--with-png' '--with-png-dir=/releases/SW809/target/SW' '--with-freetype' '--with-freetype-dir=/releases/SW809/target/SW' '--with-pdflib=/releases/SW809/target/SW' '--with-enable-dba' '--with-cdb' '--with-curl=/releases/SW809/target/SW' '--with-pgsql' '--with-unixODBC' '--with-gdbm' '--with-xmlrpc' 


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2004-12-10 21:26 UTC] brett_hollon at adp dot com
Further information.

I have traced this to a file descriptor leak.  It appears that a PHP script that is experiencing an error writing to a file is causing descriptor to not close.

After an error occurs on the file (open for writing them the filesystem set read-only prior to the write attempt) The file seems to fail to close.  Over time hundreds of file descriptors all pointing to the same file build up in the httpd process.
 [2005-01-12 23:41 UTC] tony2001@php.net
Thank you for this bug report. To properly diagnose the problem, we
need a short but complete example script to be able to reproduce
this bug ourselves. 

A proper reproducing script starts with <?php and ends with ?>,
is max. 10-20 lines long and does not require any external 
resources such as databases, etc.

If possible, make the script source available online and provide
an URL to it here. Try avoid embedding huge scripts into the report.


 [2005-01-20 01:00 UTC] php-bugs at lists dot php dot net
No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".
 [2005-01-20 18:26 UTC] brett_hollon at adp dot com
As this is an external resource leak, caused in part by a change in external filesystem attributes, I don't see how an example can be created that "does not require any external resources".
 [2005-01-22 01:21 UTC] wez@php.net
What we're hoping for it something we can use to reproduce the problem, otherwise we're just guessing.
Since we're all volunteers, we'd much rather do something more fun than guessing and hoping.
So, either you give us more information than a vague description of the problem, or this report won't get any attention.

http://bugs.php.net/how-to-report.php
 [2005-01-30 01:00 UTC] php-bugs at lists dot php dot net
No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Apr 19 11:01:28 2024 UTC