Search Postgresql Archives

Re: While converting the Master to Standby , FATAL: timeline 2 of the primary does not match recovery target timeline 1

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 06/18/2011 05:22 AM, Nithya Rajendran wrote:


We are doing Master/Standby setup, We unplugged the master server, then the standby server became the master (by creating trigger file).

 

While converting the old master to new slave server, We are getting the following error in old master,



You can't make a system that used to be in the replication set join it again the way you're trying to do.  The timeline feature you're seeing errors from is there to keep you from making mistakes like this.

Even though this system used to be the master, it still needs to go through the full procedure for creating a new standby:  start a backup, sync all the files from the master, send new archive WAL data over.  The fact that this used to be the master doesn't change that.

If the database is large, it may be worthwhile to use rsync and features such as its "--inplace" feature to make the copy from new master -> old master faster.  Since it has older copies of the files, the copy can go faster than one to an empty system would take.  But you can't just convert the old master to be a standby of a new master. 

-- 
Greg Smith   2ndQuadrant US    greg@xxxxxxxxxxxxxxx   Baltimore, MD
PostgreSQL Training, Services, and 24x7 Support  www.2ndQuadrant.us
"PostgreSQL 9.0 High Performance": http://www.2ndQuadrant.com/books

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux