[Fai-commit] r6459 - branches/experimental/patches
Michael Tautschnig
mt at alioth.debian.org
Fri Apr 15 19:29:51 UTC 2011
Author: mt
Date: 2011-04-15 19:29:47 +0000 (Fri, 15 Apr 2011)
New Revision: 6459
Added:
branches/experimental/patches/setup-storage_virtual-bugfix
Modified:
branches/experimental/patches/series
Log:
Don't try to set partition types on virtual configs
Modified: branches/experimental/patches/series
===================================================================
--- branches/experimental/patches/series 2011-04-15 19:27:21 UTC (rev 6458)
+++ branches/experimental/patches/series 2011-04-15 19:29:47 UTC (rev 6459)
@@ -12,3 +12,4 @@
make-fai-nfsroot_add-keys
extrbase-hook
setup-storage_preserve-in-place
+setup-storage_virtual-bugfix
Added: branches/experimental/patches/setup-storage_virtual-bugfix
===================================================================
--- branches/experimental/patches/setup-storage_virtual-bugfix (rev 0)
+++ branches/experimental/patches/setup-storage_virtual-bugfix 2011-04-15 19:29:47 UTC (rev 6459)
@@ -0,0 +1,19 @@
+2011-04-15 Michael Tautschnig <mt at debian.org>
+
+ * setup-storage/Commands.pm: Virtual disks don't have partition types.
+Index: trunk/lib/setup-storage/Commands.pm
+===================================================================
+--- trunk.orig/lib/setup-storage/Commands.pm
++++ trunk/lib/setup-storage/Commands.pm
+@@ -180,8 +180,9 @@
+ # make sure this device really exists (we can't check for the partition
+ # as that may be created later on
+ (-b $disk) or die "Specified disk $disk does not exist in this system!\n";
+- # set the raid/lvm unless this is an entire disk flag
+- return 0 if ($part_no == -1);
++ # set the raid/lvm unless this is an entire disk flag or a virtual disk
++ return 0 if ($part_no == -1 ||
++ (defined($FAI::configs{"PHY_$disk"}) && $FAI::configs{"PHY_$disk"}{virtual}));
+ my $pre = "exist_$d";
+ $pre .= ",cleared2_$disk" if (defined($FAI::configs{"PHY_$disk"}));
+ &FAI::push_command( "parted -s $disk set $part_no $t on", $pre, "type_${t}_$d" );
More information about the Fai-commit
mailing list