Partitions are misaligned when using GPT on disks w/ 4096 byte physical sectors
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OEM Priority Project |
Fix Released
|
Critical
|
Chris Van Hoof | ||
Precise |
Fix Released
|
Critical
|
James M. Leddy | ||
Quantal |
Fix Released
|
Critical
|
Chris Van Hoof | ||
partman-base (Debian) |
Fix Released
|
Unknown
|
|||
partman-base (Ubuntu) |
Fix Released
|
Critical
|
Colin Watson | ||
Precise |
Fix Released
|
Critical
|
Colin Watson | ||
Quantal |
Fix Released
|
Critical
|
Colin Watson |
Bug Description
[Impact] GPT partitioning always uses cylinder alignment, which is pessimal for performance on most modern disks.
[Test Case] Do a server install on a blank disk with the 'partman-
[Regression Potential] The plausible things that might go wrong that are worth testing are: (a) it is possible that a bug might cause partitions to be misaligned with things such as large gaps between them or crazy sizes, so check that their sizes look vaguely reasonable; (b) non-GPT partitioning (i.e. in practice the traditional PC MBR partition table format) should not be changed as a result of this work.
Original report follows:
I'm doing a fully preseeded install using a partman-auto disk recipe. This is an EFI install which obviously uses GPT. When I launch Disk Utility is complains that the EFI fat32 partition and the next ext4 Linux partition are misaligned by 3072 bytes and 2048 bytes respectively.
When I dump the partitioning out in parted, I can see that the partition begins on logical sector 34:
$ sudo parted /dev/sda unit s print
Model: ATA ST9500423AS (scsi)
Disk /dev/sda: 976773168s
Sector size (logical/physical): 512B/4096B
Partition Table: gpt
Number Start End Size File system Name Flags
1 34s 390659s 390626s fat32 boot
2 390660s 39453160s 39062501s ext4
So the partition begins right after the GPT headers, but since this is a 4096 byte physical sector drive, this does not begin on a physical sector boundary. It should begin on logical sector 40 (physical sector 5) to have proper alignment.
I'm not sure if this should be filed against partman-auto since this is a fully preseeded install or just partman-base.
ProblemType: Bug
DistroRelease: Ubuntu 12.04
Package: ubiquity (not installed)
ProcVersionSign
Uname: Linux 3.2.0-24-generic x86_64
NonfreeKernelMo
ApportVersion: 2.0.1-0ubuntu7
Architecture: amd64
Date: Thu May 31 08:45:45 2012
DistributionCha
# This is a distribution channel descriptor
# For more information see http://
canonical-
InstallCmdLine: BOOT_IMAGE=
InstallationMedia: Ubuntu 12.04 "Precise" - Build amd64 LIVE Binary 20120523-03:49
ProcEnviron:
TERM=xterm
PATH=(custom, no user)
LANG=en_US.UTF-8
SHELL=/bin/bash
SourcePackage: ubiquity
UpgradeStatus: No upgrade log present (probably fresh install)
Changed in oem-priority: | |
assignee: | nobody → James M. Leddy (jm-leddy) |
Changed in partman-base (Ubuntu): | |
status: | New → Incomplete |
assignee: | nobody → Colin Watson (cjwatson) |
importance: | Undecided → High |
Changed in partman-base (Ubuntu): | |
status: | Incomplete → Confirmed |
Changed in partman-base (Ubuntu): | |
importance: | High → Critical |
tags: | added: rls-mgr-p-tracking |
Changed in oem-priority: | |
importance: | High → Critical |
Changed in oem-priority: | |
status: | New → Incomplete |
status: | Incomplete → Confirmed |
Changed in oem-priority: | |
assignee: | James M. Leddy (jm-leddy) → Chris van Hoof (vanhoof) |
tags: | added: rls-q-incoming |
Changed in partman-base (Ubuntu Precise): | |
status: | New → Confirmed |
importance: | Undecided → Critical |
assignee: | nobody → Colin Watson (cjwatson) |
milestone: | none → ubuntu-12.04.1 |
tags: | removed: rls-mgr-p-tracking rls-q-incoming |
Changed in partman-base (Ubuntu Quantal): | |
status: | Confirmed → In Progress |
milestone: | none → quantal-alpha-3 |
description: | updated |
description: | updated |
Changed in partman-base (Ubuntu Precise): | |
status: | Confirmed → In Progress |
Changed in partman-base (Debian): | |
status: | Unknown → Fix Released |
Changed in oem-priority: | |
status: | Confirmed → In Progress |
Changed in oem-priority: | |
status: | In Progress → Fix Committed |
Changed in partman-base (Debian): | |
status: | Fix Released → New |
Changed in partman-base (Debian): | |
status: | New → Fix Released |
Also, note that the "partman/ alignment= minimal" was just used as a test to see if it made any difference. I found this issue without using any special kernel command line option.
Also, I'm attaching the disk-recipe I used for the install.