Revision 0628a50a lib/hypervisor/hv_lxc.py
b/lib/hypervisor/hv_lxc.py | ||
---|---|---|
1 | 1 |
# |
2 | 2 |
# |
3 | 3 |
|
4 |
# Copyright (C) 2010 Google Inc. |
|
4 |
# Copyright (C) 2010, 2013 Google Inc.
|
|
5 | 5 |
# |
6 | 6 |
# This program is free software; you can redistribute it and/or modify |
7 | 7 |
# it under the terms of the GNU General Public License as published by |
... | ... | |
425 | 425 |
@return: Problem description if something is wrong, C{None} otherwise |
426 | 426 |
|
427 | 427 |
""" |
428 |
if os.path.exists(self._ROOT_DIR): |
|
429 |
return None |
|
430 |
else: |
|
431 |
return "The required directory '%s' does not exist" % self._ROOT_DIR |
|
428 |
msgs = [] |
|
429 |
|
|
430 |
if not os.path.exists(self._ROOT_DIR): |
|
431 |
msgs.append("The required directory '%s' does not exist" % |
|
432 |
self._ROOT_DIR) |
|
433 |
|
|
434 |
try: |
|
435 |
self._GetCgroupMountPoint() |
|
436 |
except errors.HypervisorError, err: |
|
437 |
msgs.append(str(err)) |
|
438 |
|
|
439 |
return self._FormatVerifyResults(msgs) |
|
432 | 440 |
|
433 | 441 |
@classmethod |
434 | 442 |
def PowercycleNode(cls): |
Also available in: Unified diff