• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion
  • Please beaware of a breaking change in the REST API on the next Plesk release (18.0.62).
    Starting from Plesk Obsidian 18.0.62, requests to REST API containing the Content-Type header with a media-type directive other than “application/json” will result in the HTTP “415 Unsupported Media Type” client error response code. Read more here

Issue Session Timeout

Meczup zade

Basic Pleskian
Hello,
I've been using Plesk for at least 3-4 years. But still haven't understood anything about the mechanism behind sessions.
I've edit php.ini as following
Code:
session.cookie_lifetime = 28800
session.gc_maxlifetime = 28800
session.gc_probability = 0
session.gc_divisor = 1000

But users log out in 1 hour without a predictable timeout.
Could anyone help me about it.

Thanks
 
Users get logged out from where, the Plesk interface? Which php.ini did you edit?
 
There are at least two different php.ini on every Plesk server, one belonging to the operating system's PHP and the other belonging to Plesk's PHP. If you've installed alternative PHP versions that come with Plesk, there is one more for each PHP version installed.

In any case, I suggest starting the research with your site's code in order to see how the session is used, what is written to it, what is read from it. There should be no need to adjust php.ini in order to prolong such settings as a log out timeout.
 
There are at least two different php.ini on every Plesk server, one belonging to the operating system's PHP and the other belonging to Plesk's PHP. If you've installed alternative PHP versions that come with Plesk, there is one more for each PHP version installed.

In any case, I suggest starting the research with your site's code in order to see how the session is used, what is written to it, what is read from it. There should be no need to adjust php.ini in order to prolong such settings as a log out timeout.

I'm editing this PHP.ini and every change effects my website but session timeout. (There's only 1 available, that's why I'm saying one PHP.ini file)
Also, I use sessions as following
PHP:
@session_start();
Means, every request creates a session, if they don't have one.
 

Attachments

  • Screenshot_1.png
    Screenshot_1.png
    21.6 KB · Views: 14
Back
Top