I have created a table where I store serialized Java objects. They are frequently accessed and costly to create, so that is the reason. Solution works fine to me, however table size grows to 25GB inside few days! The objects are removed after few mins, so it's not case the case of amount of data really held, but simply vacuum does not do its job. After full vacuum table size drops to approx. 150 MB. In the logs I see that vacuuming process is running, but as table grows in size, it takes over 5 mins and does not help a lot.
I wonder how can I tune the vacuum to make its job better for this table?
SHOW max_prepared_transactions;andSELECT count(*) FROM pg_prepared_xacts;? Also, is there any chance table-specific autovacuum settings were ever applied? – Craig Ringer Nov 8 '12 at 8:06max_fsm_pagesand are you getting any warnings about it in the logs? – Craig Ringer Nov 8 '12 at 8:28