Revision 5574047a lib/bdev.py
b/lib/bdev.py | ||
---|---|---|
415 | 415 |
def Assemble(self): |
416 | 416 |
"""Assemble the device. |
417 | 417 |
|
418 |
This is a no-op for the LV device type. Eventually, we could |
|
419 |
lvchange -ay here if we see that the LV is not active. |
|
418 |
We alway run `lvchange -ay` on the LV to ensure it's active before |
|
419 |
use, as there were cases when xenvg was not active after boot |
|
420 |
(also possibly after disk issues). |
|
420 | 421 |
|
421 | 422 |
""" |
422 |
return True |
|
423 |
result = utils.RunCmd(["lvchange", "-ay", self.dev_path]) |
|
424 |
if result.failed: |
|
425 |
logger.Error("Can't activate lv %s: %s" % (self.dev_path, result.output)) |
|
426 |
return not result.failed |
|
423 | 427 |
|
424 | 428 |
def Shutdown(self): |
425 | 429 |
"""Shutdown the device. |
Also available in: Unified diff