-
Notifications
You must be signed in to change notification settings - Fork 35
Description
I have a problem with duplication of data.
I have a 2 instances of InfluxDB (in1, in2), on the front of it there is a influxdb-srelay with HA config. Every write command is executed in in1/in2 instance.
Also on in1/in2 I have a 2 instances of syncflux in configuration -> at in1
there is master:in1,slave:in2, at in2
there is master:in2, slave:in1.
I'm executing some write queries, and everything is ok, queries are executed on both instances.
And now, I'm shutting down in2
instance still sending write command. Next I'm restarting in2
-> syncflux are starting to process chunks from in1
and it writes it to in2
instance. The problem is that some of data which was before shutting down in instance in2 are also retrieved from in1, and added as a duplicates in process chunks command.
My configs are simple as examples from github, srelay are using HA example, syncflux are using default HA configuration with initial-replication = "both" (changing to none doesn't help)
Why syncflux duplicates the data? Why it not checks that data is present in the database?
At the screenshot there is example:
19.28 - Servers was started
19.29 - I've executed a one write command
19.30 - I've stopped a second instance, and execute two write commands.
19.32 - I've started secondary database, and syncflux rebuild database, but it add a duplication of write command at 19.29, so at secondary graph there is a 2 instead of 1