nareshrevoori Posted January 29, 2009 Share Posted January 29, 2009 Why my session data is not expiring after its default time out( 24 mins).I installed WAMP software on my windows PC. When i checked in php.ini file, it says ; After this number of seconds, stored data will be seen as 'garbage' and ; cleaned up by the garbage collection process. session.gc_maxlifetime = 24 ; 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 My session files storage path is session.save_path = "c:/wamp/tmp" I so what path i should give above so that garbage collection process happen automatically. Thanks for your help Link to comment https://forums.phpfreaks.com/topic/142916-session-expiration-problem/ Share on other sites More sharing options...
PFMaBiSmAd Posted January 29, 2009 Share Posted January 29, 2009 Session garbage collection GC runs randomly based on session.gc_probability and session.gc_divisor. If there are few or no session_start() statements being execuited, GC does not run. A sesison is just a container, don't rely on GC to make your application function. Link to comment https://forums.phpfreaks.com/topic/142916-session-expiration-problem/#findComment-749305 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.