Hi All,

In my server ther are so many session files are under /tmp files. I want to delete all the session files which is no more active in automated way.

I came to know that i need to change some garbage collection configuraions in php.ini file . These are the values in my php.ini

session.gc_probability  "1"           
session.gc_divisor     "100"    
session.gc_maxlifetime  "1440"

What values do i need to change here?

Recommended Answers

All 2 Replies

You can set the probability to 100 so the garbage collector runs with every script (a lot of overhead).

Thanks for your solution

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, learning, and sharing knowledge.