Source: fai Source-Version: 4.3.2 Tags: patch Hi,
The format of the fstab file does not allow comments to be after a record; they must be on their own line. This makes create_fstab_line produce at least two lines whenever it thinks it should add a comment. Augeas is known to break due to this unexpected format. --- Index: fai-4.3.2/lib/setup-storage/Fstab.pm =================================================================== --- fai-4.3.2/lib/setup-storage/Fstab.pm +++ fai-4.3.2/lib/setup-storage/Fstab.pm @@ -47,9 +47,14 @@ sub create_fstab_line { my ($d_ref, $name, $dev_name) = @_; my @fstab_line = (); + my @comment_line = (); + # add a comment denoting the actual device name in case of UUID or LABEL + push @comment_line, "# device during installation: $dev_name\n" + if ($name =~ /^(UUID|LABEL)=/); + # start with the device key push @fstab_line, $name; # add mount information, never dump, order of filesystem checks @@ -60,22 +65,22 @@ $fstab_line[-1] = 1 if ($d_ref->{mountpoint} eq "/"); $fstab_line[-1] = 0 if ($d_ref->{filesystem} eq "swap"); $fstab_line[-1] = 0 if ($d_ref->{filesystem} eq "tmpfs"); - # add a comment denoting the actual device name in case of UUID or LABEL - push @fstab_line, "# device during installation: $dev_name" - if ($name =~ /^(UUID|LABEL)=/); - # set the ROOT_PARTITION variable, if this is the mountpoint for / $FAI::disk_var{ROOT_PARTITION} = $name if ($d_ref->{mountpoint} eq "/"); # add to the swaplist, if the filesystem is swap $FAI::disk_var{SWAPLIST} .= " " . $dev_name if ($d_ref->{filesystem} eq "swap"); + my $ret = ''; + $ret = join ("\n", @comment_line)."\n" + if (scalar(@comment_line)); # join the columns of one line with tabs - return join ("\t", @fstab_line); + $ret .= join ("\t", @fstab_line); + return $ret; } ################################################################################ -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org