Cleaning out Sessions table?
In reviewing the size of our Koha 3 db, I've noticed that our sessions table is huge! Is it safe to truncate this table periodically? What would I lose by doing so? Thanks for any input! Richard Pritsky, Assistant Director Carpenter-Carse Library PO BOX 127 Hinesburg, VT 05461 802-482-2878 www.carpentercarse.org
Yes it is safe to purge sessions at some regular interval. It *may* be safe to perform a total purge via TRUNCATE, but that is dicier. Obviously, any open sessions would be eliminated, and it might hurt performance. For an InnoDB table before version 5.0.3, InnoDB processes TRUNCATE TABLE<http://dev.mysql.com/doc/refman/5.0/en/truncate.html>by deleting rows one by one.
(from http://dev.mysql.com/doc/refman/5.0/en/truncate.html ) I imagine if you don't care about killing open sessions, then performance at that moment probably doesn't matter either. -- Joe Atzberger LibLime - Open Source Library Solutions On Tue, May 19, 2009 at 8:17 AM, <carpentercarselibrary@gmavt.net> wrote:
In reviewing the size of our Koha 3 db, I've noticed that our sessions table is huge! Is it safe to truncate this table periodically? What would I lose by doing so?
Thanks for any input!
Richard Pritsky, Assistant Director Carpenter-Carse Library PO BOX 127 Hinesburg, VT 05461 802-482-2878 www.carpentercarse.org
participants (2)
-
carpentercarselibrary@gmavt.net -
Joe Atzberger