Hi Andrew,
On 10/09/2010 18:42, Andrew Findlay wrote:
On Fri, Sep 03, 2010 at 08:06:31PM +0200, Jonathan CLARKE wrote:
I don't have any problems using the 2 syncrepl statements side-by-side on the slave. When one master goes offline, replication continues from the other, etc.
I have done some more tests with a new slave machine having two syncrepl clauses to talk to two mirrormode masters. This time I pre-loaded the database from a recent LDIF backup and sync was achieved in a few seconds. There were a few grumbles of the form:
Sep 10 17:05:41 nis2 slapd[6571]: conn=-1 op=0: attribute "mail" index delete failure Sep 10 17:05:42 nis2 slapd[6571]: => bdb_idl_delete_key: c_get failed: DB_LOCK_DEADLOCK: Locker killed to resolve a deadlock (-30994)
I suppose these might lead to trouble later, but what is more worrying is that I then ran slapcat backups of the two masters and the new slave, and there is a difference. The two masters have identical data, but...
The slave has one entry where pwdAccountLockedTime is missing. This is an account that was locked by admin action between the initial load data being dumped from the master server and the new slave being started up, so it should have been replicated from one master or the other by syncrepl. Every other attribute in the entry is identical, including the modifyTimestamp which records when the pwdAccountLockedTime attribute was added. I know that the entry did not change after that, as I have a full changelog on both masters.
This is most likely a separate issue. Updates to the ppolicy operational attributes are not replicated like "standard" changes, but instead written directly into the local database. So it's to be expected that you see differences on these attributes between syncrepl consumers/providers.
See the ppolicy_forward_updates option in slapo-ppolicy(5) for details and a possible workaround.
Jonathan