diff options
author | Amitay Isaacs <amitay@gmail.com> | 2017-08-04 14:24:33 +1000 |
---|---|---|
committer | Martin Schwenke <martins@samba.org> | 2017-08-14 09:01:21 +0200 |
commit | 31c2d0af04aba6974fd69e1b8a7f21d8d34e5c0a (patch) | |
tree | aee870aba4fa5e386beb6055eb55940d3dad4ef1 /ctdb/tools | |
parent | 0f424a118813c9f0afc060bdc39a4f0b84eeb6e3 (diff) | |
download | samba-31c2d0af04aba6974fd69e1b8a7f21d8d34e5c0a.tar.gz |
ctdb-tools: Drop check_srvids command from ctdb tool
Signed-off-by: Amitay Isaacs <amitay@gmail.com>
Reviewed-by: Martin Schwenke <martin@meltin.net>
Diffstat (limited to 'ctdb/tools')
-rw-r--r-- | ctdb/tools/ctdb.c | 40 |
1 files changed, 0 insertions, 40 deletions
diff --git a/ctdb/tools/ctdb.c b/ctdb/tools/ctdb.c index 98f63e8b2a0..1ed6f6128cd 100644 --- a/ctdb/tools/ctdb.c +++ b/ctdb/tools/ctdb.c @@ -3381,44 +3381,6 @@ static int control_deltickle(TALLOC_CTX *mem_ctx, struct ctdb_context *ctdb, return 0; } -static int control_check_srvids(TALLOC_CTX *mem_ctx, struct ctdb_context *ctdb, - int argc, const char **argv) -{ - uint64_t *srvid; - uint8_t *result; - int ret, i; - - if (argc == 0) { - usage("check_srvids"); - } - - srvid = talloc_array(mem_ctx, uint64_t, argc); - if (srvid == NULL) { - fprintf(stderr, "Memory allocation error\n"); - return 1; - } - - for (i=0; i<argc; i++) { - srvid[i] = strtoull(argv[i], NULL, 0); - } - - ret = ctdb_ctrl_check_srvids(mem_ctx, ctdb->ev, ctdb->client, - ctdb->cmd_pnn, TIMEOUT(), srvid, argc, - &result); - if (ret != 0) { - fprintf(stderr, "Failed to check srvids on node %u\n", - ctdb->cmd_pnn); - return ret; - } - - for (i=0; i<argc; i++) { - printf("SRVID 0x%" PRIx64 " %s\n", srvid[i], - (result[i] ? "exists" : "does not exist")); - } - - return 0; -} - static int control_listnodes(TALLOC_CTX *mem_ctx, struct ctdb_context *ctdb, int argc, const char **argv) { @@ -6067,8 +6029,6 @@ static const struct ctdb_cmd { "add a tickle", "<ip>:<port> <ip>:<port>" }, { "deltickle", control_deltickle, false, true, "delete a tickle", "<ip>:<port> <ip>:<port>" }, - { "check_srvids", control_check_srvids, false, true, - "check if srvid is registered", "<id> [<id> ...]" }, { "listnodes", control_listnodes, true, true, "list nodes in the cluster", NULL }, { "reloadnodes", control_reloadnodes, false, false, |