0

I need to delete entries about anonymous user login from the sessions table.

I read what reported in https://techcommons.stanford.edu/topics/drupal/sessions-table-cleanup.

Which PHP setting in the page above ensures automatic removal of anonymous user login entries from the sessions table handled from Drupal? Do the suggested settings have any effect on that database table?

1

Go to your Drupal installation directory /sites/default/settings.php and add the following line

ini_set('arg_separator.output',     '&');
ini_set('magic_quotes_runtime',     0);
ini_set('magic_quotes_sybase',      0);
ini_set('session.cache_expire',     10800);
ini_set('session.cache_limiter',    'none');
ini_set('session.cookie_lifetime',  10800);
ini_set('session.gc_maxlifetime',   10800);
ini_set('session.save_handler',     'user');
ini_set('session.use_only_cookies', 1);
ini_set('session.use_trans_sid',    0);
ini_set('url_rewriter.tags',        '');
ini_set('session.gc_probability', 1);
  • Thanks but how is it different than the stanford article I posted with my question? – user3236765 Dec 25 '16 at 6:31
  • The session table is handled by Drupal. Are you sure that just those PHP settings are enough to clear the session table quicker? – kiamlaluno Dec 25 '16 at 6:59

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.