The cached query plan is not same as cached data, right? I think the data (node id) should be new since I totally destroied the cluster and rebuilt it.<br><br>The purpose of uninstall and rebuild the cluster is that we want to add the failure node back to cluster and let it be a new slave node rahter than master original.<br>
Is there other method can implement rejoining the cluster?<br><br><div class="gmail_quote">On Wed, Dec 22, 2010 at 10:57 PM, Steve Singer <span dir="ltr"><<a href="mailto:ssinger@ca.afilias.info">ssinger@ca.afilias.info</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">On 10-12-22 02:45 AM, Zhidong She wrote:<br>
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
Hi all,<br>
</blockquote>
<br>
The old connection has a cached query plan for the getLocalNodeId() function.<br>
<br>
If you uninstall a slony node any database connections that were open from before slony might not behave as expected.<br>
<br>
<br>
<br>
<br>
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;"><div><div></div><div class="h5">
<br>
We are using slonyI 2.0.5 to build our master/slave postgres HA solution<br>
for our project. So far slonyI works fine except for a strange<br>
getlocalnodeid issue. Could somebody please help to figure me out?<br>
<br>
The scenario is, we have host A as master (define as node 1 in slonic),<br>
host B (node 2) as slave at beginning. The data was replicated to host B<br>
from A by slony.<br>
Then we stop postgres on host A, and in host B run failover command and<br>
drop node A from cluster. Thus the db service was switch to host B.<br>
<br>
Establish a connection to host B via psql, and execute "select<br>
_cluster.getlocalnodeid('_cluster')", it returns 2. Keep this connection<br>
for a while.<br>
<br>
So far everything is good.<br>
<br>
Stop all slon process on host A and B.<br>
Then start the postgres server on host A, and in both host A and host B,<br>
execute "drop schema _cluster cascade" to clean all the cluster information.<br>
<br>
Build the cluster again, this time host B as master (node 1), host A as<br>
slave (node 2), and start the slon in both nodes.<br>
<br>
Setup a new connection to host B and execute same "select<br>
_cluster.getlocalnodeid('_cluster')", it returns 1.<br>
But in the old connection we kept before, this command still return 2.<br>
At the same time, in old connection, the update/insert/delete operation<br>
can not be synchronized to host A.<br>
It's strange that the cluster is rebuilt and slon is restarted but why<br>
only old connection the localnodeid is still 2 and can not be<br>
resynchronized?<br>
<br>
Anyone idea?<br>
<br>
Thanks very much for your time!<br>
<br>
Br,<br>
Zhidong<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br></div></div>
_______________________________________________<br>
Slony1-general mailing list<br>
<a href="mailto:Slony1-general@lists.slony.info" target="_blank">Slony1-general@lists.slony.info</a><br>
<a href="http://lists.slony.info/mailman/listinfo/slony1-general" target="_blank">http://lists.slony.info/mailman/listinfo/slony1-general</a><br>
</blockquote>
<br>
</blockquote></div><br>