On 25/07/2021 22:47, neilpgadmin12 wrote:
>> On Sunday, July 25, 2021 at 9:20:59 AM UTC-4 neilpgadmin12 wrote:
>> the replication shows as working on the standby but the postgresql service is not running. Is that correct?.
>> systemctl status postgresql
>> ● postgresql.service - PostgreSQL RDBMS
>> Loaded: loaded (/lib/systemd/system/postgresql.service; enabled; vendor preset: enabled)
>> Active: inactive (dead) since Sat 2021-07-24 15:45:17 EDT; 17h ago
>> Process: 1485589 ExecStart=/bin/true (code=exited, status=0/SUCCESS)
>> Main PID: 1485589 (code=exited, status=0/SUCCESS)
> but there is a process running
> postgres 1528223 1 0 Jul24 ? 00:00:00 /usr/lib/postgresql/12/bin/postgres -D /var/lib/postgresql/12/main -c config_file=/etc/postgresql/12/main/postgresql.conf
This is usually a sign that PostgreSQL was started directly, usually via
pg_ctl, which causes systemd to lose track of the PostgreSQL service status.
If this is the case, AFAIK the only way to "resync" systemd is to stop PostgreSQL
using pg_ctl, then issue "systemctl stop postgresql" and "systemctl start postgresql".
If not already done, you may want to configure repmgr to use the appropriate
service commands; see:
Ian Barwick https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services