php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #46625 Php Open Wrong Socket problem
Submitted: 2008-11-19 21:05 UTC Modified: 2008-11-19 23:09 UTC
From: jenek at walla dot co dot il Assigned:
Status: Not a bug Package: Session related
PHP Version: 5.2.6 OS: Linux
Private report: No CVE-ID: None
 [2008-11-19 21:05 UTC] jenek at walla dot co dot il
Description:
------------
Hello,
I want to try and explain better the problem we have to see if you can help us in understanding the root cause, and later on solve it.

The situation is that the PHP and HTTP processes are running on a Linux machine in parallel to the main application process.

The application is opening a listen socket of address IN_ADDR_ANY (0.0.0.0), port 5010. After a while due to the needs of the application, it closes this listening socket.
At this point we can see that somehow, the PHP process is opening a listen socket on the same IP and port (0.0.0.0:5010).

Few minutes later the application tries to open again the socket and fails since the PHP has it open.

I don't understand this behavior and can think of no good reason for the PHP to open this listen socket. Is there a good reason for that? If so, can it be avoided? I cannot let the PHP use this socket since the application needs it.

Moreover, I tried to change the port number we are using to 6010. This time after application closed the socket the PHP opened a listen socket on 0.0.0.0:6010.
So it seems that somehow the PHP is getting some kind of event that the socket is being closed and immediately re-open it, but without checking if this socket is really needed by the process.

I hope I described the problem clear enough so you can find the root cause and help me overcome it.

Thanks alot,

Evgeny.



Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2008-11-19 23:09 UTC] jani@php.net
Sorry, but your problem does not imply a bug in PHP itself.  For a
list of more appropriate places to ask for help using PHP, please
visit http://www.php.net/support.php as this bug system is not the
appropriate forum for asking support questions.  Due to the volume
of reports we can not explain in detail here why your report is not
a bug.  The support channels will be able to provide an explanation
for you.

Thank you for your interest in PHP.


 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Fri Aug 29 04:00:02 2025 UTC