[pgpool-general: 6786] Re: replication delay

Takuma Hoshiai hoshiai at sraoss.co.jp
Tue Nov 19 14:37:45 JST 2019


Hi,

On Mon, 18 Nov 2019 19:40:57 +0530
Lakshmi Raghavendra <lakshmiym108 at gmail.com> wrote:

> Hi Pgpool Team,
> 
>           Wanted to understand wat does the replication_delay column in
> output of "show pool" command mean ?
> 
> I have a 3-node postgres & pgpool cluster in production. The standby node
> has a replication delay wrt to master.
> Ran pg_basebackup to sync with the master. Still the delay pop-ups after a
> while.

The replication_delay is difference of postgres's lsn(log sequence number) between primary and standby.
If replication_delay icreased, it was not in time for sync of replication data.

> Also, do let me know how to avoid this delay, as the standy node having
> delay would not be chosen for failover.

I think that you maybe want to say 'loadbalance' not 'failover'? replication_delay and failover are unrelated.

You can't show latest data by loadbalanceing stadndby node, If this is okay with you, you can resolve by increasing delay_threshold parameter. You always would use loadbalance and show latest data, you should use sync streaming replication on PostgreSQL.

> 
> Please let me know at the earliest.
> 
> Thanks in advance !
> 
> Lakshmi Y M


Best Regards,

-- 
Takuma Hoshiai <hoshiai at sraoss.co.jp>



More information about the pgpool-general mailing list