<div>Sorry for late on this, its due to actual Production swap implementation. Though I tested as suggested, I didnt get time to post my reply. </div><div>After doing vigorous testing by taking into consideration Steve &amp; Jan points, we succeded it without any problem.</div>
<div><font color="#33cc00"><br></font></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><font color="#33cc00">This analysis is flawed. The two event numbers are from different origins and therefore, don&#39;t compare to each other. The combination of ev_origin,ev_seqno can never be higher on any node, than it is on the origin itself.</font></blockquote>
<div><br></div><div>Yes, my analysis has flaw. Its no where related to SEQ.No...which I analyzed and every node <a href="http://seq.no">seq.no</a> number is independed by itself. </div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
<font color="#33cc00">To simulate this problem, Steve and I were pointing out, do the following:<br>1. Create your setup as before.<br>2. Stop the streaming replication (simulating the network communication problem)<br>3. Update a row on the master and wait for the SYNC to replicate.<br>
4. Stop the slon processes. DO NOT let the streaming replica catch up with the now DEAD master. Assume the master and all its data, including WAL, have become unavailable.<br>5. Promote DR-master and do the two store path commands.<br>
6. Start slon processes.<br>7. Update another row on the new master.<br>8. Compare table content on master and slave.<br>You can detect the problem before step 5 by comparing the ev_seqno with ev_origin=old-master on the DR-master and slave. Whichever is higher should be promoted to master. In the unlikely case that it is the Slony slave, you will have to rebuild the DR-master from scratch, though.</font></blockquote>
<div><br></div><div>Yep, I could able to detect before Step 5. </div><div><br></div><div>In short of our actual production swap, we stopped application(NO DML&#39;s) and Slony. Checked DR-master(which is warm standby) is complete sync with Master(primary). Promoted DR-master, did changes to store_path on both the ends. Started slon on both the nodes. Sync catch-up well. We have taken complete care of NOT happening any Step 2 or 3 though .. :)</div>
<div><br></div><div>Thanks once again.</div><div><br></div><div>--Raghav</div><div><br></div>