Prune Quassel Database

Prune Quassel Database

February 3, 2011 10:07 1 comment
 
14 Kudos
Don't
move!

Sometimes it happens that I remember to cleanup my Quassel database because it is growing a lot even if there are chat logs I don’t care anymore.

Anyway, this technique is a little bit extreme because this way you will completely remove any chat-log (both private and public) that occurred before a given date.

If you are using Quassel with sqlite3 database then you can download the script here: purge_quassel_db.

Please, first double check the script and make sure it does what you expect it to do. I don’t take any liability nor provide any warranty for its usage.

If, instead, you are using Quassel with a postgres backend, then the command to issue is just this one:

The above command will remove any log in the database leaving untouched just those that are not older than 120 days. You can change the interval value by putting anything you want there. I usually feel comfortable having the last 4 months available, just in case.

However, if you are running a multi-identities quasselcore (and, of course, you have access to the database) than you really should refine that query by adding a restriction on the identity you are using or, in a more general sense, the one that you are aiming to cleanup.

  • reubot

    The link to the page for sqlite3 doesn’t work.