Bug 842451

Summary: fdisk doesn't align partition start to 1MiB if +<size>MB is used
Product: [Fedora] Fedora Reporter: Milan Broz <mbroz>
Component: util-linuxAssignee: Karel Zak <kzak>
Status: CLOSED CURRENTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: rawhideCC: jonathan, kzak, mluscon, pvrabec
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-02-03 14:35:11 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

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