Re: time-delayed standbys
Robert Haas <robertmhaas@gmail.com>
From: Robert Haas <robertmhaas@gmail.com>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Greg Stark <gsstark@mit.edu>, pgsql-hackers@postgresql.org
Date: 2011-04-21T03:18:42Z
Lists: pgsql-hackers
On Wed, Apr 20, 2011 at 11:15 AM, Tom Lane <tgl@sss.pgh.pa.us> wrote: > Robert Haas <robertmhaas@gmail.com> writes: >> I am a bit concerned about the reliability of this approach. If there >> is some network lag, or some lag in processing from the master, we >> could easily get the idea that there is time skew between the machines >> when there really isn't. And our perception of the time skew could >> easily bounce around from message to message, as the lag varies. I >> think it would be tremendously ironic of the two machines were >> actually synchronized to the microsecond, but by trying to be clever >> about it we managed to make the lag-time accurate only to within >> several seconds. > > Well, if walreceiver concludes that there is no more than a few seconds' > difference between the clocks, it'd probably be OK to take the master > timestamps at face value. The problem comes when the skew gets large > (compared to the configured time delay, I guess). I suppose. Any bound on how much lag there can be before we start applying to skew correction is going to be fairly arbitrary. -- Robert Haas EnterpriseDB: http://www.enterprisedb.com The Enterprise PostgreSQL Company