[Bucardo-general] resync a table
videanuadrian at yahoo.com
Tue May 3 05:40:14 UTC 2016
I have a 4 database servers replicated with bucardo 5.x. All servers acts as sources.Initially there was only one server and as the application using the database could not be stopped when i put the dbs on other servers i`ve got a backup from "yesterday".Everything seems to work as expected, but now i have to recover the records from that missing day that bucardo would not replicate them by itself. I`ve googled a little bit and found that issuing a query like:
UPDATE tableX SET id=id;
would do the job as bucardo will pickup the update and replicate the missing records.This works for the majority of my tables.
The problem is the 2 tables have a unique constraint on a pair of columns, and these records were deleted and readded on the original table.So now in the old table i have this pair with an id and in the new table the same pair with other id. Due to this the inserts cannot be performed as it breaks the unique constraint.
What I want to do (but i do not know how to do this exactly) would be to stop the replication, truncate all the data from old table, and then repopulate the data from the original table.
What are the steps to do this ?
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Bucardo-general