Hi.
> There are 84542 rows here. Is this a lot? Doesn't sound like much,
> but who knows :)
Wow, that's a nice amound. Is that a public site?
> Or would something like:
> DELETE FROM session where authenticated=0 and last_visit <
> (strftime('%s','now') - 24*60*60*7);
> do the job fine?
Deleting from session is only part of the job, you also want to get rid of
the corresponding session_attributes for purged sessions, for example.
> If so, is there not some built in purging that goes on?
Trac's session management does house-keeping while user requests are
served, namely cleaning outdated entries from the session and
session_attribute tables (outdated as in "older than 90 days" by default).
This works for small Trac instances, but it appears to be a bad idea for
sites like trac-hacks.org where we had ~52k rows table sessions and ~200k
rows in table session_attributes. Depending on the general server load,
the "in-request house-keeping" has led to delays of up to 3500 ms for
requests where it happened.
To avoid these delays, I've disabled the in-request house-keeping and
implemented a small (bash) script that does it once per hour. I intend to
provide a patch that makes in-request house-keeping configurable in
trac.ini and adds the functionality of my bash script to trac-admin.
Bye, Mike
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Trac
Development" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/trac-dev?hl=en
-~----------~----~----~----~------~----~------~--~---