Commit 419c3348 authored by Klaus Aehlig's avatar Klaus Aehlig
Browse files

Improve the heuristic of guessing masterd's livelock file



As, during startup, masterd uses livelock files for special
tasks, the lexicographically last livelock file for masterd
is the masterd_check_agreement_ file. However, when debugging,
we want the primary livelock file. Hence extend the prefix to
include the leading digit 1 of the time, which will work till
Wed May 18 05:33:20 CEST 2033.
Signed-off-by: default avatarKlaus Aehlig <aehlig@google.com>
Reviewed-by: default avatarPetr Pudlak <pudlak@google.com>
parent bb4013df
......@@ -643,7 +643,7 @@ def Wconfd(opts, args): # pylint: disable=W0613
ToStderr("Command 'listlocks' takes precisely one argument.")
return 1
wconfdcontext = (int(args[1]),
utils.livelock.GuessLockfileFor("masterd"))
utils.livelock.GuessLockfileFor("masterd_1"))
result = wconfd.Client().ListLocks(wconfdcontext)
print "Answer: %s" % (result,)
else:
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment