• We value your experience with Plesk during 2024
    Plesk strives to perform even better in 2025. To help us improve further, please answer a few questions about your experience with Plesk Obsidian 2024.
    Please take this short survey:

    https://pt-research.typeform.com/to/AmZvSXkx
  • The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.
  • We’re working on enhancing the Monitoring feature in Plesk, and we could really use your expertise! If you’re open to sharing your experiences with server and website monitoring or providing feedback, we’d love to have a one-hour online meeting with you.

session.save_path problem

fabrizioi

Basic Pleskian
Hi to all,

I have activated a new linux dedicated server with centos5.4 and plesk8.6

I came from experience from plesk8.x/window2008, so this is first time on linux/plesk

I have problem with php and the session.save_path.

I have read the following kb
http://kb.odin.com/en/6781

When I set the environment like explain in the article the site became very slowly, it is possible ? Why ?

If, for example, I move the session save path to a folder inside the web directory for example:

/var/www/vhosts/<domain>/httpdocs/tmp

The site works well, but this is incorrect and insecure because the sessions cannot be stored in a web directory I believe.

So I'd like to know which is the correct way to configure the session.save_path.

After any change I reconfigure the vhost.conf with:

websrvmng --reconfigure-vhost ....

And I restart the httpd service.

For the session I use the Pear/Auth Class that works well in windows environment for my experience.

Any help are appreciate.

Bye.
 
in /etc/php.ini change the session_path to /tmp
if you use su_php and you have for each domain your own php.ini then you can do there and then can be custom path
 
Hi,

Thanks for the replay.

So if I have correct understand:

I can edit php.ini and set session.save.path = /etc/tmp/

I must also integrate the "php_admin_value openbase_dir" located in /var/www/vhosts/<domain>/conf/vhost.conf with the /etc/tmp/ ?

I don't know su-php

It is possible and/or reccomended to store session in a layout like this: /tmp/sess_domain1/ /tmp/sess_domain2 and so on ?

Php garbage collector work well also in this situation ?


Bye
 
Hi,

I have found this article very very intresting, thanks for sharing.

I have apply some fix to my server, like explain in the article.

I have a question about the session.save_path.

The session file created in ./tmp have the apache:apache user:group setting.

This is correct ? Or I must install suPhp ? (I do not use any software at the moment listed in the article)

Bye
 
Yes, apache:apache is normal for files created by a php script (via apache) in /tmp.

Indeed, any file created by php anywhere in the filesystem will likely be apache:apache.

Only if you use su-php (not recommended unless you really know what you are doing, even with lvalic's wonderful info) will the owndership be different.

Faris.
 
Back
Top