Revision 3aecd2c7 lib/utils.py
b/lib/utils.py | ||
---|---|---|
39 | 39 |
|
40 | 40 |
from ganeti import logger |
41 | 41 |
from ganeti import errors |
42 |
from ganeti import constants |
|
42 | 43 |
|
43 | 44 |
|
44 | 45 |
_locksheld = [] |
... | ... | |
95 | 96 |
|
96 | 97 |
def _GetLockFile(subsystem): |
97 | 98 |
"""Compute the file name for a given lock name.""" |
98 |
return "/var/lock/ganeti_lock_%s" % subsystem
|
|
99 |
return "%s/ganeti_lock_%s" % (constants.LOCK_DIR, subsystem)
|
|
99 | 100 |
|
100 | 101 |
|
101 | 102 |
def Lock(name, max_retries=None, debug=False): |
Also available in: Unified diff