diff --git a/sambacc/ctdb.py b/sambacc/ctdb.py index c9fcdb5..28cc036 100644 --- a/sambacc/ctdb.py +++ b/sambacc/ctdb.py @@ -527,8 +527,9 @@ def __enter__(self) -> CLILeaderStatus: _logger.error(f"command {pnn_cmd!r} failed: {err!r}") except FileNotFoundError: _logger.error(f"ctdb command ({pnn_cmd!r}) not found") - # recmaster = - recmaster_cmd = samba_cmds.ctdb["recmaster"] + # recmaster = + admin_cmd = samba_cmds.ctdb_leader_admin_cmd() + recmaster_cmd = samba_cmds.ctdb[admin_cmd] try: out = subprocess.check_output(list(recmaster_cmd)) recmaster = out.decode("utf8").strip()