php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Doc Bug #47731 Misleading doc in php.ini for session.save_path and/or session.gc_maxlifetime
Submitted: 2009-03-20 13:28 UTC Modified: 2009-05-08 16:00 UTC
Votes:1
Avg. Score:2.0 ± 0.0
Reproduced:1 of 1 (100.0%)
Same Version:1 (100.0%)
Same OS:1 (100.0%)
From: chcaron at nrcan dot gc dot ca Assigned:
Status: Not a bug Package: Documentation problem
PHP Version: Irrelevant OS: Linux
Private report: No CVE-ID: None
 [2009-03-20 13:28 UTC] chcaron at nrcan dot gc dot ca
Description:
------------
In the php.ini file, here's what it says (for session.save_path):

##START##
; NOTE: If you are using the subdirectory option for storing session files
;       (see session.save_path above), then garbage collection does *not*
;       happen automatically.  You will need to do your own garbage
;       collection through a shell script, cron entry, or some other method.
;       For example, the following script would is the equivalent of
;       setting session.gc_maxlifetime to 1440 (1440 seconds = 24 minutes):
;          cd /path/to/sessions; find -cmin +24 | xargs rm 
##END##

On the website, here's what it says (http://ca3.php.net/manual/en/session.configuration.php#ini.session.save-path):

##START##
Also note that if N is used and greater than 0 then automatic garbage collection will not be performed
##END##

The documentation in php.ini is misleading as it makes you think that using the session.save_path variable will prevent the garbage collector to work. This isn't true. It would happen *only* if you are specifying "N", and it "N" would be greater than 0.

Expected result:
----------------
The documentation in the php.ini file (either for "session.save_path" or "session.gc_maxlifetime") should include the same information as found on the website.


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2009-05-08 16:00 UTC] danbrown@php.net
This is two separate sections that, while related, are still not one in 
the same.  Perhaps it could be worded better, but I would not classify 
this as a bug.
 
PHP Copyright © 2001-2026 The PHP Group
All rights reserved.
Last updated: Tue Oct 06 03:00:02 2026 UTC