> > Just a few quick questions before we start testing.
> > 
> > Is this necessary to keep the DB size at a norm?
> 
> I found it very necessary when using Postgres 7.3.4.  It 
> needs a full vacuum every week for me.

Vacuum is necessary in all PostgreSQL versions, if you ever do UPDATEs
or DELETEs. So as long as you never prune anything, you don't really
need it - you *do* need ANALYZE though. But in a real deployment, you
will have deletes, so you should definitly run vacuum analyze.

Only in ancient versions like <= 7.3 do you need vacuum full. In modern
versions, a plain vacuum is enough. I'd recommend you run it once/day if
you can, or at least once/week.


> > Time - If anyone is currently doing this whats the average time it 
> > takes for you database? And how large is your database?
> 
> The problem is likely to be the File table and its indexes.  
> On a 2.8HGz P4 with ~ 7 million rows in the File table, 
> vacuum takes 30 mins and vacuum full takes 90 mins for me.  
> I've not attempted to optimize this.

Wow, that's bad :-) I have a similar machine, with 14 million rows in
the File table, and a vacuum takes only 9 minutes (that's for the whole
database and not just file, but I assume you have the same - it's by far
the one that takes most time).
Also,that's vacuum analyze, but I don't think the analyze makes much
difference.

The things you want to do: increase maintenance_work_mem, and upgrade to
a current postgresql version (there has been plenty of work wrt vacuum
speed at least up to 8.0).

//Magnus


-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid0944&bid$1720&dat1642
_______________________________________________
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users

Reply via email to