summaryrefslogtreecommitdiff
path: root/source4/dsdb/repl
diff options
context:
space:
mode:
authorMatthieu Patou <mat@matws.net>2011-11-27 12:24:23 +0100
committerMatthieu Patou <mat@matws.net>2011-12-05 18:23:07 +0100
commit2f8a84bb7b430c68c06f4121df6905b163f7ae71 (patch)
tree1f65cc3dfcec37d756b136aa1aa08e7eb155f09b /source4/dsdb/repl
parent105d388c9bfd542755cfe46adff337a6333f54e8 (diff)
downloadsamba-2f8a84bb7b430c68c06f4121df6905b163f7ae71.tar.gz
samba-2f8a84bb7b430c68c06f4121df6905b163f7ae71.tar.bz2
samba-2f8a84bb7b430c68c06f4121df6905b163f7ae71.zip
s4-drs: mark WERR_DS_DRA_BUSY as a non error in DsReplicaUpdateRefs
Diffstat (limited to 'source4/dsdb/repl')
-rw-r--r--source4/dsdb/repl/drepl_out_helpers.c24
1 files changed, 22 insertions, 2 deletions
diff --git a/source4/dsdb/repl/drepl_out_helpers.c b/source4/dsdb/repl/drepl_out_helpers.c
index 71d2c3bc51..8cfafb9527 100644
--- a/source4/dsdb/repl/drepl_out_helpers.c
+++ b/source4/dsdb/repl/drepl_out_helpers.c
@@ -827,8 +827,28 @@ static void dreplsrv_update_refs_done(struct tevent_req *subreq)
nt_errstr(status),
r->in.req.req1.dest_dsa_dns_name,
r->in.req.req1.naming_context->dn));
- tevent_req_nterror(req, status);
- return;
+ /*
+ * TODO we are currently not sending the
+ * DsReplicaUpdateRefs at the correct moment,
+ * we do it just after a GetNcChanges which is
+ * not always correct.
+ * Especially when another DC is trying to demote
+ * it will sends us a DsReplicaSync that will trigger a getNcChanges
+ * this call will succeed but the DsRecplicaUpdateRefs that we send
+ * just after will not because the DC is in a demote state and
+ * will reply us a WERR_DS_DRA_BUSY, this error will cause us to
+ * answer to the DsReplicaSync with a non OK status, the other DC
+ * will stop the demote due to this error.
+ * In order to cope with this we will for the moment concider
+ * a DS_DRA_BUSY not as an error.
+ * It's not ideal but it should not have a too huge impact for
+ * running production as this error otherwise never happen and
+ * due to the fact the send a DsReplicaUpdateRefs after each getNcChanges
+ */
+ if (!W_ERROR_EQUAL(werr, WERR_DS_DRA_BUSY)) {
+ tevent_req_nterror(req, status);
+ return;
+ }
}
DEBUG(4,("UpdateRefs OK for %s %s\n",