ctdb-daemon: Add tracking of migration records
[sfrench/samba-autobuild/.git] / ctdb / server / ctdb_ltdb_server.c
index 8ff963419f15197fd0236d6bedad26fc40098b23..677078be6a87e3d3b29b9b56c4be2b32e02d274c 100644 (file)
@@ -1027,6 +1027,15 @@ again:
                return -1;
        }
 
                return -1;
        }
 
+       ret = ctdb_migration_init(ctdb_db);
+       if (ret != 0) {
+               DEBUG(DEBUG_ERR,
+                     ("Failed to setup migration tracking for db '%s'\n",
+                      ctdb_db->db_name));
+               talloc_free(ctdb_db);
+               return -1;
+       }
+
        ctdb_db->generation = ctdb->vnn_map->generation;
 
        DEBUG(DEBUG_NOTICE,("Attached to database '%s' with flags 0x%x\n",
        ctdb_db->generation = ctdb->vnn_map->generation;
 
        DEBUG(DEBUG_NOTICE,("Attached to database '%s' with flags 0x%x\n",