summaryrefslogtreecommitdiff
path: root/ctdb/tools
diff options
context:
space:
mode:
authorAmitay Isaacs <amitay@gmail.com>2018-03-08 14:19:19 +1100
committerMartin Schwenke <martins@samba.org>2018-03-09 07:08:23 +0100
commitefe3a7279ee43d1bd774b7ca22ec14dc233b9c97 (patch)
tree7b999e4d4deaf38b49cad64d3c159fea6a5761a3 /ctdb/tools
parent35cc786d1083cba944b91775982c6a403fe8be20 (diff)
downloadsamba-efe3a7279ee43d1bd774b7ca22ec14dc233b9c97.tar.gz
ctdb-tools: Drop ipiface command from ctdb tool
This command is not used anywhere and also does not work for IPv6 addresses. 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.c30
1 files changed, 0 insertions, 30 deletions
diff --git a/ctdb/tools/ctdb.c b/ctdb/tools/ctdb.c
index 8535c784c93..fa8d880335a 100644
--- a/ctdb/tools/ctdb.c
+++ b/ctdb/tools/ctdb.c
@@ -5870,34 +5870,6 @@ static int control_reloadips(TALLOC_CTX *mem_ctx, struct ctdb_context *ctdb,
return ipreallocate(mem_ctx, ctdb);
}
-static int control_ipiface(TALLOC_CTX *mem_ctx, struct ctdb_context *ctdb,
- int argc, const char **argv)
-{
- ctdb_sock_addr addr;
- char *iface;
- int ret;
-
- if (argc != 1) {
- usage("ipiface");
- }
-
- ret = ctdb_sock_addr_from_string(argv[0], &addr, false);
- if (ret != 0) {
- fprintf(stderr, "Failed to Parse IP %s\n", argv[0]);
- return 1;
- }
-
- iface = ctdb_sys_find_ifname(&addr);
- if (iface == NULL) {
- fprintf(stderr, "Failed to find interface for IP %s\n",
- argv[0]);
- return 1;
- }
- free(iface);
-
- return 0;
-}
-
static const struct ctdb_cmd {
const char *name;
@@ -6065,8 +6037,6 @@ static const struct ctdb_cmd {
"show database statistics", "<dbname|dbid>" },
{ "reloadips", control_reloadips, false, false,
"reload the public addresses file", "[all|<pnn-list>]" },
- { "ipiface", control_ipiface, true, false,
- "Find the interface an ip address is hosted on", "<ip>" },
};
static const struct ctdb_cmd *match_command(const char *command)