php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #26038 session_start(): Failed to initialize storage module
Submitted: 2003-10-30 07:30 UTC Modified: 2003-11-17 18:08 UTC
Votes:2
Avg. Score:4.0 ± 0.0
Reproduced:2 of 2 (100.0%)
Same Version:1 (50.0%)
Same OS:1 (50.0%)
From: pedro at dehumanizer dot com Assigned:
Status: Not a bug Package: Session related
PHP Version: 4CVS-2003-10-30 (stable) OS: FreeBSD 4.9
Private report: No CVE-ID: None
 [2003-10-30 07:30 UTC] pedro at dehumanizer dot com
Description:
------------
I believe this bug had already been reported by someone else (#25876), but it was marked as "bogus".

I'm using FreeBSD 4.9 (and 4.8-STABLE before), Apache 2.0.48 from ports (and 2.0.47 before), and tried several PHP versions from 4.3.2 to 4CVS-20031030 (today's). All of them exhibit this problem, with SquirrelMail 1.4.2. 

I don't think it's a SquirrelMail problem, however, as the line in question is a simple

        session_start();

The problem is intermitent - when navigating through the webmail, from time to time, when I click on a link, a blank page appears *very quickly*, just in the frame which was supposed to be changed. In the logs, I get this error:

[client 62.169.69.5] PHP Fatal error:  session_start(): Failed to initialize storage module. in /var/www/htdocs/mail/functions/global.php on line 295, referer: https://www.dehumanizer.com/mail/src/webmail.php

If I reload the page, or go back from the blank page and click on the same link again, it usually works then. The error rate is hard to calculate, but it should be less than 1 in 10 times.

I've tried changing the sessions handler between files and mm, but it doesn't solve the problem. Neither does activating register_globals, which SquirrelMail doesn't need, anyway.

PHP configure options:

./configure  --disable-cgi --with-apxs2=/usr/local/sbin/apxs --with-openssl --with-zlib --with-gdbm --with-imap --with-iconv --enable-ftp --with-mysql=/usr/local/mysql --with-curl --disable-debug --enable-exif --enable-sockets --disable-ipv6 --with-gd --with-jpeg-dir --with-png-dir --enable-dio --with-gettext=/usr/local --with-bz2 --enable-mbstring --enable-mbregex --enable-zend-multibyte --with-mysql-sock=/tmp/mysql.sock --with-mm=/usr/local



Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2003-10-30 07:34 UTC] pedro at dehumanizer dot com
By the way, if I use Apache 1.3.28 instead, configuring the same version of PHP with exactly the same options (except replacing --with-apxs2 with --with-apxs), the problem disappears.
 [2003-11-17 18:08 UTC] sniper@php.net
It's not PHP bug. (Apache2 is really not ready for production)

 [2003-12-16 17:05 UTC] darren at cpanel dot net
Just FYI, this also happens with apache 1.3.29 and php 4.3.3 and 4.3.4 on RedHat Linux.
 [2004-01-05 03:28 UTC] dewaard at netcollective dot nl
I encountered this problem while working on a custom 
session handler with session_set_save_handler(). All the 
virtual hosts on that particular server that contain 
session_start() where having this issue, except from the 
virtual host on which I was developing the custom 
session handler. The only way to solve it was an Apache 
restart.

After a while the problem occured again and an Apache 
restart fixed this occurence to. I don't know what 
caused the problem, but i'm quite sure it happened 
because of my experiments with 
session_set_save_handler(). I didn't do anything else 
that relates to sessions and didn't mess with the ini 
settings.

The error occured on PHP 4.3.3 (Apache 1.3.29, Red Hat 
8). I've just updated to PHP 4.3.4, but I'm afraid that 
won't solve this issue. I will true to find out more 
about this problem and will share all the clues that i 
can find.
 [2004-02-05 06:42 UTC] bugs dot php dot net at mkaart dot net
Hi,

I had similar problems on my Gentoo Linux box running Apache 2.0.48 and php4. The problem was solved when I changed the following setting from "user" to "files" in the php.ini:

session.save_handler = files

Note: This broke drupal (a CMS i have running), but enabling .htaccess for drupal, which sets session.save_handler to user, fixed that as well.

Hope this helps...

Regards,

Marnix Kaart
 [2004-02-12 16:52 UTC] mivox at mivox dot com
Happens frequently on my osCommerce site, hosted at Pair, running Apache 1.3.29 and PHP 4.3.4. The problems started in November 2003, and they began upgrading to FreeBSD 4.6-STABLE (incl. the Apache and PHP versions noted above) in November.

I have just tried implementing the suggestion given above about the session.save_handler = files php setting, by adding the following to my .htaccess file (as per Pair's suggestion):

php_value session.save_handler files
php_value magic_quotes_gpc 1

If the problem reappears after altering the .htaccess, I will report back. It seems to be running fine right now, but it is a maddeningly intermittent problem.
 [2004-08-12 00:34 UTC] ron at dse dot nl
It's probably a combination of issues related to Apache XBit-hack. I found a workaround for my case. See my comments on http://bugs.php.net/bug.php?id=25876 and http://bugs.php.net/bug.php?id=25753
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Apr 25 08:01:28 2024 UTC