<div dir="ltr"><div><div>Hi,</div><div><br></div><div>In our PostgreSQL setup, we have 2 PostgreSQL VMs(primary, standby) and 3 Pgpool VMs. During failover we check the replication lag. If the replication lag is zero</div><div>then we proceed for failover. To check the replication lag we rely on pgpool, command we use to check the lag is &quot;show pool_nodes&quot;.</div><div>We extract the last column value of standby node entry.</div><div><br></div><div>We have couple question regarding the replication lag calculation. Please help us here.</div><div>1 - Can we rely on this replication lag value incaseĀ  postgresql primary is down?</div><div>2 - How Pgpool calculate the replication lag if primary VM is down?</div></div><div><br></div><div>Regards,</div><div>Abhijit</div></div>