Re: Finding out if 'vacuum --analyze-in-stages' has generated enough stats - Mailing list pgsql-admin

From Bruce Momjian
Subject Re: Finding out if 'vacuum --analyze-in-stages' has generated enough stats
Date
Msg-id 20210331131609.GB11609@momjian.us
Whole thread Raw
In response to Finding out if 'vacuum --analyze-in-stages' has generated enough stats  (Vineet Naik <naikvin@gmail.com>)
Responses Re: Finding out if 'vacuum --analyze-in-stages' has generated enough stats
List pgsql-admin
On Wed, Mar 31, 2021 at 12:38:14PM +0530, Vineet Naik wrote:
> > This option will try to create some statistics as fast as possible, to make the database usable, and then produce
fullstatistics in the subsequent stages.
 
> 
> So my question is, after which stage is it ok to send traffic to the
> server without much performance impact? Also, is it possible to query
> the stats view in pg and determine if enough stats have been
> generated?

That is a very hard question to answer.  Some queries have only a few
possible plans, so few or no statistics are fine.  Other queries require
detailed statistics to generate efficient plans.  I think you need to
set up a dummy server with no stats and try your workload on that, then
run the stages manually and test after each stage to see how the
performance is.

-- 
  Bruce Momjian  <bruce@momjian.us>        https://momjian.us
  EDB                                      https://enterprisedb.com

  If only the physical world exists, free will is an illusion.




pgsql-admin by date:

Previous
From: Nikhil Shetty
Date:
Subject: Re: Recovery doesn't pause during PITR
Next
From: "Campbell, Lance"
Date:
Subject: work_mem