ID: 26005 Comment by: none at none dot mil Reported By: parsnip11 at hotmail dot com Status: No Feedback Bug Type: Session related Operating System: * PHP Version: 4CVS-2003-10-31 New Comment:
I experienced this same error in my code. I had remapped native sessioning to use the database. During a specific update on a page, I was seeing this error. It turned out that the reason was that the update was in a transaction block that was failing, and I was not explicitly issuing a ROLLBACK. The shared database resource will not accept further statements (like from the session handler), until the transaction has been rolled back. If you are not using transactions, you may want to check for a default setting where all queries are isolated in transactions by default (with postgresql). In the end, I have learned that when you see this error, chances are good something is hosed with the database connection thereby making it not possible for the session handler to do its job. Previous Comments: ------------------------------------------------------------------------ [2006-03-11 01:31:17] emmirk at gmail dot com Yo he resuelto el problema abriendo y cerrando las conexiones a la base de datos que controlan la session en cada funcion y con eso desaparecio el mensaje aqui pongo una de las funciones: function mysql_session_read ($ID) { global $tableName; //ABIENDO LA BASE DE DATOS mysql_connect("localhost","root","clave"); mysql_select_db("sesiones"); $ID = addslashes($ID); $datos = mysql_query("SELECT value FROM $tableName WHERE key = '$ID'") or die("ERROR"); mysql_close(); //<------ CERRANDO LA BASE DE DATOS if (mysql_numrows($session_data) == 1) { return mysql_result($session_data, 0); } else { return false; } } ------------------------------------------------------------------------ [2006-01-17 17:20:52] paresh at quasarsoftech dot com Apache/2.0.55, (Win32), PHP/5.0.5 Changing the max_execution_time in my php.ini in my distribution on XAMPP worked for me. ------------------------------------------------------------------------ [2006-01-05 21:49:41] dmitriy at forsalebyowner dot com I am experiencing the same problem. The message in the logs reads: Unknown(): A session is active. You cannot change the session module's ini settings at this time. in Unknown on line 0 OS: Linux Distribution: Debian (stable) Apache: 2.0.54 PHP: 5.0.5 ------------------------------------------------------------------------ [2005-10-15 17:53:19] geoff at fireballgroup dot com I am running Apache 1.3.31 and PHP 4.3.9. I got the same error and I was using a custom session handler to save my sessions in the database. The onlt time this error occured was when I was sending two emails that took some time to execute. My specific problem was due to insufficient amount of time for the session handler to do its work. I bumped my time from 30 to set_time_limit(60) and it works fine now. ------------------------------------------------------------------------ [2005-10-03 15:23:05] codebowl at gmail dot com I am also having this problem however i am using php 5.0.5 on windows. I am running Apache 2 and the isapi module. This seems to happen when i run a script that will do about 20 curl executions. I also have no ini_set for session stuff, however i do have ini_set('max_execution_time', 600); I am not sure why i am getting this since it was brought up in php 4 i figured it would be fixed by 5, maybe it's something new? I am also using a custom session handler, but up until now have never had a problem with it. ------------------------------------------------------------------------ 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/26005 -- Edit this bug report at http://bugs.php.net/?id=26005&edit=1