Re: Multiple postgresql clusters with same version and separate binaries

From: Erika Knihti-Van Driessche <erika(dot)knihti(at)gmail(dot)com>
To: Stéphane KANSCHINE <stephane(at)hexack(dot)fr>
Cc: pgsql-admin(at)lists(dot)postgresql(dot)org
Subject: Re: Multiple postgresql clusters with same version and separate binaries
Date: 2019-01-08 07:13:09
Message-ID: CALgXhV-Hi0rL8cakzBp3cL33EobCwuCyC9UWY2MY2m8BGFbOnA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin pgsql-general

Hi,

I'm sure I'd regret creationg all the extra work for myself, but.. the
customer insists that not all (at least production) applications may go
down at the same time.
I have streaming replication in place also, and I think for minor upgrade
it won't be a problem to first upgrade standby, resync replication, then
failover primary to newer minor version standby (altho I did read that this
is not supported but will likely work..). For major upgrade this isn't an
option though, or I would have to implement Slony (I think)..

In any case, currently I have 17 very small clusters running on an acc
env, half of them are in fact for dev and other half for acc with streaming
replication. It all started with one cluster of course, but during the
years it has got a bit out of hand. Applications are all on separate
clusters, because I have to be able to stop them separately. I have always,
without thinking further, used initdb from that one set of binaries, to
create a new cluster. If I'd separate the binaries, then I'd also have to
indeed create separate profiles to make sure I use correct set of binaries
for each cluster.. which will make it all quite complicated..

So, just creating separate services isn't really an option, because it
won't help me with the upgrades.

Cheers,
Erika

On Mon, 7 Jan 2019 at 15:36, Stéphane KANSCHINE <stephane(at)hexack(dot)fr> wrote:

> Le ven. 4 janv., vers 16:30, Erika Knihti-Van Driessche exprimait :
>
> > Hi,
>
> Hey !
>
> > Thanks all for your replies and help! I already thought that it’ll
> > be possible to just install binaries in different locations.
>
> It's not necessary, you "only" have to separate services, one
> thing that manages the services files in the Debian packages. It also
> manages clusters init and stop/start/etc globally for services named :
>
> - postgresql(at)10-cluster1
> - postgresql(at)10-cluster2
> - ...
>
> > Oh, and I’m on RHEL 7. [...] Previously I did do a minor upgrade -
> > shutdown all clusters and upgrade, then startup all.. but now they
> > start doing difficult with downtime for all applications at the same
> > time, so with next upgrade, I’ll separate all binaries.
>
> Please don't, you'll regret it when you'll have to upgrade as you'll have
> to uprade all your binaries. You should create separated services
> files and a global one.
>
> Regards,
> --
> Stéphane KANSCHINE - https://www.hexack.fr./ - https://www.nuajik.io./
> @ stephane(at)hexack(dot)fr
>  +33 6 64 31 72 52
>

In response to

Responses

Browse pgsql-admin by date

  From Date Subject
Next Message Robert Simmons 2019-01-08 08:30:01 Re: Database migration across different operating systems
Previous Message selva kumaran 2019-01-08 05:22:59 Doubt On JSON in Postgresql

Browse pgsql-general by date

  From Date Subject
Next Message Stéphane KANSCHINE 2019-01-08 08:50:32 Re: Multiple postgresql clusters with same version and separate binaries
Previous Message Thomas Carroll 2019-01-07 20:54:41 Re: Memory exhaustion due to temporary tables?