From: | Bruce Momjian <bruce(at)momjian(dot)us> |
---|---|
To: | Harold Giménez <harold(dot)gimenez(at)gmail(dot)com> |
Cc: | pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: pg_upgrade improvements |
Date: | 2012-04-12 00:40:18 |
Message-ID: | 20120412004018.GX3379@momjian.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Wed, Apr 04, 2012 at 07:26:58PM -0700, Harold Giménez wrote:
> Hi all,
>
> I've written a pg_upgrade wrapper for upgrading our users (heroku)
> to postgres 9.1. In the process I encountered a specific issue that
> could easily be improved. We've had this process work consistently
> for many users both internal and external, with the exception of just
> a few for whom the process fails and required manual handholding.
>
> Before it performs the upgrade, the pg_upgrade program starts the
> old cluster, does various checks, and then attempts to stop it. On
> occasion stopping the cluster fails - I've posted command output
> on a gist [1]. Manually running the pg_upgrade shortly afterwards
> succeeds. We believe stopping the cluster times out because there
> are other connections to the cluster that are established in that
> small window. There could be incoming connections for a number of
> reasons: either the user or the user's applications are reestablishing
> connections, or something like collectd on the localhost attempts to
> connect during that small window.
Well, we did address this in PG 9.2 by having pg_upgrade use a
non-default port number when starting servers, 50432. You can do that
too in PG 9.1 by just specifying non-default port numbers when you run
pg_upgrade. We do start the server with a special --binary-upgrade
mode, and we could do all sorts of connection limits in that mode, but
having the port number be different seemed the clearest solution.
--
Bruce Momjian <bruce(at)momjian(dot)us> http://momjian.us
EnterpriseDB http://enterprisedb.com
+ It's impossible for everything to be true. +
From | Date | Subject | |
---|---|---|---|
Next Message | Harold Giménez | 2012-04-12 00:47:58 | Re: pg_upgrade improvements |
Previous Message | Bruce Momjian | 2012-04-12 00:38:08 | Re: pg_upgrade improvements |