[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

[PATCH rhel6-branch 1/2] Resolve /dev/disk/ devices during rescue (#605312)



Convert symlinks in /dev/disk/ to their real paths before trying to
resolve them when mounting the disks for rescue.

Resolves: rhbz#605312
---
 storage/devicetree.py |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/storage/devicetree.py b/storage/devicetree.py
index 56721e8..728191e 100644
--- a/storage/devicetree.py
+++ b/storage/devicetree.py
@@ -2304,6 +2304,9 @@ class DeviceTree(object):
             if device is None:
                 log.error("failed to resolve device %s" % devspec)
         elif devspec.startswith("/dev/"):
+            if devspec.startswith("/dev/disk/"):
+                devspec = os.path.realpath(devspec)
+
             # device path
             device = self.getDeviceByPath(devspec)
             if device is None:
-- 
1.7.3.2


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]