Bug #65301 [Fbk->NoF]: Deleting sessions without taking into account the configuration
| From: | php-bugs at lists dot php dot net | Date: | Tue, 15 Oct 2013 11:54:46 +0000 |
| Subject: | Bug #65301 [Fbk->NoF]: Deleting sessions without taking into account the configuration | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-182254@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=65301&edit=1
ID: 65301
Updated by: php-bugs@lists.php.net
Reported by: developer at cartman34 dot fr
Summary: Deleting sessions without taking into account the
configuration
-Status: Feedback
+Status: No Feedback
Type: Bug
Package: Apache2 related
Operating System: Debian 7.1 (wheezy)
PHP Version: Irrelevant
Private report: N
New Comment:
No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Re-Opened". Thank you.
Previous Comments:
------------------------------------------------------------------------
[2013-07-20 18:33:50] johannes@php.net
Please try using this snapshot:
http://snaps.php.net/php5.4-latest.tar.gz
For Windows:
http://windows.php.net/snapshots/
we can neither support debian builds nor old versions.
------------------------------------------------------------------------
[2013-07-20 08:13:08] developer at cartman34 dot fr
Description:
------------
I'am running a PHP5 5.4.4-14+deb7u3 with an apache2 2.2.22-13 and it suffered of an issue with
sessions, these ones are quickly deleted without taking into account the php.ini configuration.
I recently updated my server from Squeeze to Wheezy and i come with a new version of PHP, the
version 5.4 and these bugs.
I got the new php.ini configuration that i updated for my own preferences.
Here is my php.ini session related configuration:
[Session]
session.save_handler = files
;session.save_path = "/var/lib/php5"
session.use_cookies = 1
;session.cookie_secure =
session.use_only_cookies = 1
session.name = PHPSESSID
session.auto_start = 0
session.cookie_lifetime = 604800
session.cookie_path = /
session.cookie_domain =
session.cookie_httponly =
session.serialize_handler = php
session.gc_probability = 0
session.gc_divisor = 1000
session.gc_maxlifetime = 604800
session.bug_compat_42 = Off
session.bug_compat_warn = Off
session.referer_check =
;session.entropy_length = 32
;session.entropy_file = /dev/urandom
session.cache_limiter = nocache
session.cache_expire = 180
You see that PHP should not delete sessions due to the session.gc_probability=0 and even if it does,
the session.gc_maxlifetime is for one week.
I checked the cookie, it is always right but the session file seems to disappear after the default
session.cookie_lifetime delay.
It is a debian stable server, so I can't upgrade PHP more than the current stable release for
debian. :-D
For my own usage, I will try to use a custom Session Handler.
Test script:
---------------
<?php
session_start();
if( !isset($_SESSION['last_time']) ) {
echo 'Creating session.';
} else {
echo 'Delay since last update: '.($_SESSION['last_time']-time()).'
seconds.';
}
$_SESSION['last_time'] = time();
// This is just a test script for bugs.php.net
Expected result:
----------------
Under one week reload, I expect displaying 'Delay since last update', not 'Creating
session.'.
Actual result:
--------------
Displaying 'Creating session.' after less than 30 minutes.
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=65301&edit=1