Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jaZAd-000473-FX for pgsql-admin@arkaria.postgresql.org; Mon, 18 May 2020 06:22:39 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1jaZAb-0007GK-ON for pgsql-admin@arkaria.postgresql.org; Mon, 18 May 2020 06:22:37 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jaZAb-0007GB-G0 for pgsql-admin@lists.postgresql.org; Mon, 18 May 2020 06:22:37 +0000 Received: from mail-wm1-x341.google.com ([2a00:1450:4864:20::341]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1jaZAZ-0006yx-Cx for pgsql-admin@lists.postgresql.org; Mon, 18 May 2020 06:22:36 +0000 Received: by mail-wm1-x341.google.com with SMTP id f134so8007811wmf.1 for ; Sun, 17 May 2020 23:22:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cybertec-at.20150623.gappssmtp.com; s=20150623; h=message-id:subject:from:to:date:in-reply-to:references:user-agent :mime-version:content-transfer-encoding; bh=8bEif/BvfO3Ykznt10I/xAsU51bNQ0Pljdql2Zm5Evs=; b=KZrl9A6Z7UWiyxJdenfDobRTChPXhBtblneB77mSpmgr3WNgNb4nMxx482qP74/ej5 KhoUAv9KCLhfXZ1rGHfLPWIMvFMa9+WxEH3PAvKsL/Bg7eQa46TCOI8hA5egAdPFA6VF vV0UnbtXZFYCIl0R5d50AopvbRDMrZ12Psgn5CM0EBYlRNXkintODkIoDCgjQsegCpLa h0JMXL6fXY9RRto//hab6Zw1uWRMOTBALNeu28L9UdomyyH7pQlk4X4cFNm6rX/JS+Ja /kWJenl5PP7Jy4ndJMw9+MX4MOnx34/Q7y0WzXuM5dx+ch1Qcc6VqD6qlzkVxEyOQn85 SMWA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:message-id:subject:from:to:date:in-reply-to :references:user-agent:mime-version:content-transfer-encoding; bh=8bEif/BvfO3Ykznt10I/xAsU51bNQ0Pljdql2Zm5Evs=; b=qAv2QTtY5eNdYzVGoih70tTfRJGofvZb2pCwlfC+d2qquiZZpo0+Pa73B28PUIRkFD dMHDcsNXjfK7dIC5dja1kVMdwGHZ1r454lnVwI9jR8kkWlactz9/zTqM0XwsI2AGKLxz bL+PudztF8yDVHpjuSQ+nkvpDVXLaGeO7MMinyj7RDiOPqRT1hWP2KduPgTjOL3Vqc3+ 2sVjycoOH+ST8vcCUfXgvmjUe3XRWUfzay6wz8T439PY+IROGSbXE3tVFKbba9pzJgmy 439QMqNTgYSbRi2tGS1a4uYmY05eX0YJ3DJ4mrCq1vf8wBLt+i5oHIRcM5DY7wWX/ibG Pd5w== X-Gm-Message-State: AOAM532HsCPqX0V85rtLmy1GQpoHGcE6N/njB848eNE+NDnn9cQIkshZ iR6eitIWHAwVnKrZzVJWK1zpXw== X-Google-Smtp-Source: ABdhPJym2bJBK0VfubWow9EfHa0VvgLlxz/n8VPJsU4JXjT6QabLPQUZn2i+YyQPPVy5qPLO4ljYfw== X-Received: by 2002:a1c:9e43:: with SMTP id h64mr17373904wme.0.1589782953649; Sun, 17 May 2020 23:22:33 -0700 (PDT) Received: from localhost.localdomain (217-149-172-219.nat.highway.telekom.at. [217.149.172.219]) by smtp.gmail.com with ESMTPSA id w15sm14588807wmi.35.2020.05.17.23.22.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 17 May 2020 23:22:33 -0700 (PDT) Message-ID: <9558122d82fc8fa0215c3d8861d59774f654c0f4.camel@cybertec.at> Subject: Re: PGBOUNCER FAILOVER AND HIGH AVAILABILITY From: Laurenz Albe To: Peter Wainaina , pgsql-admin@lists.postgresql.org Date: Mon, 18 May 2020 08:22:32 +0200 In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" User-Agent: Evolution 3.32.5 (3.32.5-1.fc30) MIME-Version: 1.0 Content-Transfer-Encoding: 7bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On Fri, 2020-05-15 at 23:56 -0400, Peter Wainaina wrote: > Hello hope you well ,want to implement the below: > a) Pg-bouncer to detect a promoted standby database automatically > b) High availability by having more than pg-bouncer That is not pgBounder's job. For high availability, run a pg_bouncer on each standby. Use libpg's HA features to make the client connect to the right one: "host=host1,host2 port=port1,port2 target_session_attrs=read-write" Yours, Laurenz Albe -- Cybertec | https://www.cybertec-postgresql.com