| From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
|---|---|
| To: | Bertrand Roos <bertrand(dot)roos(at)areal(dot)fr> |
| Cc: | Bill Moran <wmoran(at)potentialtech(dot)com>, pgsql-general <pgsql-general(at)postgresql(dot)org> |
| Subject: | Re: Auto-analyse on insert operations |
| Date: | 2015-11-04 15:56:10 |
| Message-ID: | 3051.1446652570@sss.pgh.pa.us |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-general |
Bertrand Roos <bertrand(dot)roos(at)areal(dot)fr> writes:
> In fact, I was telling the question because I have read on some forums
> that the auto vacuum deamon only count dead tuple so only update and
> delete operations can cause the scheduling of auto-analyse.
That might have been true years ago, don't remember at the moment.
But in modern PG versions auto-vacuum is driven by the estimated number
of dead tuples while auto-analyze is driven by the total count of
inserts+updates+deletes. It's easy to show in a standalone experiment
that auto-analyze *will* run against a table that's only had inserts.
With the numbers you're showing, auto-analyze should trigger once the
table gets to 20% new tuples. It would be interesting to see the
pg_stat_all_tables values for one of your problematic tables.
regards, tom lane
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Adrian Klaver | 2015-11-04 15:57:04 | Re: Auto-analyse on insert operations |
| Previous Message | Rob Sargent | 2015-11-04 15:53:28 | Re: Recursive Arrays 101 |