|
Basically, since you have done a failover, all bets are off with the
old node 1. >From the slony documention regarding failover: http://gborg.postgresql.org/project/slony1/genpage.php?howto_failover Step 3) After the failover is complete and node2 accepts write operations against the tables, remove all remnants of node1's configuration information with the slonik command drop node (id = 1, event node = 2); After failover, getting back node1 After the above failover, the data stored on node1 must be considered out of sync with the rest of the nodes. Therefore, the only way to get node1 back and transfer the master role to it is to rebuild it from scratch as a slave, let it catch up and then follow the switchover procedure. ----------------------------------------------------------------------------------------------------------------- To to re-add node 1. A. On node 2 drop node (id = 1, event node = 2); B. Modify $NODE1NAME , $NODE2NAME , $NODE1HOST & $NODE2HOST in the script below as needed and execute from node 2 ================================================================================================== slonik <<_EOF_ #-- # define the namespace the replication system uses in our example it is # slony_example #-- CLUSTER NAME = $COMETCLUSTER; #-- # admin conninfo's are used by slonik to connect to the nodes one for each # node on each side of the cluster, the syntax is that of PQconnectdb in # the C-API # -- node 1 admin conninfo = 'dbname=$NODE1NAME host=$NODE1HOST port=$PGPORT user=$REPLICATIONUSER'; node 2 admin conninfo = 'dbname=$NODE2NAME host=$NODE2HOST1 port=$PGPORT user=$REPLICATIONUSER'; STORE NODE ( ID = 1, COMMENT = 'Your Comments Here' ); store path (server = 1, client = 2, conninfo='dbname=$NODE1NAME host=$NODE1HOST port=$PGPORT user=$REPLICATIONUSER '); store path (server = 2, client = 1, conninfo='dbname=$NODE2NAME host=$NODE2HOST port=$PGPORT user=$REPLICATIONUSER '); store listen (origin=1, provider = 1, receiver =2); store listen (origin=2, provider = 2, receiver =1); store node (id=1,event node = 2, comment = 'Slave node'); subscribe set (id = 1, provider = 2, receiver = 1, forward = no); _EOF_ ================================================================================================== -- Melvin Davidson CCT - Database Developer 303-798-9228 ext. 305 |
_______________________________________________ Slony1-general mailing list [email protected] http://gborg.postgresql.org/mailman/listinfo/slony1-general
