[Bucardo-general] Failed to add sync: DBD::Pg::st execute failed: ERROR: Could not find "account_" inside the "public" schema on database "db"! at line 30.
Пацев Антон
patsev.anton at gmail.com
Tue May 16 13:30:20 UTC 2017
Hello!
i have error when when try sync
I have script for automation:
cat ./replica_add.sh
#!/bin/sh
. ./replica_env.sh
for dbname in $dbname_list ;do
dbname_s="`echo $dbname|sed -r 's/\-/_/g'`"
echo "--------------------------------------------------"
echo "DBNAME - ${dbname}"
echo "--------------------------------------------------"
bucardo add database ${dbname_s}_node1 dbname=${dbname} dbhost=${master}
dbuser=postgres
bucardo add database ${dbname_s}_node2 dbname=${dbname} dbhost=${slave}
dbuser=postgres
bucardo add table all --db=${dbname_s}_node1 --herd=${dbname_s}_herd
strict_check=0
bucardo add sequence all --db=${dbname_s}_node1 --herd=${dbname_s}_herd
bucardo add dbgroup ${dbname_s}_servers_group ${dbname_s}_node1:source
bucardo add dbgroup ${dbname_s}_servers_group ${dbname_s}_node2:target
#bucardo add sync ${dbname_s}_sync herd=${dbname_s}_herd
dbs=${dbname_s}_servers_group onetimecopy=1 strict_checking=0
done
echo "--------------------------------------------------"
#sudo bucardo restart
echo "done"
cat ./replica_sync_add.sh
#!/bin/sh
. ./replica_env.sh
for dbname in $dbname_list ;do
dbname_s="`echo $dbname|sed -r 's/\-/_/g'`"
echo "--------------------------------------------------"
echo "DBNAME - ${dbname}"
echo "--------------------------------------------------"
bucardo add sync ${dbname_s}_sync herd=${dbname_s}_herd
dbs=${dbname_s}_servers_group onetimecopy=1 strict_checking=0
done
echo "--------------------------------------------------"
#sudo bucardo restart
echo "done"
Changed pg_hba.conf for access. Install bucardo install.
./replica_add.sh
--------------------------------------------------
DBNAME - subs_online_catalogue_dev
--------------------------------------------------
Added database "subs_online_catalogue_dev_node1"
Added database "subs_online_catalogue_dev_node2"
Creating relgroup: subs_online_catalogue_dev_herd
Added table public.account_ to relgroup subs_online_catalogue_dev_herd
.....
New tables added: 207
Sorry, no sequences were found
New sequences added: 0
Created dbgroup "subs_online_catalogue_dev_servers_group"
Added database "subs_online_catalogue_dev_node1" to dbgroup
"subs_online_catalogue_dev_servers_group" as source
Added database "subs_online_catalogue_dev_node2" to dbgroup
"subs_online_catalogue_dev_servers_group" as target
./replica_sync_add.sh
--------------------------------------------------
DBNAME - subs_online_catalogue_dev
--------------------------------------------------
WARNING: Issuing rollback() due to DESTROY without explicit disconnect()
of DBD::Pg::db handle dbname=subs_online_catalogue_dev;host=10.233.4.16 at
line 1018.
CONTEXT: PL/Perl function "validate_sync"
SQL statement "SELECT validate_sync('subs_online_catalogue_dev_sync')"
PL/Perl function "validate_sync"
Failed to add sync: DBD::Pg::st execute failed: ERROR: Could not find
"account_" inside the "public" schema on database
"subs_online_catalogue_dev_node2"! at line 30.
CONTEXT: PL/Perl function "validate_sync" at /sbin/bucardo line 4612.
--------------------------------------------------
done
What is wrong?
--
С уважением, Антон Пацев.
Best regards, Anton Patsev.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.endcrypt.com/pipermail/bucardo-general/attachments/20170516/095a9bf5/attachment.html>
More information about the Bucardo-general
mailing list