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

[OSSTEST PATCH 09/36] preseed_create: osstest-erase-other-disks: workaround creating /dev/sdXD files



Sometime, it can happen that the erase-other-disks script fails and
indicate that /dev/sda1 isn't a block device anymore. This happened
when /dev/sda was erased before /dev/sda1. So to avoid this, we will
zero the partitions of ${disk} first, and hopefully the error won't
happen again.

Signed-off-by: Anthony PERARD <anthony.perard@xxxxxxxxxx>
---
 Osstest/Debian.pm | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Osstest/Debian.pm b/Osstest/Debian.pm
index 7d6f9778..36c05551 100644
--- a/Osstest/Debian.pm
+++ b/Osstest/Debian.pm
@@ -1305,7 +1305,7 @@ for sd in sd hd; do
     udevadm settle
     log "\${sd} devices present after: `echo /dev/\${sd}*`"
 done
-for dev in ${disk}*; do
+for dev in ${disk}?* ${disk}*; do
     zero
 done
 echo ===
-- 
Anthony PERARD




 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.