summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--perl-install/raid.pm4
1 files changed, 3 insertions, 1 deletions
diff --git a/perl-install/raid.pm b/perl-install/raid.pm
index de74f55ef..4b4cb8109 100644
--- a/perl-install/raid.pm
+++ b/perl-install/raid.pm
@@ -221,11 +221,13 @@ sub inactivate_all() {
sub prepare_prefixed {
my ($raids) = @_;
+ @$raids or return;
+
my @devices = uniq(map { devices::make($_->{device}) } map { @{$_->{disks}} } @$raids);
output("$::prefix/etc/mdadm.conf",
join(' ', 'DEVICE', @devices) . "\n",
- map { "ARRAY " . devices::make($_->{device}) . " UUID=" . $_->{UUID} . "\n" } @$raids);
+ map { "ARRAY " . devices::make($_->{device}) . " UUID=$_->{UUID} auto=yes\n" } @$raids);
}
sub get_md_info {