[Parted-maintainers] Bug#923561: parted: Incorrect optimal alignment for USB device

Phillip Susi phill at thesusis.net
Mon Mar 4 15:01:54 GMT 2019


On 3/1/2019 6:04 PM, Kevin Locke wrote:
> Presumably the error occurs because parted is using the optimal_io_size
> for alignment.  Since optimal_io_size is based on USB constraints rather
> than disk constraints, it does not seem suitable for partition layout.
> 
> I would suggest ignoring optimal_io_size if it is not a multiple of
> minimum_io_size, as done by cryptsetup[1].  Alternatively, 33553920
> could be ignored specifically, since it seems common for USB disks.
> 
> This issue has been discussed elsewhere:
> https://www.saout.de/pipermail/dm-crypt/2016-January/004934.html
> https://bugzilla.redhat.com/show_bug.cgi?id=1513820
> https://unix.stackexchange.com/q/340484
> https://linux-blog.anracom.com/2018/12/03/linux-ssd-partition-alignment-problems-with-external-usb-to-sata-controllers-i/

Interesting.  It sounds like USB and MD are using optimal_io_size in
fundamentally incompatible ways.  The question then is: is USB doing the
wrong thing ( and should be fixed ), or is the very definition of
optimal_io_size fundamentally broken?



More information about the Parted-maintainers mailing list