diff options
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 | 2 | ||||
-rw-r--r-- | perl-install/partition_table/dos.pm | 4 | ||||
-rw-r--r-- | perl-install/partition_table/raw.pm | 3 |
5 files changed, 12 insertions, 1 deletions
diff --git a/perl-install/NEWS b/perl-install/NEWS index 5e4068cac..25c3dbf39 100644 --- a/perl-install/NEWS +++ b/perl-install/NEWS @@ -1,5 +1,7 @@ - diskdrake: o "Clear All" defaults to LVM on full disk if drive is >4TB + o do not allow partitions bigger than 2TB-1 on DOS MBR, nor partitions + starting above 2TB-1 - bootloader-config: o handle /boot/xxx files on linux raid1 - fix getting UUID on mdmadm (eg: md0) devices diff --git a/perl-install/install/NEWS b/perl-install/install/NEWS index 4431b8cd1..f811b41bb 100644 --- a/perl-install/install/NEWS +++ b/perl-install/install/NEWS @@ -1,5 +1,7 @@ - diskdrake: o "Clear All" defaults to LVM on full disk if drive is >4TB + o do not allow partitions bigger than 2TB-1 on DOS MBR, nor partitions + starting above 2TB-1 - restore banner on pop up messages (#33753) - handle /boot/xxx files on linux raid1 - when basesystem can't be selected, display the reason diff --git a/perl-install/partition_table.pm b/perl-install/partition_table.pm index 5b2d30aaf..590365536 100644 --- a/perl-install/partition_table.pm +++ b/perl-install/partition_table.pm @@ -219,7 +219,7 @@ sub get_normal_parts_and_holes { $hole, $_; } sort { $a->{start} <=> $b->{start} } grep { !isWholedisk($_) } get_normal_parts($hd); - push @l, { start => $start, size => $last - $start, %$minimal_hole }; + push @l, { start => $start, size => min($last - $start, $hd->max_partition_size), %$minimal_hole } if $start < $hd->max_partition_start; grep { !isEmpty($_) || $_->{size} >= $hd->cylinder_size } @l; } diff --git a/perl-install/partition_table/dos.pm b/perl-install/partition_table/dos.pm index c12b7cba4..2376fce11 100644 --- a/perl-install/partition_table/dos.pm +++ b/perl-install/partition_table/dos.pm @@ -33,6 +33,10 @@ sub last_usable_sector { $hd->{geom}{sectors} * $hd->{geom}{heads} * $hd->{geom}{cylinders}; } +my $two_TB = 2 * 1024 * 1024 * 2048; +sub max_partition_start { $two_TB - 1 } +sub max_partition_size { $two_TB - 1 } + sub get_rawCHS { my ($part) = @_; diff --git a/perl-install/partition_table/raw.pm b/perl-install/partition_table/raw.pm index 925ae6562..c3bc9dcce 100644 --- a/perl-install/partition_table/raw.pm +++ b/perl-install/partition_table/raw.pm @@ -69,6 +69,9 @@ sub last_usable_sector { my ($hd) = @_; $hd->{totalsectors}; } +# no limit +sub max_partition_start { 1e99 } +sub max_partition_size { 1e99 } #- default method for starting a partition, only head size or twice #- is allowed for starting a partition after a cylinder boundarie. |