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 1v3tpR-005KiX-Fw for pgsql-admin@arkaria.postgresql.org; Wed, 01 Oct 2025 10:12:57 +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 1v3tpO-000Ju0-MR for pgsql-admin@arkaria.postgresql.org; Wed, 01 Oct 2025 10:12:55 +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 1v3tpO-000JtT-78 for pgsql-admin@lists.postgresql.org; Wed, 01 Oct 2025 10:12:55 +0000 Received: from mail-lf1-x135.google.com ([2a00:1450:4864:20::135]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.96) (envelope-from ) id 1v3tpM-000qn6-13 for pgsql-admin@postgresql.org; Wed, 01 Oct 2025 10:12:53 +0000 Received: by mail-lf1-x135.google.com with SMTP id 2adb3069b0e04-579d7104c37so9431949e87.3 for ; Wed, 01 Oct 2025 03:12:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1759313571; x=1759918371; darn=postgresql.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=1BH0aHzILCHKMEiWBVyYUzPWFLoCxo7KyY3XVzpD18E=; b=BCC2jBKSsEAErxOCPYQUoslfKhPm9O5L/Dmek0Zo5yQ/afeQ+0X1Rs0OWg7ExfbP0p lacEsE+MDo/8af8LDxywBIs+obsEv2P4S/NH7qFUeyRQ3wTuC9e5YhMxoXpAmBKUOMTf 5mDkvUikWqph0MkOzFCI68zHH4lXRWK0x8TJJbhTok3fe84iWEryAkp7JDc8ZjT0f0mq +jDlzGPbWHLFen98iRE81zIsYgN5Q0W2BKAr0XnARykUGBhKNmf6xantKuW0t6O7mdWA Q2PEPp7Ic/JxIP38unBCMwlSopwPHTkRKnfeAyX7Kd0VBEfNmpP+ZWkY6Q/Ri9Whqhim aVDQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1759313571; x=1759918371; h=cc: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=1BH0aHzILCHKMEiWBVyYUzPWFLoCxo7KyY3XVzpD18E=; b=OZdKNOunPpPCojy9QlYDefdc60d9IfupB14YPJQuVe4OQGDtOB/NRYl+cg6/TtDKiB QMsN2JwmDTJzViGtJqBKNNIwMkgdWB+39lQCyyul4f9ele0ENYk22UaMs1ZZPUqgIrQP 95T5UCxHePqtRf/YgiCMfcXU+DFcpiR0LmwVQpNWIfU6SsWiPLFJ2Ho3vNzPx0tCw1Vf f6d+rir7k2+dNnflFmHd4uj4WX3BbiV5/OC9J1nY/WiZPgMAKvCJC35EwHtBD5KpywmG Wi/HE+Wd2wwnxGDTScRGEUYcRrbCEnecShjg1oztYqV6F/coPFBSbcqhMKHi1AzPlkTY T4sQ== X-Forwarded-Encrypted: i=1; AJvYcCUuvMbGkwUiTrHWAK2+ehj84/FDEXbHYjqUl1i5r2SxVfT8BzQPnn7HaV1jU1XTqY+ztwbD4LEbNxDKPQ==@postgresql.org X-Gm-Message-State: AOJu0YwHLOmTj9tKKCxOgl4x+rpaoygp/mIXWPRkSRgoBQXVpwGo0bpc ueyoLLKmzw8MPIsEBtFQzioGsp8W5DLQvRFg0pACc513fYaz7X1OzXQTH6n1KP1U824CKasvVDu AW4v2lfOdV1YnBZuDje8jKi96HMoyeLH4VNbq X-Gm-Gg: ASbGncv+4p2L+uMYcobEqYirIeCiCuKqo4bYNeu1+iLyBK9I4Z0aOUdcVI8ITCOFZ1H BjTUEVZgpfyjzZ/wfF7LuKvoYqQByO1Itiei0mFfdCHgBlhUFgIrjte0TqfpBGi09WUGwvyVjrL VgVTFDRQzwQ7ryoPloMVyQbys+6ezbx1TMdpo2Fy7i3yBnlRuV1P21ZoNs2R4Czi3BtnVTZzl/1 5I4qKO9gmLT/6sxwYWMhnyn+4WPT4pFaF9J21C+MOEylwvrpQ8y1V+3tJmc5575Dg== X-Google-Smtp-Source: AGHT+IGYBSHKfwJzrw49D9pASDZvfW73GKDuPs0pzm2bzXK+Hu08pih13b2N4vsbTr6vP6jOvwK3gUb4Ka9JTVTRd9Y= X-Received: by 2002:a05:6512:3a8e:b0:57a:71f0:5da9 with SMTP id 2adb3069b0e04-58af9efd80dmr881935e87.3.1759313571173; Wed, 01 Oct 2025 03:12:51 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Imran Khan Date: Wed, 1 Oct 2025 13:12:40 +0300 X-Gm-Features: AS18NWApn29-HoeFl4DRJAKrUncbkpcrxIIWJqwmKkqFKonvFHUgz5dwRsqaQ4A Message-ID: Subject: Re: repmgr cannot bring up the standby database after switchover manaully To: Tayyab Fayyaz Cc: Chris Lee , pgsql-admin Content-Type: multipart/alternative; boundary="000000000000755a9f0640161c24" List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --000000000000755a9f0640161c24 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hi Tayyab, Is this a default behavior? We have 4 nodes cluster but never had issue in switchovers. Thanks, Imran On Wed, Oct 1, 2025, 1:10=E2=80=AFPM Tayyab Fayyaz wrote: > Hello Chris, > > I faced this issue it will not add automatically as standby you have to > add it manually. > > But I wrote a script which perform to add old primary as standby once it'= s > back online. > > Tayyab > > > On Wed, 1 Oct 2025, 3:02=E2=80=AFpm Chris Lee, wrote: > >> Hi all, >> >> I have 2 postgresql servers. One is the primary and another one is the >> standby. I am trying to setup repmgr to do the switchover manually. >> Passwordless ssh have been setup for postgres ID on both servers. >> >> I use this command "repmgr standby switchover --log-level=3DDEBUG >> --verbose". The standy database is able to promote to be the primary. Fo= r >> the previous primary database, it was shutdown. It was not able to bring= up >> as standby by repmgr. >> >> Does anyone encounter this issue before? Thanks a lot for any suggestion= s. >> >> Here is my OS and DB versions: >> >> OS version: CentOS Stream release 8 >> Postgres DB version: 15.12 >> rempmgr version: 5.5.0 >> >> Here is the repmgr conf files: >> >>>>> >> node_id=3D1 # Use 2 on standby >> node_name=3D'primary' >> conninfo=3D'host=3Dcentos804 user=3Drepmgr dbname=3Drepmgr password=3Dxx= x >> connect_timeout=3D15' >> use_primary_conninfo_password=3Dtrue >> data_directory=3D'/var/lib/pgsql/15/data' # Adjust for your setup >> pg_bindir=3D'/usr/pgsql-15/bin' >> service_start_command =3D 'sudo systemctl start postgresql-15' >> service_stop_command =3D 'sudo systemctl stop postgresql-15' >> <<<<< >> >> >>>>> >> node_id=3D2 # Use 2 on standby >> node_name=3D'standby' >> conninfo=3D'host=3Dcentos803 user=3Drepmgr dbname=3Drepmgr password=3Dxx= x >> connect_timeout=3D15' >> use_primary_conninfo_password=3Dtrue >> data_directory=3D'/var/lib/pgsql/15/data' # Adjust for your setup >> pg_bindir=3D'/usr/pgsql-15/bin' >> service_start_command =3D 'sudo systemctl start postgresql-15' >> service_stop_command =3D 'sudo systemctl stop postgresql-15' >> <<<<< >> >> Regards, >> Chris >> > --000000000000755a9f0640161c24 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hi Tayyab,

= =C2=A0Is this a default behavior? We have 4 nodes cluster but never had iss= ue in switchovers.=C2=A0

Thanks,=C2=A0
Imran

On W= ed, Oct 1, 2025, 1:10=E2=80=AFPM Tayyab Fayyaz <tayyab.humayl@gmail.com> wrote:
Hello Chris,

I faced this issue it will not add automatical= ly as standby you have to add it manually.

But I wrote a script which perform to add old primary as= standby once it's back online.

Tayyab


On Wed, 1 Oct 2025, 3:02=E2=80=AFpm Chris Lee, <cle= e.hk@gmail.com> wrote:
Hi all,

I have 2 postgresql servers. One is the primary = and another one is the standby. I am trying to setup repmgr to do the switc= hover manually. Passwordless ssh have been setup for postgres ID on both se= rvers.

I use this command "repmgr standby switchover --log-leve= l=3DDEBUG --verbose". The standy database is able to promote to be the= primary. For the previous primary database, it was shutdown. It was not ab= le to bring up as standby by repmgr. =C2=A0

Does anyone encounter th= is issue before? Thanks a lot for any suggestions.

Here is my OS and= DB versions:

OS version: CentOS Stream release 8
Postgres DB ver= sion: =C2=A015.12
rempmgr version: 5.5.0

Here is the repmgr conf = files:
>>>>>
node_id=3D1 =C2=A0# Use 2 on standby
n= ode_name=3D'primary'
conninfo=3D'host=3Dcentos804 user=3Drep= mgr dbname=3Drepmgr password=3Dxxx connect_timeout=3D15'
use_primary= _conninfo_password=3Dtrue
data_directory=3D'/var/lib/pgsql/15/data&#= 39; =C2=A0# Adjust for your setup
pg_bindir=3D'/usr/pgsql-15/bin'= ;
service_start_command =3D 'sudo systemctl start postgresql-15'=
service_stop_command =C2=A0=3D 'sudo systemctl stop postgresql-15&#= 39;
<<<<<

>>>>>
node_id=3D2 =C2= =A0# Use 2 on standby
node_name=3D'standby'
conninfo=3D'h= ost=3Dcentos803 user=3Drepmgr dbname=3Drepmgr password=3Dxxx connect_timeou= t=3D15'
use_primary_conninfo_password=3Dtrue
data_directory=3D= 9;/var/lib/pgsql/15/data' =C2=A0# Adjust for your setup
pg_bindir=3D= '/usr/pgsql-15/bin'
service_start_command =3D 'sudo systemct= l start postgresql-15'
service_stop_command =C2=A0=3D 'sudo syst= emctl stop postgresql-15'
<<<<<

Regards,
Ch= ris
--000000000000755a9f0640161c24--