Bug #14798 Updated: session.gc_maxlifetime does not work (Reopen Bug ID #3793)

From: Date: Wed, 23 Jan 2002 10:35:59 +0000
Subject: Bug #14798 Updated: session.gc_maxlifetime does not work (Reopen Bug ID #3793)
References: 1  Groups: php.dev 
Request: Send a blank email to php-dev+get-77880@lists.php.net to get a copy of this message
ID: 14798
Updated by: yohgaki
Reported By: bs_php@infeer.com
Old Status: Analyzed
Status: Critical
Bug Type: Session related
Operating System: Win 2k
PHP Version: 4.1.1
New Comment:

This is data loss issue. Mark it as Critical.


Previous Comments:
------------------------------------------------------------------------

[2002-01-22 03:44:15] kori@volny.cz

OS: W2K Professional (SP2)
WWW: Apache, IIS 5.0
Filesystem: FAT32

1) ISAPI module works fine with IIS 5.0. Is some bug in IIS 5.1?

2) There are same problems as I reported before with
"session.gc_maxlifetime".
     
3) "session.gc_probability  = 100" on FAT32 deletes other session files
except last accessed/created session file as before.  

-- Kori

------------------------------------------------------------------------

[2002-01-21 17:34:10] kori@volny.cz

Hi, I tested PHP 4.1.0 (release) on Windows XP Professional and there
is my report:

WWW server: IIS 5.1
Filesystem: NTSF (Compressed)

PHP.INI:

[Session]
session.save_handler      = files   ; handler used to store/retrieve
data
session.save_path         = C:/Windows/Temp    ; argument passed to
save_handler
                                    ; in the case of files, this is
the
                                    ; path where data files are stored
session.use_cookies       = 0       ; whether to use cookies
session.name              = PHPSESSID  
                                    ; name of the session
                                    ; is used as cookie name
session.auto_start        = 0       ; initialize session on request
startup
session.cookie_lifetime   = 0       ; lifetime in seconds of cookie
                                    ; or if 0, until browser is
restarted
session.cookie_path       = /       ; the path the cookie is valid for
session.cookie_domain     =         ; the domain the cookie is valid
for
session.serialize_handler = php     ; handler used to serialize data
                                    ; php is the standard serializer of
PHP
session.gc_probability    = 100       ; percentual probability that the

                                    ; 'garbage collection' process is
started
                                    ; on every session initialization
session.gc_maxlifetime    = 600    ; after this number of seconds,
stored
                                    ; data will be seen as 'garbage'
and
                                    ; cleaned up by the gc process
session.referer_check     =         ; check HTTP Referer to invalidate

                                    ; externally stored URLs containing
ids
session.entropy_length    = 0       ; how many bytes to read from the
file
session.entropy_file      =         ; specified here to create the
session id
; session.entropy_length    = 16
; session.entropy_file      = /dev/urandom
session.cache_limiter     = nocache ; set to {nocache,private,public}
to
                                    ; determine HTTP caching aspects
session.cache_expire      = 180     ; document expires after n minutes
session.use_trans_sid     = 0       ; use transient sid support if
enabled
                                    ; by compiling with
--enable-trans-sid
url_rewriter.tags         =
"a=href,area=href,frame=src,input=src,form=fakeentry"

------------------------------------

1) The ISAPI module doesn't work right (there is some data output
error) with ISS 5.1.
   CGI version works fine.
   
2) There is still the same problem with "session.gc_maxlifetime".

3) "session.gc_probability = 100" - there is one change. It deleted all
files except last accessed session file in previous versions of PHP,
now It do nothing (NO files, including expired files are deleted).
   
4) Session_destroy() function works fine.


I will test CGI & ISAPI modules with W2K professional (Apache, IIS 5.0)
on FAT32 filesystem tomorrow.

-- Kori

------------------------------------------------------------------------

[2002-01-13 20:30:28] yohgaki@php.net

Under Windows, session save path's directory is FAT FS and save handler
is files, gc call is deleting all session files. 

Status = Analyzed.

(I cannot fix this one, since it's windows specific :)

------------------------------------------------------------------------

[2002-01-13 17:03:06] bs_php@infeer.com

OK, as I thought: The test (see top entry) works on Win with NTFS.
What I did:
 a) I set session.gc_probability = 100
 b) I mad a little FAT32 partition on F: and a NTFS partition G:

The bug *only appears* when using FAT32: 
   session.save_path = F:\tmp

Session works fine when using NTFS:
   session.save_path = G:\tmp

So it MUST be a *atime* related problem. 

------------------------------------------------------------------------

[2002-01-13 16:22:13] yohgaki@php.net

Ok, I'll assume your FAT FS supports mtime.
However, I still have to ask you if it work with NTFS. I don't use
Windows now .

If there is a problem, I think problem is in TSRM code ;)

------------------------------------------------------------------------

The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
    http://bugs.php.net/?id=14798


Edit this bug report at http://bugs.php.net/?id=14798&edit=1



Thread (15 messages)

« previous php.dev (#77880) next »