Skip site navigation (1) Skip section navigation (2)

Re: pitr standby on slave with skewed time

From: Simon Riggs <simon(at)2ndquadrant(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Robert Treat <xzilla(at)users(dot)sourceforge(dot)net>, pgsql-admin(at)postgresql(dot)org
Subject: Re: pitr standby on slave with skewed time
Date: 2008-07-11 17:15:57
Message-ID: 1215796557.4051.1551.camel@ebony.2ndQuadrant (view raw or flat)
Thread:
Lists: pgsql-admin
On Fri, 2008-07-11 at 12:15 -0400, Tom Lane wrote:
> Robert Treat <xzilla(at)users(dot)sourceforge(dot)net> writes:
> > Was review a clients config/setup and ran across a pitr warm standby scenario
> > where the master machine is set to the current time, but the slave's time is 
> > currently sitting back in the month of May. Outside of getting ntp setup on 
> > the machine, I am wondering if I need to do anything special with the 
> > postgresql setup, or if just setting the correct date on the machine is a 
> > safe enough operation that nothing else would need to be done (like re-doing 
> > the base backup). Any thoughts? 
> 
> AFAIR you should be all right ... PITR only looks at WAL indexes, not
> file timestamps.

WAL filenames, just in case anybody listening thinks "I didn't create an
index on my WAL, should I?". This is so people that set their pg_xlog
filesystem no file modification timestamps don't screw up their
recovery.

> The slave does watch the current time to decide when to do recovery
> restartpoints, so if you were setting the clock *back* by a large amount
> it might be wise to stop and restart the slave postmaster.  Forward
> should be no problem though.

Yeh, you're good.

-- 
 Simon Riggs           www.2ndQuadrant.com
 PostgreSQL Training, Services and Support


In response to

pgsql-admin by date

Next:From: Jessica RichardDate: 2008-07-12 12:03:46
Subject: best starting points....
Previous:From: Tom LaneDate: 2008-07-11 16:15:39
Subject: Re: pitr standby on slave with skewed time

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group