Re: [PATCH4/6] Don't create array if already exists

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

 




On 04/10/2009 03:33 PM, Jacek Danecki wrote:
If array was created before this patch disallow to create new
MDRaidArrayDevice object.


Tests for created before MD array is done only if iswmd parameter was set in kernel commad line.
commit bc8f7be0ed366c72b8216d5fdd56ecb4ca3771f8
Author: Jacek Danecki <Jacek.Danecki@xxxxxxxxx>
Date:   Tue Apr 14 13:34:21 2009 -0400

    Don't create array if already exists

diff --git a/storage/devicetree.py b/storage/devicetree.py
index 03fd1f8..b103ec9 100644
--- a/storage/devicetree.py
+++ b/storage/devicetree.py
@@ -999,6 +999,12 @@ class DeviceTree(object):
                 log.warning("invalid data for %s: %s" % (name, e))
                 return
 
+            if md_uuid and md_is_isw():
+                md_array = self.getDeviceByUuid(md_uuid)
+                if md_array:
+                    log.debug("MD array md_uuid=%s already created" % (md_uuid))
+                    return md_array
+            
             device = MDRaidArrayDevice(name,
                                        level=md_level,
                                        memberDevices=md_devices,
_______________________________________________
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