diff options
author | Thierry Vignaud <thierry.vignaud@gmail.com> | 2016-07-30 16:27:37 +0200 |
---|---|---|
committer | Thierry Vignaud <thierry.vignaud@gmail.com> | 2016-07-31 17:31:11 +0200 |
commit | 0810aa1a87ba9ded271f3c3d8037787d9866e1a0 (patch) | |
tree | b08f5f37bcf1e3889b701d33e58ccc9459e4070f /perl-install | |
parent | fa5d71d34b1193fea0e290bb0586d0ff02747366 (diff) | |
download | drakx-0810aa1a87ba9ded271f3c3d8037787d9866e1a0.tar drakx-0810aa1a87ba9ded271f3c3d8037787d9866e1a0.tar.gz drakx-0810aa1a87ba9ded271f3c3d8037787d9866e1a0.tar.bz2 drakx-0810aa1a87ba9ded271f3c3d8037787d9866e1a0.tar.xz drakx-0810aa1a87ba9ded271f3c3d8037787d9866e1a0.zip |
do not switch from gpt to dos scheme on small disk
or more generally, do not switch from current scheme to default one if
not told otherwise
else we get errors when partitionning after clearing them, such as:
"INTERNAL ERROR: unknown device vda7"
Diffstat (limited to 'perl-install')
-rw-r--r-- | perl-install/NEWS | 2 | ||||
-rw-r--r-- | perl-install/install/NEWS | 2 | ||||
-rw-r--r-- | perl-install/partition_table.pm | 4 |
3 files changed, 7 insertions, 1 deletions
diff --git a/perl-install/NEWS b/perl-install/NEWS index c1182f8e1..c60639b19 100644 --- a/perl-install/NEWS +++ b/perl-install/NEWS @@ -1,5 +1,7 @@ - diskdrake: o first usable sector is LBA34 for GPT + o respect used scheme when clearing a disk + (ie do not switch from gpt to dos scheme on small disk) - drakboot: o fix .old backup for grub2's grub.cfg - authentication: add support for sha256/sha512 and default to sha512 diff --git a/perl-install/install/NEWS b/perl-install/install/NEWS index 3686461a8..e94dfad12 100644 --- a/perl-install/install/NEWS +++ b/perl-install/install/NEWS @@ -2,6 +2,8 @@ o fix .old backup for grub2's grub.cfg - partionning: o first usable sector is LBA34 for GPT + o respect used scheme when clearing a disk + (ie do not switch from gpt to dos scheme on small disk) Version 17.52 - 17 July 2016 diff --git a/perl-install/partition_table.pm b/perl-install/partition_table.pm index 08fa8ab25..294e18052 100644 --- a/perl-install/partition_table.pm +++ b/perl-install/partition_table.pm @@ -229,7 +229,9 @@ sub _default_type { sub initialize { my ($hd, $o_type) = @_; - my $type = $o_type || _default_type($hd); + my $current = c::get_disk_type($hd->{file}); + $current = 'dos' if $current eq 'msdos'; + my $type = $o_type || $current || _default_type($hd); require "partition_table/$type.pm"; "partition_table::$type"->initialize($hd); |