try to wait for mapping device mapper
authorGui Chen <gui.chen@intel.com>
Fri, 17 May 2013 05:40:23 +0000 (01:40 -0400)
committerGui Chen <gui.chen@intel.com>
Fri, 17 May 2013 05:40:23 +0000 (01:40 -0400)
a delay for setup multipath device will throw error:
/dev/loop0X: No such file or directory

Signed-off-by: Gui Chen <gui.chen@intel.com>
mic/utils/partitionedfs.py

index 226e4d9..f1102d4 100644 (file)
@@ -448,6 +448,10 @@ class PartitionedMount(Mount):
                 raise MountError("Failed to map partitions for '%s'" %
                                  d['disk'].device)
 
+            # FIXME: there is a bit delay for multipath device setup,
+            # wait 10ms for the setup
+            import time
+            time.sleep(10)
             d['mapped'] = True
 
     def __unmap_partitions(self):