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 1pkRkf-0004dd-DL for pgsql-general@arkaria.postgresql.org; Thu, 06 Apr 2023 15:42:17 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1pkRkd-0002bK-Vi for pgsql-general@arkaria.postgresql.org; Thu, 06 Apr 2023 15:42:15 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1pkRkd-0002bB-JQ for pgsql-general@lists.postgresql.org; Thu, 06 Apr 2023 15:42:15 +0000 Received: from mail1.dalibo.net ([51.159.93.128] helo=mail.dalibo.com) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1pkRkZ-001GrC-4E for pgsql-general@lists.postgresql.org; Thu, 06 Apr 2023 15:42:15 +0000 Received: from karst (larco.ioguix.net [78.202.0.6]) by mail.dalibo.com (Postfix) with ESMTPSA id D6D9F1FB18; Thu, 6 Apr 2023 17:41:58 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=dalibo.com; s=a; t=1680795719; bh=9Jq2SqfdOP7xeYJ+zRAUbEylKJOepmZeeAv6Vvg9s60=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=M1OPGXN6mpjGW1VcBu6WbeqYhY3U64BypteT8Rly3dJKM7oepPvMZMYaTINibzYHN Si9dyShx6IQGINUa6/ljOi5q/9nLxxnKm28mcjV5L/WWohRRuKFHYv4/M2nIHUOs6I oK7KkXUgHUlBZclDAhM1ywamLBLHXI1HhalJEaWo= Date: Thu, 6 Apr 2023 17:41:58 +0200 From: Jehan-Guillaume de Rorthais To: Tatsuo Ishii Cc: inzamam.shafiq@hotmail.com, cyberdemn@gmail.com, pgsql-general@lists.postgresql.org Subject: Re: Patroni vs pgpool II Message-ID: <20230406174158.62c47a30@karst> In-Reply-To: <20230405.165015.9256683667589504.t-ishii@sranhm.sra.co.jp> References: <20230405.163826.1094418722086264919.t-ishii@sranhm.sra.co.jp> <20230405.165015.9256683667589504.t-ishii@sranhm.sra.co.jp> Organization: Dalibo MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Wed, 05 Apr 2023 16:50:15 +0900 (JST) Tatsuo Ishii wrote: > > But, I heard PgPool is still affected by Split brain syndrome. > > Can you elaborate more? If more than 3 pgpool watchdog nodes (the > number of nodes must be odd) are configured, a split brain can be > avoided. Split brain is a hard situation to avoid. I suppose OP is talking about PostgreSQL split brain situation. I'm not sure how PgPool's watchdog would avoid that. To avoid split brain, you need to implement a combinaison of quorum and (self-)fencing. Patroni quorum is in the DCS's hands. Patroni's self-fencing can be achieved with the (hardware) watchdog. You can also implement node fencing through the "pre_promote" script to fence the old primary node before promoting the new one. If you need HA with a high level of anti-split-brain security, you'll not be able to avoid some sort of fencing, no matter what. Good luck.