Re: pg_stats how-to?

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Y Sidhu" <ysidhu(at)gmail(dot)com>
Cc: "Bill Moran" <wmoran(at)collaborativefusion(dot)com>, pgsql-performance(at)postgresql(dot)org
Subject: Re: pg_stats how-to?
Date: 2007-05-15 00:20:49
Message-ID: 1623.1179188449@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

"Y Sidhu" <ysidhu(at)gmail(dot)com> writes:
> it may be table fragmentation. What kind of tables? We have 2 of them which
> experience lots of adds and deletes only. No updates. So a typical day
> experiences record adds a few dozen times on the order of 2.5 million. And
> deletes once daily. Each of these tables has about 3 btree indexes.

With an arrangement like that you should vacuum once daily, shortly
after the deletes --- there's really no point in doing it on any other
schedule. Note "shortly" not "immediately" --- you want to be sure that
any transactions old enough to see the deleted rows have ended.

regards, tom lane

In response to

Responses

Browse pgsql-performance by date

  From Date Subject
Next Message Greg Smith 2007-05-15 03:19:23 Re: Automatic adjustment of bgwriter_lru_maxpages
Previous Message Y Sidhu 2007-05-14 22:15:49 Re: pg_stats how-to?