ID: 16263 Comment by: ddw252 at bham dot ac dot uk Reported By: kur at natur dot cuni dot cz Status: No Feedback Bug Type: Session related Operating System: ANY PHP Version: 4.3.0-dev New Comment:
Found this solution: I was running a server on my pc and session data was lost when I left the page. php_info() revealved session.save_path was C:\DOCUME~1\MyUsername\LOCALS~1\Temp\php\session but when I looked on the C drive, in the temp folder, there was no php folder. So I made a php folder, with a session folder inside it, and hey presto everything works fine :) Previous Comments: ------------------------------------------------------------------------ [2007-03-21 16:36:29] bagginsbh at hotmail dot com The only work around I have found is on the first call to start a session in your application capture that session id. Then pass it in the url or as a form parameter. After the session_start() call on your next page, reset the session id to the passed in session id. Also may consider archiving all session files such that can be parsed at a later time to extract the key-value pairs. This bug has been a major, major problem in my clients environment. This has been the first time I have run into it. It also has nothing to do with the time of the session as I have had the lost session occur in less than 2 minutes after session start. If not executing a session destroy, which will delete the session file from the temp location, then look at the old session files and recover the `lost` parameters. ------------------------------------------------------------------------ [2007-03-15 05:21:59] akk7788 at yahoo dot com Has a workaround been posted for this yet? I'm having a similar problem. THanks ------------------------------------------------------------------------ [2007-03-13 06:53:07] bagginsbh at hotmail dot com Generally occurs during peak server loads. Intermittently, a new session is created at session_start() call even though the cookie id has not changed. Old session file remains with associated data. New session wipes out all key value pairs resulting in lost data. PHP Version: 4.3.9 Server: Apache 2.0 OS: wsprolinux kernel: 2.6.9-42 ------------------------------------------------------------------------ [2007-02-20 16:03:58] george at edynamo dot com same problem here - FC4, PHP 5.0.2 - session files are empty. possible solution ( sometimes works ) - use session_register insted of $_SESSION to set a new value to the session ------------------------------------------------------------------------ [2007-02-19 15:11:11] e at sloven dot net I have same problem and I have tried all suggested solutions. Problem still remains. ------------------------------------------------------------------------ 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/16263 -- Edit this bug report at http://bugs.php.net/?id=16263&edit=1