Multi Masters and Replication - unworkable

Discuss your pilot or production implementation with other Zimbra admins or our engineers.
1441Cam
Posts: 16
Joined: Sat Sep 13, 2014 2:30 am

Multi Masters and Replication - unworkable

Postby 1441Cam » Fri Oct 05, 2012 12:22 pm

Hi,
I am trying to plan a scalable deployment and have tried to use the multi-master replication offered by ZCS 8. After a bit of investigation it looks like it isn't a workable solution.
The multi server install documentation isn't clear on what topologies are supported. I read somewhere that multi master replication should have up to four masters.
It follows that it might be possible to add replicas (the documentation suggests that multi master and replicas can co-exist, and the installation scripts allow it)
However during testing I find that the replicas are only really talking to one master, and if that master (in a multi master group) is shut down the replica stops getting updates. This leads to inconsistency as reads on the replica show no changes, whereas writes to the multi-master group succeed. The test case for this is pretty trivial and I have explained it in a previous post here.
From my limited knowledge of openldap (a couple of days of experimentation) it looks like replicas just aren't compatible with the multi-master approach. Please correct me if I'm wrong.
So it looks like Zimbra supports the single master with 0 or more replicas (where the master is a single point of failure), OR a multi-master configuration with no replicas (which is limited in its ability to scale).
Also zmreplcheck seems worse than useless, in my test case it fails to report that the master is still being updated and the replica is out of date. This seems to be because it is querying contextCSN and only looking at the first value returned - there are three values returned for that attribute.
The Perl code in zmreplchk is doing:
$pcsn = $entry->get_value('contextCSN');
so $pcsn will take only the first value. I have modified zmreplchk to dump out all the values but in its present state it doesn't have the logic to interpret them correctly. However it is clear that the servers are not in sync!
Is anyone at Zimbra working on multi-master as it seems not quite ready for GA in ZCS 8???


User avatar
quanah
Zimbra Alumni
Zimbra Alumni
Posts: 1668
Joined: Fri Sep 12, 2014 10:33 pm
Contact:

Multi Masters and Replication - unworkable

Postby quanah » Fri Oct 05, 2012 2:47 pm

I suggest you read
In">https://www.openldap.org/doc/admin24/replication.html#N-Way%20Multi-Master%20replication
In
particularly, look at the diagram in section 18.3.4.1.1
A replica can only talk to a single "master". If you want it to take updates from all masters, then you need to use a load balancer in front of the multi-masters that provides a single address for them. There is nothing Zimbra specific about this.
Please file a bug about zmreplchk in the Zimbra bugzilla.
Thanks.
--
Quanah Gibson-Mount
Product Architect, Symas http://www.symas.com/
OpenLDAP Core team http://www.openldap.org/project/
1441Cam
Posts: 16
Joined: Sat Sep 13, 2014 2:30 am

Multi Masters and Replication - unworkable

Postby 1441Cam » Fri Oct 05, 2012 3:28 pm

[quote user="quanah"]I suggest you read
In">https://www.openldap.org/doc/admin24/replication.html#N-Way%20Multi-Master%20replication
In
particularly, look at the diagram in section 18.3.4.1.1
A replica can only talk to a single "master". If you want it to take updates from all masters, then you need to use a load balancer in front of the multi-masters that provides a single address for them. There is nothing Zimbra specific about this.
Please file a bug about zmreplchk in the Zimbra bugzilla.
Thanks.[/QUOTE]
It looks like I've got some reading material for the weekend. I had seen the openldap docs but the Zimbra documents seemed at a higher level, and I was hoping not to have to become a LDAP expert to use Zimbra.
It isn't clear to me how I could put a load balancer between the replica and the multi-master servers I have described to make it work - the replica would 'refreshAndPersist' with provider as one load balanced IP address - but a message would get through to one of the multi-masters, which would send updates to the replica. If the master was shut down, would the other masters take over sending updates?
I think the ZCS 8 documents could be much improved wrt LDAP architectures even by including a couple of example diagrams, or pointing out that replicas and multi masters won't mix without exotic networking tricks.
I will look at a patch / bug for zmreplchk.
Thanks for the prompt reply :)
-Cam
1441Cam
Posts: 16
Joined: Sat Sep 13, 2014 2:30 am

Multi Masters and Replication - unworkable

Postby 1441Cam » Tue Oct 09, 2012 6:20 am

Bug covering zmreplchk behaviour created:
Bug 77898 – zmreplchk shortcomings
as hinted in the bug I have extended zmreplchk but my limited knowledge of LDAP has resulted in inelegant code. I'm sure the Zimbra team will find a more elegant solution. If my patched version would help, let me know.
-Cam

Return to “Administrators”

Who is online

Users browsing this forum: Google [Bot] and 20 guests