Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- add in a schema only dump onto the new slave
- ## add the node to the cluster
- slonik <<_EOF_
- cluster name = cross_slony;
- node 1 admin conninfo = 'dbname=ubermaster host=MASTER user=slony password=PASSWORD';
- node 2 admin conninfo = 'dbname=ubermaster host=SLAVE user=slony password=PASSWORD';
- store node (id=2, comment = 'PSI Slave Node 1');
- store path (server = 1, client = 2, conninfo='dbname=ubermaster host=MASTER user=slony password=PASSWORD');
- store path (server = 2, client = 1, conninfo='dbname=ubermaster host=SLAVE user=slony password=PASSWORD');
- _EOF_
- turn on slony on slave
- ## subscribe node to the set
- slonik <<_EOF_
- cluster name = cross_slony;
- node 1 admin conninfo = 'dbname=ubermaster host=MASTER user=slony password=PASSWORD';
- node 2 admin conninfo = 'dbname=ubermaster host=SLAVE user=slony password=PASSWORD';
- subscribe set ( id = 1, provider = 1, receiver = 2, forward = no);
- _EOF_
- Subscription is picked up fine on the slave:
- 2010-04-29 12:38:44 GMT DEBUG2 remoteWorkerThread_1: Received event 1,3486676 ENABLE_SUBSCRIPTION
- 2010-04-29 12:38:44 GMT DEBUG1 copy_set 1
- 2010-04-29 12:38:44 GMT DEBUG4 version for "dbname=ubermaster host=MASTER user=slony password=PASSWORD" is 80310
- 2010-04-29 12:38:44 GMT DEBUG1 remoteWorkerThread_1: connected to provider DB
- 2010-04-29 12:38:44 GMT DEBUG2 remoteWorkerThread_1: all tables for set 1 found on subscriber
- 2010-04-29 12:38:44 GMT DEBUG2 remoteWorkerThread_1: copy_set SYNC found, use event seqno 3486674.
- 2010-04-29 12:38:44 GMT DEBUG2 remoteWorkerThread_1: 0.010 seconds to build initial setsync status
- 2010-04-29 12:38:44 GMT DEBUG1 remoteWorkerThread_1: disconnected from provider DB
- 2010-04-29 12:38:44 GMT DEBUG1 copy_set 1 done in 0.043 seconds
- 2010-04-29 12:38:44 GMT CONFIG enableSubscription: sub_set=1
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement