Revision dc7d923e lib/cmdlib.py
b/lib/cmdlib.py | ||
---|---|---|
14334 | 14334 |
REQ_BGL = False |
14335 | 14335 |
|
14336 | 14336 |
def ExpandNames(self): |
14337 |
self.needed_locks = {} |
|
14338 |
# We need all nodes to be locked in order for RemoveExport to work, but we |
|
14339 |
# don't need to lock the instance itself, as nothing will happen to it (and |
|
14340 |
# we can remove exports also for a removed instance) |
|
14341 |
self.needed_locks[locking.LEVEL_NODE] = locking.ALL_SET |
|
14337 |
self.needed_locks = { |
|
14338 |
# We need all nodes to be locked in order for RemoveExport to work, but |
|
14339 |
# we don't need to lock the instance itself, as nothing will happen to it |
|
14340 |
# (and we can remove exports also for a removed instance) |
|
14341 |
locking.LEVEL_NODE: locking.ALL_SET, |
|
14342 |
|
|
14343 |
# Removing backups is quick, so blocking allocations is justified |
|
14344 |
locking.LEVEL_NODE_ALLOC: locking.ALL_SET, |
|
14345 |
} |
|
14346 |
|
|
14347 |
# Allocations should be stopped while this LU runs with node locks, but it |
|
14348 |
# doesn't have to be exclusive |
|
14349 |
self.share_locks[locking.LEVEL_NODE_ALLOC] = 1 |
|
14342 | 14350 |
|
14343 | 14351 |
def Exec(self, feedback_fn): |
14344 | 14352 |
"""Remove any export. |
Also available in: Unified diff