diff options
author | Pascal Rigaux <pixel@mandriva.com> | 2005-06-01 04:05:36 +0000 |
---|---|---|
committer | Pascal Rigaux <pixel@mandriva.com> | 2005-06-01 04:05:36 +0000 |
commit | 31c599c27d11d6b1c9a9407b99839b79eea94a99 (patch) | |
tree | 11e9fab5eda88f65e04ffde2db17acb4ce784e43 | |
parent | 0bb3c1756eaf0d3207278eee90bf510eb974712e (diff) | |
download | drakx-backup-do-not-use-31c599c27d11d6b1c9a9407b99839b79eea94a99.tar drakx-backup-do-not-use-31c599c27d11d6b1c9a9407b99839b79eea94a99.tar.gz drakx-backup-do-not-use-31c599c27d11d6b1c9a9407b99839b79eea94a99.tar.bz2 drakx-backup-do-not-use-31c599c27d11d6b1c9a9407b99839b79eea94a99.tar.xz drakx-backup-do-not-use-31c599c27d11d6b1c9a9407b99839b79eea94a99.zip |
set the LABEL after formatting, or drop it if we don't know how to set it
-rw-r--r-- | perl-install/fs/format.pm | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/perl-install/fs/format.pm b/perl-install/fs/format.pm index 1b7b977cd..ce4d7e73a 100644 --- a/perl-install/fs/format.pm +++ b/perl-install/fs/format.pm @@ -93,6 +93,14 @@ sub part_raw { if ($fs_type eq 'ext3') { disable_forced_fsck($dev); } + if ($part->{device_LABEL}) { + if (member($fs_type, qw(ext2 ext3))) { + run_program::run("tune2fs", "-L", $part->{device_LABEL}, devices::make($dev)); + } else { + log::l("dropping LABEL=$part->{device_LABEL} since we don't know how to set labels for fs_type $part->{fs_type}"); + delete $part->{device_LABEL}, $part->{prefer_device_LABEL}; + } + } set_isFormatted($part, 1); } |