Re: The way to know whether the standby has caught up with the master

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Heikki Linnakangas <heikki(dot)linnakangas(at)enterprisedb(dot)com>
Cc: Fujii Masao <masao(dot)fujii(at)gmail(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: The way to know whether the standby has caught up with the master
Date: 2011-05-25 14:07:21
Message-ID: 4780.1306332441@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Heikki Linnakangas <heikki(dot)linnakangas(at)enterprisedb(dot)com> writes:
> On 25.05.2011 07:42, Fujii Masao wrote:
>> To achieve that, I'm thinking to change walsender so that, when the standby
>> has caught up with the master, it sends back the message indicating that to
>> the standby. And I'm thinking to add new function (or view like
>> pg_stat_replication)
>> available on the standby, which shows that info.

> By the time the standby has received that message, it might not be
> caught-up anymore because new WAL might've been generated in the master
> already.

Even assuming that you believe this is a useful capability, there is no
need to change walsender. It *already* sends the current-end-of-WAL in
every message, which indicates precisely whether the message contains
all of available WAL data.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Pavan Deolasee 2011-05-25 14:07:35 Re: Proposal: Another attempt at vacuum improvements
Previous Message Leonardo Francalanci 2011-05-25 14:04:06 Re: use less space in xl_xact_commit patch