Jewelu wrote:I have the same problem since 3.8.4 and 3.8.5 does not fix it for me. When I kill all sessions so that the number of users online restarts at zero, it is growing again from day to day, endlessly. It seems hat Joomla is not ending sessions after the session lifetime defined in the settings.
Killing the sessions will not have an effect! The way how the sessions are destroyed changed starting from version 3.8.4.
If you are using the "Database" handler, then it depends on your server configuration whether the session will be destroyed at all. This has been changed because performance reasons (in earlier versions the sessions were removed using SQL statements, now the PHP garbage collector is used).
Check the "session.gc_probability" value (System - System Information - PHP Information
). If set to 0, then you should either increase the value or add a cronjob to clean the sessions.
What is session.gc_probability?
session.gc_probability in conjunction with session.gc_divisor is used to manage probability that the gc (garbage collection) routine is started. Defaults to 1. See session.gc_divisor for details.
So, if your session.gc_probability is set to 0 (check your PHP Information!), then the probability that sessions will be destroyed is exactly 0%. This means that the sessions will stay in the sessions table "forever", this explains the ever-increasing values in modules like "Who is online".
You can easily change this by setting the value to a higher integer value. If session.gc_divisor is 100 and you set session.gc_probability to 10, then the probability that the gc routine will be started is 10%.
In this configuration the probability is 1%:
If you cannot modify this value, then you could activate a cronjob that will execute the gc routine with the help of a small PHP script at certain time stamps (hourly, daily etc... as you define it in your cronjob). More information about session_gc can be obtained here: http://php.net/manual/en/function.session-gc.php
If you don't fully understand what you have to do to fix it, then you can simply switch to the "PHP" session handler in the Global Configuration.
Hope this helps! :-)
You do not have the required permissions to view the files attached to this post.