On Jul 28, 2010, at 5:14 PM, Furosh One wrote:

> I just tried it but not exactly sure what I'm looking for. Under 
> 'current_query' I get <command string not enabled>.

In your postgresql.conf:

track_activities = on
track_counts = on

then reload (or restart) postgres

> However, I also did a vacuum --full on the database and OMG! everything runs 
> so much faster now!!!
> 
> I read somewhere to stay away from 'vacuum --FULL'  and other places that say 
> to run weekly. I also setup a crontab job that does:
> 
> saturday vacuumdb -av 
> sunday  vacuumdb -a --analyze 
> 
> We all saw some great improvement on using the UI and the database actually 
> reclaimed a whole bunch of space!
> 
> Would you recommend using the autovacuum feature in postgresql.conf instead 
> or with the weekly cron job?

I think both are good solutions.  I use autovacuum because I like having all 
this information in the postgresql.conf.  If you do use autovacuum you probably 
want to change a few defaults.  I use:

autovacuum = on   #this requires track_counts = on  (see above)
autovacuum_naptime = 6000    #minimum delay between autovacs (100 minutes)
autovacuum_vacuum_threshold = 400000    # min number of row updates before next 
autovac

If you do a lot of deletes (like ever delete an upload) vacuum can recover lots 
of space and improve performance because the db data tables may end up much 
smaller.  Analyze is very important for the query optimizer. 

Bob Gobeille
_______________________________________________
fossology mailing list
fossology@fossology.org
http://fossology.org/mailman/listinfo/fossology

Reply via email to