Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1sy0vZ-00DlPN-QY for pgsql-general@arkaria.postgresql.org; Tue, 08 Oct 2024 03:30:25 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1sy0vY-001ye0-Di for pgsql-general@arkaria.postgresql.org; Tue, 08 Oct 2024 03:30:24 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1sy0vX-001yds-WD for pgsql-general@lists.postgresql.org; Tue, 08 Oct 2024 03:30:24 +0000 Received: from mail-oa1-x2a.google.com ([2001:4860:4864:20::2a]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.94.2) (envelope-from ) id 1sy0vR-0033Wz-LP for pgsql-general@lists.postgresql.org; Tue, 08 Oct 2024 03:30:22 +0000 Received: by mail-oa1-x2a.google.com with SMTP id 586e51a60fabf-2872134c806so1596974fac.3 for ; Mon, 07 Oct 2024 20:30:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1728358216; x=1728963016; darn=lists.postgresql.org; h=to:subject:message-id:date:from:in-reply-to:references:mime-version :from:to:cc:subject:date:message-id:reply-to; bh=FlL1n9LO6U8cYS9HzdEpi0GyHsT0aKDaGHkpsJTEfQA=; b=YuHy1QKAMD8MvV2ZIbD5tkh5s2JwxXVZnW8rfLNoVB/M5PjUQnxFiAjNhnSZPSnvFl 2V3oOUHRME7jN0HFEVNvrSmupuCsVMjTKwPx+LDO+v+45bfgr7NAb+v5tEZeiXDEzof7 yuZyOFoJqvv0Nf4uC6q4hLe7C7NK0TYw+E3rOmvfe7It980R9Ir4EqLA5kmgoN440lim 1EwKbpvauvlZOPoJzGqpvtqN2NFy2cyIo8F1xDW2JHjIU0og9quUbl5O541777itbCgl JdwlMdjeDxnlYGBad9roFG9J+Q76Wcb+siRKedTL871K+riMt6Ekc5rzugB60dSstCuM Yb6g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1728358216; x=1728963016; h=to:subject:message-id:date:from:in-reply-to:references:mime-version :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=FlL1n9LO6U8cYS9HzdEpi0GyHsT0aKDaGHkpsJTEfQA=; b=QjfMlUe9yeqqb3Lxu5WDPDPRiwyPsjaPMHOg9Cyzo1NQMeIhQizyg4x+nxfHD+AZ6T 6a4op80HNNgBfsGkjysT62S7pEHwPjoHk1PU4hae5DpmmD5TMfxdPzB1x8xfEEum/qfA fp7vLcQ8465X1HEGPtc3tWyjg9CZ7OYmc7E8/2dNNYWTK3dvmVYUcPfzTad9gMWODSsY 6WZHNMcZxkpkfaqPi4CYh48K5UzShgQOjQ4KrcsVmSqubNPMsQ+n0VItpHa0wFdp3Mkx 1Wmu4//clC5AB6k0FXcfr/ADq1x3ULZJpETdU1ZYf/jYRK81j6pCDbOmdCAGuVLkFjNX wn+w== X-Gm-Message-State: AOJu0YyjBEn0K1w0Zzf8OTGyOxWkUQxanpvRpy2pX6MiuddQZkRPTzQW 8DsQlweZxDWo1IzTK7Foy3StpgQIGEC+BApGEF6NhgKIDVow2LfLv4DvAXyecvh5FVIygymnE27 JoZxN7bHFNZKsscD+B7/+L1YdvIGx8A== X-Google-Smtp-Source: AGHT+IErtgb4A//AKkmS0LK7JkjNe1gYdKDhtkl95gV2rboKJjouFGcq/wji5Np9KPvpXh2uCT+VUcTOC2Bso4DDRxI= X-Received: by 2002:a05:6870:8a24:b0:277:e94b:779c with SMTP id 586e51a60fabf-287c1db3ca7mr8389847fac.19.1728358216546; Mon, 07 Oct 2024 20:30:16 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Ron Johnson Date: Mon, 7 Oct 2024 23:30:05 -0400 Message-ID: Subject: Re: Load balancing of write queries among health-checked nodes To: "pgsql-generallists.postgresql.org" Content-Type: multipart/alternative; boundary="0000000000008ac7130623eec19b" List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --0000000000008ac7130623eec19b Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Mon, Oct 7, 2024 at 11:04=E2=80=AFPM wr= ote: > Hello. I have a PostgreSQL high availability cluster with Pgpool-II, but = I > don't use the virtual IP feature so my clients don't know which node to > send queries to. DNS round-robin is not a solution because it can't > distinguish between healthy and dead nodes. > > I thought about having a Pgpool-II instance on each client (client > Pgpool-II -> cluster Pgpool-II -> PostgreSQL), but AFAIK it can't > distribute write queries. I also know that libpq may have multiple nodes = to > connect, but I need an advanced health check because a node may have > connectivity but be separated from the whole cluster so it must be > considered dead. > Isn't that multi-master clustering? --=20 Death to , and butter sauce. Don't boil me, I'm still alive. crustacean! --0000000000008ac7130623eec19b Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
On Mon, Oct 7, 2024 at 11:04=E2=80=AFPM &= lt;me+postgres@kotovale= xarian.com> wrote:
Hello. I have a PostgreSQL high availa= bility cluster with Pgpool-II, but I don't use the virtual IP feature s= o my clients don't know which node to send queries to. DNS round-robin = is not a solution because it can't distinguish between healthy and dead= nodes.

I thought about having a Pgpool-II instance on each client (client Pgpool-I= I -> cluster Pgpool-II -> PostgreSQL), but AFAIK it can't distrib= ute write queries. I also know that libpq may have multiple nodes to connec= t, but I need an advanced health check because a node may have connectivity= but be separated from the whole cluster so it must be considered dead.
=

Isn't that multi-master clustering?

--
Death to <= Redacted>, and butter sauce.
Don't boil me, I'm still alive.=
<Redacted> crustacean!
--0000000000008ac7130623eec19b--