ID:               47640
 Updated by:       j...@php.net
 Reported By:      manuel dot schmitt at manitu dot de
-Status:           Open
+Status:           Bogus
 Bug Type:         Session related
 Operating System: Linux
 PHP Version:      5.2.9
 New Comment:

Endless loops tend to cause such problems. One should always use
http://www.php.net/session_write_close as early as possible to prevent 
race conditions and this kind of "bugs".


Previous Comments:
------------------------------------------------------------------------

[2009-03-17 06:32:36] manuel dot schmitt at manitu dot de

ARGH!

It is so simple!

<?php

session_start();
while (true) { $i *= 2; }

?>

Execute it for the first time and ensure, that it runs into any of the
php limits, e.g. maxmimum execution time.

Call the script a second time while not running into the limit. When
tracing the PHP process you will see an unlimited flock() syscall!

------------------------------------------------------------------------

[2009-03-16 23:46:42] j...@php.net

You need to come up with a script / set of scripts which can be used 
to _reliably_ reproduce the issue.

------------------------------------------------------------------------

[2009-03-16 16:29:03] manuel dot schmitt at manitu dot de

But how should I trace this anymore?

I can strace apache/php processes seeing that there is a PHP script
doing flock() on a file, the process never returns.

What should I do?

------------------------------------------------------------------------

[2009-03-16 16:25:10] j...@php.net

I'm actually running also s9y installation in the high traffic 
server. Never had any hanging PHP processes. And many times scripts 
have run to limits due to database being too slow. Still, no hangups 
with sessions. As this is quite impossible to reproduce, please try 
and figure out what really causes it. I know it's hard but otherwise 
we can keep on guessing and that's pretty useless.

------------------------------------------------------------------------

[2009-03-16 08:07:22] manuel dot schmitt at manitu dot de

E.g. any S9Y installation does reproduce this. I cannot post this here
because it has lots of files.

BUT as I told you I said what I suppose. I suppose that scripts running
into any php limit (e.g. execution time) do not properly close the
session files. It does NOT happen when scripts are correctly finished!

------------------------------------------------------------------------

The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
    http://bugs.php.net/47640

-- 
Edit this bug report at http://bugs.php.net/?id=47640&edit=1

Reply via email to