[PATCH] Use ID_SERIAL to write multipath.conf, but ID_SERIAL_SHORT for UI.

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

 



multipath and multipathd expect the leading "3" in wwids, but that's bad
in the user interface.  So use one for one and the other for the other.
---
 storage/devices.py |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/storage/devices.py b/storage/devices.py
index 5f9d068..436d138 100644
--- a/storage/devices.py
+++ b/storage/devices.py
@@ -2773,7 +2773,8 @@ class MultipathDevice(DiskDevice):
         
             May be overridden by a sub-class for e.g. RDAC handling.
         """
-        self._serial = self._info['ID_SERIAL_SHORT']
+        self._serial_short = self._info['ID_SERIAL_SHORT']
+        self._serial = self._info['ID_SERIAL']
 
     @property
     def identity(self):
@@ -2791,7 +2792,7 @@ class MultipathDevice(DiskDevice):
 
     @property
     def wwid(self):
-        serial = self.identity
+        serial = self._serial_short
         ret = []
         while serial:
             ret.append(serial[:2])
-- 
1.6.5.rc2

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/anaconda-devel-list

[Index of Archives]     [Kickstart]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]
  Powered by Linux