repl: Do not report all replication failures at level 0
authorAndrew Bartlett <abartlet@samba.org>
Mon, 21 Mar 2016 02:51:12 +0000 (15:51 +1300)
committerAndrew Bartlett <abartlet@samba.org>
Mon, 6 Jun 2016 14:36:23 +0000 (16:36 +0200)
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Garming Sam <garming@catalyst.net.nz>
source4/dsdb/repl/replicated_objects.c

index d2acff30b5bc329badda3a3df0fc9744863d43d8..674074c350f84ea0ec4fdea95a12bdc9db63b21d 100644 (file)
@@ -836,8 +836,13 @@ WERROR dsdb_replicated_objects_commit(struct ldb_context *ldb,
                        dsdb_reference_schema(ldb, cur_schema, false);
                }
 
-               DEBUG(0,("Failed to apply records: %s: %s\n",
-                        ldb_errstring(ldb), ldb_strerror(ret)));
+               if (!W_ERROR_EQUAL(objects->error, WERR_DS_DRA_MISSING_PARENT)) {
+                       DEBUG(1,("Failed to apply records: %s: %s\n",
+                                ldb_errstring(ldb), ldb_strerror(ret)));
+               } else {
+                       DEBUG(3,("Missing parent while attempting to apply records: %s\n",
+                                ldb_errstring(ldb)));
+               }
                ldb_transaction_cancel(ldb);
                TALLOC_FREE(tmp_ctx);