recoverd: ctdb_takeover_run() uses CTDB_CONTROL_IPREALLOCATED
authorMartin Schwenke <martin@meltin.net>
Thu, 21 Feb 2013 02:13:09 +0000 (13:13 +1100)
committerAmitay Isaacs <amitay@gmail.com>
Mon, 6 May 2013 03:38:21 +0000 (13:38 +1000)
This means "ipreallocated" is now run on stopped nodes.

Signed-off-by: Martin Schwenke <martin@meltin.net>
server/ctdb_takeover.c

index 15a8bbb409d06280dd43e0d7f6192adaed4ce204..44393a71ee2f49ebbcfeda75e9fa61e48e15f3c5 100644 (file)
@@ -2456,12 +2456,10 @@ ipreallocated:
         * IPs have moved.  Once upon a time this event only used to
         * update natwg.
         */
-       data.dptr  = discard_const("ipreallocated");
-       data.dsize = strlen((char *)data.dptr) + 1; 
        nodes = list_of_connected_nodes(ctdb, nodemap, tmp_ctx, true);
-       if (ctdb_client_async_control(ctdb, CTDB_CONTROL_RUN_EVENTSCRIPTS,
+       if (ctdb_client_async_control(ctdb, CTDB_CONTROL_IPREALLOCATED,
                                      nodes, 0, TAKEOVER_TIMEOUT(),
-                                     false, data,
+                                     false, tdb_null,
                                      NULL, fail_callback,
                                      callback_data) != 0) {
                DEBUG(DEBUG_ERR, (__location__ " failed to send control to run eventscripts with \"ipreallocated\"\n"));