GNU bug report logs - #35715
parted crashed when extended partition doesn't start on physical sector boundary

Previous Next

Package: parted;

Reported by: Jens Schmidt <crashdump <at> meine-dateien.info>

Date: Mon, 13 May 2019 15:12:01 UTC

Severity: normal

Done: Phillip Susi <phill <at> thesusis.net>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 35715 in the body.
You can then email your comments to 35715 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-parted <at> gnu.org:
bug#35715; Package parted. (Mon, 13 May 2019 15:12:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Jens Schmidt <crashdump <at> meine-dateien.info>:
New bug report received and forwarded. Copy sent to bug-parted <at> gnu.org. (Mon, 13 May 2019 15:12:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Jens Schmidt <crashdump <at> meine-dateien.info>
To: bug-parted <at> gnu.org
Cc: crashdump <at> meine-dateien.info
Subject: parted crashed when extended partition doesn't start on physical
 sector boundary
Date: Mon, 13 May 2019 16:23:15 +0200
Hello developer team.

parted crashed when extended partition doesn't
start on physical sector boundary.

On my older laptop's HDD the extended partition isn't aligned to
4096 bytes boundary but to 512 bytes. This is not really a problem
because extended partition has only one sector in size and the speed
reduction due to unaligned partition is not likely to be noticeable.

parted never should crash when reading such a partition table!

Please fix ASAP because this bug is at least five years old and has
many entries in Google search.


Output of: 'parted /dev/sda unit co print unit s print'
------
Backtrace has 14 calls on stack:
  14: /lib/i386-linux-gnu/libparted.so.2(ped_assert+0x51) [0xb76cd471]
  13: /lib/i386-linux-gnu/libparted.so.2(+0x2320a) [0xb76e820a]
  12: /lib/i386-linux-gnu/libparted.so.2(+0xdaf8) [0xb76d2af8]
  11: /lib/i386-linux-gnu/libparted.so.2(ped_disk_add_partition+0x2ac) [0xb76d34fc]
  10: /lib/i386-linux-gnu/libparted.so.2(+0x22af7) [0xb76e7af7]
  9: /lib/i386-linux-gnu/libparted.so.2(+0x22bee) [0xb76e7bee]
  8: /lib/i386-linux-gnu/libparted.so.2(+0x22b30) [0xb76e7b30]
  7: /lib/i386-linux-gnu/libparted.so.2(+0x23e60) [0xb76e8e60]
  6: /lib/i386-linux-gnu/libparted.so.2(ped_disk_new+0x5b) [0xb76d30cb]
  5: parted(+0x682b) [0x8007282b]
  4: parted(non_interactive_mode+0x8f) [0x800780bf]
  3: parted(main+0x10e3) [0x80070713]
  2: /lib/i386-linux-gnu/libc.so.6(__libc_start_main+0xf6) [0xb74b8286]
  1: parted(+0x489c) [0x8007089c]

[..]

Assertion (metadata_length > 0) at ../../../libparted/labels/dos.c:2313
in function add_logical_part_metadata() failed.
------


Output of: 'fdisk -l /dev/sda'
------------
Disk /dev/sda: 931,5 GiB, 1000204886016 bytes, 1953525168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: dos
Disk identifier: 0xbfd1a1b9

Device     Boot      Start        End    Sectors   Size Id Type
/dev/sda1             2048     206847     204800   100M 83 Linux
/dev/sda2  *        206848  335636479  335429632   160G  7 HPFS/NTFS/exFAT
/dev/sda3        335636480  335699967      63488    31M ef EFI (FAT-12/16/32)
/dev/sda4        335703422 1953524292 1617820871 771,4G  5 Extended
/dev/sda5        335706112  339899775    4193664     2G 82 Linux swap / Solaris
/dev/sda6        339899776  457083369  117183594  55,9G 83 Linux
/dev/sda7        457085424  574269935  117184512  55,9G 83 Linux
/dev/sda8        574271984 1530140671  955868688 455,8G 83 Linux
/dev/sda9       1530142720 1851125759  320983040 153,1G 83 Linux
/dev/sda10      1851127808 1953319492  102191685  48,7G 83 Linux
/dev/sda11      1953323008 1953524292     201285  98,3M 83 Linux
------------


Best regards
Jens




Reply sent to Phillip Susi <phill <at> thesusis.net>:
You have taken responsibility. (Thu, 16 May 2019 18:06:01 GMT) Full text and rfc822 format available.

Notification sent to Jens Schmidt <crashdump <at> meine-dateien.info>:
bug acknowledged by developer. (Thu, 16 May 2019 18:06:02 GMT) Full text and rfc822 format available.

Message #10 received at 35715-done <at> debbugs.gnu.org (full text, mbox):

From: Phillip Susi <phill <at> thesusis.net>
To: Jens Schmidt <crashdump <at> meine-dateien.info>
Cc: 35715-done <at> debbugs.gnu.org
Subject: Re: bug#35715: parted crashed when extended partition doesn't start
 on physical sector boundary
Date: Thu, 16 May 2019 14:05:07 -0400
This has nothing to do with alignment; it is because your first and
second extended partitions have no space between them to hold the EBR.
This space has been required by parted always and in the past all other
partitioning tools were believed to honor this requirement, but for some
unknown reason, a few people every now and then somehow find another
partititiong tool that lays out their table this way and parted won't
accept it.

Jens Schmidt writes:

> Hello developer team.
>
> parted crashed when extended partition doesn't
> start on physical sector boundary.
>
> On my older laptop's HDD the extended partition isn't aligned to
> 4096 bytes boundary but to 512 bytes. This is not really a problem
> because extended partition has only one sector in size and the speed
> reduction due to unaligned partition is not likely to be noticeable.
>
> parted never should crash when reading such a partition table!
>
> Please fix ASAP because this bug is at least five years old and has
> many entries in Google search.
>
>
> Output of: 'parted /dev/sda unit co print unit s print'
> ------
> Backtrace has 14 calls on stack:
>   14: /lib/i386-linux-gnu/libparted.so.2(ped_assert+0x51) [0xb76cd471]
>   13: /lib/i386-linux-gnu/libparted.so.2(+0x2320a) [0xb76e820a]
>   12: /lib/i386-linux-gnu/libparted.so.2(+0xdaf8) [0xb76d2af8]
>   11: /lib/i386-linux-gnu/libparted.so.2(ped_disk_add_partition+0x2ac) [0xb76d34fc]
>   10: /lib/i386-linux-gnu/libparted.so.2(+0x22af7) [0xb76e7af7]
>   9: /lib/i386-linux-gnu/libparted.so.2(+0x22bee) [0xb76e7bee]
>   8: /lib/i386-linux-gnu/libparted.so.2(+0x22b30) [0xb76e7b30]
>   7: /lib/i386-linux-gnu/libparted.so.2(+0x23e60) [0xb76e8e60]
>   6: /lib/i386-linux-gnu/libparted.so.2(ped_disk_new+0x5b) [0xb76d30cb]
>   5: parted(+0x682b) [0x8007282b]
>   4: parted(non_interactive_mode+0x8f) [0x800780bf]
>   3: parted(main+0x10e3) [0x80070713]
>   2: /lib/i386-linux-gnu/libc.so.6(__libc_start_main+0xf6) [0xb74b8286]
>   1: parted(+0x489c) [0x8007089c]
>
> [..]
>
> Assertion (metadata_length > 0) at ../../../libparted/labels/dos.c:2313
> in function add_logical_part_metadata() failed.
> ------
>
>
> Output of: 'fdisk -l /dev/sda'
> ------------
> Disk /dev/sda: 931,5 GiB, 1000204886016 bytes, 1953525168 sectors
> Units: sectors of 1 * 512 = 512 bytes
> Sector size (logical/physical): 512 bytes / 4096 bytes
> I/O size (minimum/optimal): 4096 bytes / 4096 bytes
> Disklabel type: dos
> Disk identifier: 0xbfd1a1b9
>
> Device     Boot      Start        End    Sectors   Size Id Type
> /dev/sda1             2048     206847     204800   100M 83 Linux
> /dev/sda2  *        206848  335636479  335429632   160G  7 HPFS/NTFS/exFAT
> /dev/sda3        335636480  335699967      63488    31M ef EFI (FAT-12/16/32)
> /dev/sda4        335703422 1953524292 1617820871 771,4G  5 Extended
> /dev/sda5        335706112  339899775    4193664     2G 82 Linux swap / Solaris
> /dev/sda6        339899776  457083369  117183594  55,9G 83 Linux
> /dev/sda7        457085424  574269935  117184512  55,9G 83 Linux
> /dev/sda8        574271984 1530140671  955868688 455,8G 83 Linux
> /dev/sda9       1530142720 1851125759  320983040 153,1G 83 Linux
> /dev/sda10      1851127808 1953319492  102191685  48,7G 83 Linux
> /dev/sda11      1953323008 1953524292     201285  98,3M 83 Linux
> ------------
>
>
> Best regards
> Jens





Information forwarded to bug-parted <at> gnu.org:
bug#35715; Package parted. (Fri, 17 May 2019 09:33:01 GMT) Full text and rfc822 format available.

Message #13 received at 35715 <at> debbugs.gnu.org (full text, mbox):

From: Jens Schmidt <crashdump <at> meine-dateien.info>
To: 35715 <at> debbugs.gnu.org
Subject: Re: bug#35715: closed (Re: bug#35715: parted crashed when extended
 partition doesn't start on physical sector boundary)
Date: Fri, 17 May 2019 11:32:13 +0200
OK. Thank you.

But I can't believe that a segmentation fault is the common way to say
that a partition table doesn't conform to your reference setting.


Am 16.05.2019, 18:05 schrieb help-debbugs <at> gnu.org (GNU bug Tracking
System):

> Your bug report
>
> #35715: parted crashed when extended partition doesn't start on
> physical sector boundary
>
> which was filed against the parted package, has been closed.
>
> The explanation is attached below, along with your original report.
> If you require more details, please reply to 35715 <at> debbugs.gnu.org.
>




Information forwarded to bug-parted <at> gnu.org:
bug#35715; Package parted. (Fri, 17 May 2019 14:42:01 GMT) Full text and rfc822 format available.

Message #16 received at 35715 <at> debbugs.gnu.org (full text, mbox):

From: Phillip Susi <phill <at> thesusis.net>
To: Jens Schmidt <crashdump <at> meine-dateien.info>
Cc: 35715 <at> debbugs.gnu.org
Subject: Re: bug#35715: closed (Re: bug#35715: parted crashed when extended
 partition doesn't start on physical sector boundary)
Date: Fri, 17 May 2019 10:41:08 -0400
Jens Schmidt writes:

> OK. Thank you.
>
> But I can't believe that a segmentation fault is the common way to say
> that a partition table doesn't conform to your reference setting.

It was an assertion failure, not a seg fault.




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Sat, 15 Jun 2019 11:24:03 GMT) Full text and rfc822 format available.

This bug report was last modified 6 years and 6 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.