Quantcast
Channel: MySQL Forums - NDB clusters
Viewing all articles
Browse latest Browse all 1560

Active-active replication (no replies)

$
0
0
Hello.
I'm trying to use active-active replication.
Configs are same for both SQL servers:


server-id=1

log-bin-trust-function-creators = 1
log-bin=log-bin.log
binlog-format=ROW
ndb-log-orig=1
ndb-log-transaction-id=1
#ndb-log-update-as-write=0

log-slave-updates=1

ndb-log-apply-status=1

replicate-wild-do-table=devel.%
replicate-wild-do-table=mysql.ndb_apply_status
replicate-wild-do-table=mysql.ndb_replication

(only "server-id" is different for another server).

I have many questions. Please, help me to go into the matter.


Firstly, is this config correct for active-active replication?


Secondly, what exactly I must have in mysql.ndb_replication table?
According to documentation,
> Because the conflict detection algorithms employed by NDB$EPOCH() and NDB$EPOCH_TRANS() are asymmetric, you must use different values for the primary slave's and secondary slave's server_id entries.

Now I have such row:

*************************** 1. row ***************************
db: devel
table_name: %
server_id: 1
binlog_type: 0
conflict_fn: NDB$EPOCH2_TRANS()
1 rows in set (0,01 sec)


I must add another row with server_id=2?



Thirdly, now I get errors about LOST EVENT. Is it normal for active-active replication? I suppose that both servers know current position of binlog at remote server and at localhost, so both can continue to download binlog from remote server from right position. We have conflict resolution, so servers can figure out what rows are correct.
If servers know position for downloading binlog and can deal with inconsistency, there must not be LOST EVENTS errors. Am I wrong?


Thanks.

Viewing all articles
Browse latest Browse all 1560

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>