diff --git a/ctdb/client/ctdb_client.c b/ctdb/client/ctdb_client.c index ad7aa4f8dcb..4997818bca7 100644 --- a/ctdb/client/ctdb_client.c +++ b/ctdb/client/ctdb_client.c @@ -2948,6 +2948,11 @@ int ctdb_set_socketname(struct ctdb_context *ctdb, const char *socketname) return 0; } +const char *ctdb_get_socketname(struct ctdb_context *ctdb) +{ + return ctdb->daemon.name; +} + /* return the pnn of this node */ diff --git a/ctdb/include/ctdb_client.h b/ctdb/include/ctdb_client.h index 4bb14e960ee..e9aa8d17fb1 100644 --- a/ctdb/include/ctdb_client.h +++ b/ctdb/include/ctdb_client.h @@ -87,6 +87,7 @@ void ctdb_set_max_lacount(struct ctdb_context *ctdb, unsigned count); int ctdb_set_address(struct ctdb_context *ctdb, const char *address); int ctdb_set_socketname(struct ctdb_context *ctdb, const char *socketname); +const char *ctdb_get_socketname(struct ctdb_context *ctdb); /* tell ctdb what nodes are available. This takes a filename, which will contain