Bug 842451 - fdisk doesn't align partition start to 1MiB if +<size>MB is used
Summary: fdisk doesn't align partition start to 1MiB if +<size>MB is used
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: util-linux
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Karel Zak
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-07-23 21:45 UTC by Milan Broz
Modified: 2013-03-01 04:11 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-02-03 14:35:11 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Milan Broz 2012-07-23 21:45:11 UTC
Description of problem:
If there are no topology data (default 512b alignement), fdisk should align new partition start to 1MiB.

Unfortunately, not true if you use SI units:

fdisk /dev/sdb
n -> primary, start is default 2048 sectors (ok), size +256MB
n -> primarym use default

and you will see this:
   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1            2048      502047      250000   83  Linux
/dev/sdb2          502048   312499999   155998976   83  Linux

502048 is not aligned to expected 1MiB. it should be 503808

Fixed here
https://github.com/karelzak/util-linux/commit/c0175e6185ac81843cbad33cbea75abd033f0e66

Version-Release number of selected component (if applicable):
util-linux-2.21.2-2.fc18.x86_64

How reproducible:
see above


Note You need to log in before you can comment on or make changes to this bug.