On 07/06/2012 11:15 PM, Sylvain CAILLET
wrote:
If you create and drop a lot of tables, you need to make sure you're vacuuming the pg_catalog tables frequently. Newer versions mostly take care of this for you, but on 8.3 you'll at minimum have to turn autovaccum right up. See what happens if you run in psql, as a Pg superuser (usually the "postgres" account): CLUSTER pg_class_oid_index ON pg_catalog.pg_class; CLUSTER pg_type_oid_index ON pg_catalog.pg_type; CLUSTER pg_attribute_relid_attnam_index ON pg_catalog.pg_attribute; CLUSTER pg_index_indexrelid_index ON pg_catalog.pg_index; I'm guessing you have severe table bloat in your catalogs, in which case this may help. I use CLUSTER instead of VACCUUM FULL because on old versions like 8.3 it'll run faster and sort the indexes for you too.
That won't be a problem unless your OS and file system are truly crap. -- Craig Ringer |