1. Please take a little time for this simple survey! Thank you for participating!
    Dismiss Notice

Sparatic session_start() Error

Discussion in 'Plesk for Linux - 8.x and Older' started by johnson4, Sep 2, 2005.

  1. johnson4

    johnson4 Guest

    0
     
    Fatal error: session_start(): Failed to initialize storage module. in /home/httpd/vhosts/realstuf.ca/httpdocs/phpwebsite-0.9.1/core/Core.php on line 303

    at www.realstuf.ca
    and

    Warning: ini_set(): A session is active. You cannot change the session module's ini settings at this time. in /home/httpd/vhosts/sleepcomfy.ca/httpdocs/open_session.php on line 3

    at www.sleepcomfy.ca/admin.php

    I get this error for no apparent reason, ever since I switched to Plesk.

    Any insight?
     
  2. jamesyeeoc

    jamesyeeoc Guest

    0
     
    Hmm, I am wondering if this is also related to the number of recent posts regarding Horde/IMP sessions being terminated quickly.

    The only 2 references I can find to a possible solution are:

    In /etc/php.ini, set: session.auto_start = 0
    which should be the default on Plesk servers (all that I've checked anyways).

    Memory allocation problems (PHP Bugs#26005). Try setting 'memory_limit' to a higher value (32M, 64M, ?)

    Also, what version of PHP do you have installed??
     
  3. johnson4

    johnson4 Guest

    0
     
    I have PHP4

    I couldn't find /etc/php.ini, could it be under a different directory?

    We have the option to switch to C-panel quite cheaply, do you think that would help here?
     
  4. johnson4

    johnson4 Guest

    0
     
  5. jamesyeeoc

    jamesyeeoc Guest

    0
     
    Hmm, interesting. Do you actually have a directory '/home/tmp' ? The 'session.save_path' is set to that.
     
  6. johnson4

    johnson4 Guest

    0
     
    no I didn't have that directory (/home/tmp),
    so I created it and now have this error,

    Fatal error: session_start(): Failed to initialize storage module. in /home/httpd/vhosts/sleepcomfy.ca/httpdocs/open_session.php on line 4

    (only sparaticaly) and it usually disappears after refreshing the page.

    Should I redirect the session.save_path
    to somewhere specific?

    I really appriciate the help, I know very very little, and migrating to a new server system has been quite a headache.
    Thanks again.
     
  7. jamesyeeoc

    jamesyeeoc Guest

    0
     
    I believe that normally the /etc/php.ini file has the following as default for most 7.5.x installs on RH type systems:

    session.save_path = /tmp

    Then the question would be what other settings are different than 'normal' (if there is such a thing as normal).... :)

    If you can't find /etc/php.ini, you will have to do a search to find the path for your system.

    You did not give any details about your server, OS, Plesk version.... I am only intimately familiar with RedHat, so if you are using Suse, FreeBSD, or something other than RedHat type Linux, then I can give general advice, just not OS specifics....
     
  8. jamesyeeoc

    jamesyeeoc Guest

    0
     
    Interestingly enough, while investigating this post, I found that my own osTicket installation was no longer working. What I eventually found was:

    1. My /etc/php.ini file had random garbage entries

    2. In my subdomain's vhost.conf file, somehow I had managed to specify a session.save_path referring to a mambo directory... (must have been drinking too much that night!)

    Once I cleaned up the php.ini and removed the errant session.save_path, all my session problems went away... Doh!~
     
  9. johnson4

    johnson4 Guest

    0
     
    Our programmer suggested this work around, not a real cure maybe but it keeps the error from coming up in our clients faces.
    It should be ok as the sites function properly after you refresh the page that gives the error
    Added this string

    error_reporting(0);
    ini_set('session.save_handler', 'files');

    to the problem file, in this case open_session.php
     
Loading...