I am developing with slony1-2.2.4. I have setup two nodes replicating from a single producer and I'm simply trying to make one of the current subscribers replicate from the other. I understand the single purpose of the RESUBSCRIBE NODE operation is to make this happen. So I have created a resubscribe node script but everywhere I run it returns the error "subscribeSet() must be called on origin." Eventually I discovered that even while running on the origin host, slonik reaches out to the new provider host to generate the error (See the session below. I recreated the function on the new provider with "YYY" markup.) I am completely blocked with the resubscribe operation now. Thanks in advance for any insights. root@ams9.nss1.tn:/tmp# cat doresub-2.slk cluster name = ams_cluster; node 1 admin conninfo='dbname=ams host=198.18.102.35 user=ams_slony sslmode=verify-ca sslcert=/usr/local/akamai/.ams_certs/complete-ams_slony.crt sslkey=/usr/local/akamai/.ams_certs/ams_slony.private_key sslrootcert=/usr/local/akamai/etc/ssl_ca/canonical_ca_roots.pem'; node 3 admin conninfo='dbname=ams host=198.18.102.35 user=ams_slony sslmode=verify-ca sslcert=/usr/local/akamai/.ams_certs/complete-ams_slony.crt sslkey=/usr/local/akamai/.ams_certs/ams_slony.private_key sslrootcert=/usr/local/akamai/etc/ssl_ca/canonical_ca_roots.pem'; resubscribe node (origin = 1, provider = 3, receiver = 2); root@ams9.nss1.tn:/tmp# root@ams9.nss1.tn:/tmp# slonik doresub-2.slk doresub-2.slk:19: PGRES_FATAL_ERROR lock table "_ams_cluster".sl_event_lock, "_ams_cluster".sl_config_lock;select "_ams_cluster".resubscribeNode(1, 3, 2); - ERROR: Slony-I: subscribeSet() YYY must be called on origin root@ams9.nss1.tn:/tmp# root@ams9.nss1.tn:/tmp# emacs doresub-2.slk root@ams9.nss1.tn:/tmp# cat doresub-2.slk cluster name = ams_cluster; node 1 admin conninfo='dbname=ams host=198.18.102.35 user=ams_slony sslmode=verify-ca sslcert=/usr/local/akamai/.ams_certs/complete-ams_slony.crt sslkey=/usr/local/akamai/.ams_certs/ams_slony.private_key sslrootcert=/usr/local/akamai/etc/ssl_ca/canonical_ca_roots.pem'; resubscribe node (origin = 1, provider = 3, receiver = 2); root@ams9.nss1.tn:/tmp# root@ams9.nss1.tn:/tmp# slonik doresub-2.slk doresub-2.slk:11: ERROR: no admin conninfo for node 3 root@ams9.nss1.tn:/tmp#
If you add a node 2 admin conninfo='....' statement to the top of your script does it do anything differently?
Ouch. Now that I look again, I see I misconfigured the node 1 path as the node 3, which explains a lot. After fixing that, slonik returns "ERROR: no admin conninfo for node 2,² and after applying your suggestion, the resubscribe goes through. Sorry to bother! Tom :-)
I think this bug can be closed.