From: | Andres Freund <andres(at)2ndquadrant(dot)com> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | Christoph Berg <christoph(dot)berg(at)credativ(dot)de>, PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Is analyze_new_cluster.sh still useful? |
Date: | 2014-06-18 17:58:41 |
Message-ID: | 20140618175841.GU3115@awork2.anarazel.de |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On 2014-06-18 13:54:16 -0400, Tom Lane wrote:
> Andres Freund <andres(at)2ndquadrant(dot)com> writes:
> > On 2014-06-18 13:24:14 -0400, Tom Lane wrote:
> >> Andres Freund <andres(at)2ndquadrant(dot)com> writes:
> >>> On 2014-06-18 12:51:43 -0400, Tom Lane wrote:
> >>>> Another angle is that some folks might have tried to automate things
> >>>> even more, with a wrapper script that starts up the new postmaster
> >>>> and runs analyze_new_cluster.sh all by itself. I guess they could
> >>>> make the wrapper do "vacuumdb --all --analyze-in-stages" directly,
> >>>> though, so maybe that's not a fatal objection either.
>
> >>> Wouldn't that be quite counterproductive? The reason we don't normally
> >>> do that and why --analyze-in-stages exists is that the cluster should be
> >>> started up as fast as possible. Restarting it after ANALYZE went through
> >>> would be defeating that purpose, no?
>
> >> How so? Once you've started the postmaster, you're open for business,
> >> no?
>
> > Wasn't there lots of talk about making the server inaccessible while
> > pg_upgrade is doing its thing? Also, many people are desparately unhappy
> > if postgres has to be restarted (to return to be being OS managed) after
> > their application already has connected.
>
> I think we're not on the same page. My point is that someone might want
> to automate the whole sequence: stop old postmaster, run pg_upgrade, start
> the updated postmaster normally (hence it *is* open for business), kick
> off the analyze runs. If you're concerned about minimal downtime you
> would not want to be waiting around for the admin to issue a perfectly
> predictable series of commands.
Oh, yea. Definitely. I think that's what I've seen happen in pretty much
*all* usages of pg_upgrade. I somehow misread that you wanted to add
that into pg_upgrade. Not really sure how, sorry.
Greetings,
Andres Freund
--
Andres Freund http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services
From | Date | Subject | |
---|---|---|---|
Next Message | Josh Berkus | 2014-06-18 17:59:59 | Re: Set new system identifier using pg_resetxlog |
Previous Message | Tom Lane | 2014-06-18 17:54:16 | Re: Is analyze_new_cluster.sh still useful? |