Discussion:
[Bucardo-general] RDS as a Master with Bucardo
Saiful Muhajir
2016-08-30 09:25:37 UTC
Permalink
Hi,

Has anyone tried using RDS as a master using Bucardo? I read this
https://aws.amazon.com/blogs/aws/rds-postgres-read-replicas/ on Data Export
part and it seems that using RDS as a master with Bucardo is possible.

I tried it myself and found no error while setting up. But, kicking the
sync is not working with error below:

KID (bcrdsync) Kid has died, error is: DBD::Pg::st execute failed: ERROR:
relation "bucardo.bucardo_truncate_trigger" does not exist LINE 1:
...ident(tname), MAX(EXTRACT(epoch FROM cdate)) FROM
bucardo.bu...
^ at /usr/local/share/perl/5.18.2/Bucardo.pm line 3299. Line: 5041 Main DB
state: ? Error: none DB bcrdrds2 state: ? Error: none DB bcrdrds3 state:
42P01 Error: 7
KID (bcrdsync) Kid 31286 exiting at cleanup_kid. Sync "bcrdsync" Reason:
DBD::Pg::st execute failed: ERROR: relation
"bucardo.bucardo_truncate_trigger" does not exist LINE 1: ...ident(tname),
MAX(EXTRACT(epoch FROM cdate)) FROM
bucardo.bu...
^ at /usr/local/share/perl/5.18.2/Bucardo.pm line 3299. Line: 5041 Main DB
state: ? Error: none DB bcrdrds2 state: ? Error: none DB bcrdrds3 state:
42P01 Error: 7

I checked the database and there is no bucardo schema nor bucardo database
created. And of course no triggers created on the tables.

FYI, The user I am using has replication role.
bucardouser | Create role, Create DB, Replication | {rds_superuser} |

Am I missing something?

Thank you

--
Regards,

​Saiful​
Saiful Muhajir
2016-09-01 02:27:55 UTC
Permalink
Hi Matthew,

I have successfully setup Bucardo multi-masters myself on my own servers.
And it was working fine. The next step is, I want to setup replication and
use RDS as a master.

To reply your question:
- Bucardo version 5.4.1
- PostgreSQL version 9.5.4

Commands:
$ bucardo add db bcrdrds1 dbname=bucardotest username=bucardo host=
xxxxxx.master.rds.amazonaws.com port=5432
$ bucardo add db bcrdrds2 dbname=bucardotest
$ bucardo add table tb_department db=bcrdrds1 --herd=bcrdherd --verbose
$ bucardo add dbgroup bcrdgroup1 bcrdrds1:source bcrdrds2:target
​$ bucardo add sync bcrdsync herd=bcrdherd dbs=bcrdgroup1

Once I put some data, I execute:
​$ ​bucardo kick bcrdsync

​No error while performing those commands. The error only appear in the log
once kick is fired:
​
​KID (bcrdsync) New kid, sync "bcrdsync" alive=1 Parent=31277 PID=31286
kicked=0
KID (bcrdsync) Kid has died, error is: DBD::Pg::st execute failed: ERROR:
relation "bucardo.bucardo_truncate_trigger" does not exist LINE 1:
...ident(tname), MAX(EXTRACT(epoch FROM cdate)) FROM
bucardo.bu...
^ at /usr/local/share/perl/5.18.2/Bucardo.pm line 3299. Line: 5041 Main DB
state: ? Error: none DB bcrdrds2 state: ? Error: none DB bcrdrds3 state:
42P01 Error: 7
KID (bcrdsync) Kid 31286 exiting at cleanup_kid. Sync "bcrdsync" Reason:
DBD::Pg::st execute failed: ERROR: relation
"bucardo.bucardo_truncate_trigger" does not exist LINE 1: ...ident(tname),
MAX(EXTRACT(epoch FROM cdate)) FROM
bucardo.bu...
^ at /usr/local/share/perl/5.18.2/Bucardo.pm line 3299. Line: 5041 Main DB
state: ? Error: none DB bcrdrds2 state: ? Error: none DB bcrdrds3 state:
42P01 Error: 7 ​



--
Send Bucardo-general mailing list submissions to
To subscribe or unsubscribe via the World Wide Web, visit
https://mail.endcrypt.com/mailman/listinfo/bucardo-general
or, via email, send a message with subject or body 'help' to
You can reach the person managing the list at
When replying, please edit your Subject line so it is more specific
than "Re: Contents of Bucardo-general digest..."
1. Re: Bucardo-general Digest, Vol 106, Issue 5
(Balman, Matthew D. (GSFC-428.0)[Embedded Flight Systems, Inc])
----------------------------------------------------------------------
Message: 1
Date: Tue, 30 Aug 2016 12:18:36 +0000
From: "Balman, Matthew D. (GSFC-428.0)[Embedded Flight Systems, Inc]"
Subject: Re: [Bucardo-general] Bucardo-general Digest, Vol 106, Issue
5
Content-Type: text/plain; charset="iso-8859-1"
Post by Saiful Muhajir
Am I missing something?
What bucardo version are you using?
Please post the setup commands and output.
What versions of the database(s) are you using?
I haven?t done what you?re doing, but this seems like the setup itself
didn?t complete properly and hopefully there is an error message point to
what went wrong.
Either that or you have a permissions issue.
For these kinds of things it can be helpful to try this with very
privileged database and local user to see if the problem goes away and
then reduce permissions.
------------------------------
_______________________________________________
Bucardo-general mailing list
https://mail.endcrypt.com/mailman/listinfo/bucardo-general
End of Bucardo-general Digest, Vol 106, Issue 6
***********************************************
Loading...