pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: senor <frio_cervesa@hotmail.com>
To: pgsql-general@lists.postgresql.org <pgsql-general@lists.postgresql.org>
Subject: Re: pg_upgrade --jobs
Date: Sun, 7 Apr 2019 19:18:32 +0000
Message-ID: <BYAPR01MB370123FD07BC67330F4952EAF7530@BYAPR01MB3701.prod.exchangelabs.com> (raw)
In-Reply-To: <CAB_myF6HzMT8j9jfvFasj0G0w1PUfoV3ev5KsB1smum3faUxxg@mail.gmail.com>
References: <BYAPR01MB370142138620DE0D3DD6120BF7520@BYAPR01MB3701.prod.exchangelabs.com>
	<1c0469fb-1878-35ac-8468-78ce47299638@aklaver.com>
	<BYAPR01MB370161A441B39513EF47FE5AF7520@BYAPR01MB3701.prod.exchangelabs.com>
	<16144.1554588125@sss.pgh.pa.us>
	<BYAPR01MB3701D38CD99FE2E23A2FE17FF7520@BYAPR01MB3701.prod.exchangelabs.com>
	<20138.1554594658@sss.pgh.pa.us>
	<41c4d2a3-0a0a-bec3-7609-ec232b95f27b@gmail.com>
	<BYAPR01MB37015302FC3DE93AFADA2EB7F7530@BYAPR01MB3701.prod.exchangelabs.com>
	<CAB_myF6HzMT8j9jfvFasj0G0w1PUfoV3ev5KsB1smum3faUxxg@mail.gmail.com>

I just noticed I missed Sherrylyn's post.
I did some reading about Slony and believe it is would be useful if I had the time to dig in. As pointed out, it's not an out-of-the box solution. It is included on the TODO list though. For now I can only dream of the 86 second down time.

Thanks

________________________________________
From: Sherrylyn Branchaw <sbranchaw@gmail.com>
Sent: Sunday, April 7, 2019 6:43 AM
To: senor
Cc: pgsql-general@lists.postgresql.org
Subject: Re: pg_upgrade --jobs

are there any shortcuts to upgrading that would circumvent exporting the entire schema?

By "shortcuts," do you mean you want to minimize the time and energy you put into the upgrade, or that you want to minimize database downtime? If you mean downtime, I was able to upgrade a customer-facing database with ~350,000 tables from Postgres 9.0 to 9.6 last year with only 86 seconds of downtime, using Slony, but I had to make many custom modifications to Slony and test thoroughly beforehand, and it was not for the faint of heart, the pressed for time, or the inexperienced. There may be better ways (and if so, I would be curious to learn about them), but Slony was the tool with which I was most familiar at the time.

This method does, of course, require exporting the entire schema, but because our only constraint was to minimize customer downtime, and the database was online while the schema was being exported, we didn't care how long it took. Your constraints may be different.

For those reading: we do know that 350,000 tables is Doing It Wrong, and we're getting rid of them, but we decided being on an EOLed version of Postgres was worse and should be fixed first.

Sherrylyn





view thread (15+ messages)  latest in thread

Message-ID: <BYAPR01MB370123FD07BC67330F4952EAF7530@BYAPR01MB3701.prod.exchangelabs.com>
Permalink:  ../BYAPR01MB370123FD07BC67330F4952EAF7530@BYAPR01MB3701.prod.exchangelabs.com/
Also on:    postgresql.org/message-id/BYAPR01MB370123FD07BC67330F4952EAF7530@BYAPR01MB3701.prod.exchangelabs.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-general@postgresql.org
  Cc: frio_cervesa@hotmail.com
  Subject: Re: pg_upgrade --jobs
  In-Reply-To: <BYAPR01MB370123FD07BC67330F4952EAF7530@BYAPR01MB3701.prod.exchangelabs.com>
  References: <BYAPR01MB370142138620DE0D3DD6120BF7520@BYAPR01MB3701.prod.exchangelabs.com> <1c0469fb-1878-35ac-8468-78ce47299638@aklaver.com> <BYAPR01MB370161A441B39513EF47FE5AF7520@BYAPR01MB3701.prod.exchangelabs.com> <16144.1554588125@sss.pgh.pa.us> <BYAPR01MB3701D38CD99FE2E23A2FE17FF7520@BYAPR01MB3701.prod.exchangelabs.com> <20138.1554594658@sss.pgh.pa.us> <41c4d2a3-0a0a-bec3-7609-ec232b95f27b@gmail.com> <BYAPR01MB37015302FC3DE93AFADA2EB7F7530@BYAPR01MB3701.prod.exchangelabs.com> <CAB_myF6HzMT8j9jfvFasj0G0w1PUfoV3ev5KsB1smum3faUxxg@mail.gmail.com> <BYAPR01MB370123FD07BC67330F4952EAF7530@BYAPR01MB3701.prod.exchangelabs.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox