[Systems] Pootle's stats.db

Chris Leonard cjl at sugarlabs.org
Mon Oct 8 16:42:30 EDT 2012


On Mon, Oct 8, 2012 at 3:20 PM, Bernie Innocenti <bernie at codewiz.org> wrote:
> Hello,
>
> while investigating backup space usage, I noticed that Pootle has a
> 7.3GB database called /var/lib/pootle/dbs/stats.db which keeps growing
> and growing.
>
> Do you know if there's a way to flush the old records? If not, do you
> need any of its contents or can I just delete it?

After checking around a bit, I decided the best course was to delete
and regenerate the stats.db.  That's going to take a while, but let's
see what it looks like after the refresh.


pootle:~/dbs$ ls -l
total 8066676
-rwxr-xr-x 1 pootle pootle   34149376 Feb 22  2011 pootle.db
-rwxr-xr-x 1 pootle pootle 7993879552 Oct  8 16:17 stats.db
-rwxr-xr-x 1 pootle pootle  232213606 Aug 30  2011 stats.sql.bz2

pootle:~/dbs$ rm stats.db

pootle:~/dbs$ ls
pootle.db  stats.sql.bz2

pootle:~/dbs$ PootleServer --refreshstats
/usr/lib/pymodules/python2.6/registration/models.py:4:
DeprecationWarning: the sha module is deprecated; use the hashlib
module instead
  import sha
2012-10-08 22:29:13,538 INFO Updating stats for Terminology [Templates]
2012-10-08 22:29:13,709 INFO Updating stats for Terminology [Afrikaans]
2012-10-08 22:29:15,702 INFO Updating stats for Terminology [Haitian;
Haitian Creole]


More information about the Systems mailing list