From: Karel Zak <kzak@redhat.com>
To: Craig <util-linux_contact@magister.com.au>
Cc: util-linux@vger.kernel.org
Subject: Re: ***Urgent***! Fdisk: GPT support utterly breaks hybrid MBR; *must* have disable option! :(
Date: Wed, 9 Oct 2013 16:16:28 +0200 [thread overview]
Message-ID: <20131009141628.GB940@x2.net.home> (raw)
In-Reply-To: <alpine.LFD.2.03.1310092211290.7406@aslan.magister.com.au>
On Wed, Oct 09, 2013 at 10:23:13PM +1100, Craig wrote:
> Sorry if this isn't the place, but curiously, I could find no bug-reporting
> info in the documentation, and definitely I consider this one a bug! Adding
> experimental GPT support to fdisk has completely broken its ability to read
> the MBR for a hybrid partitioning scheme. To be blunt, I don't see the
It's more generic problem, we ignore MBR for hybrid GPT on more
places (for example in kernel and libblkid).
(Just for the record, hybrid GPT is ugly non-standard hack.)
> point in fdisk GPT support in any case; gdisk does a *vastly* better job,
> and appears to be mature. At the least however, there needs urgently to be
> a means by which GPT can be disabled (command-line switch?) or by which
> fdisk can be forced to read an existing MBR under _any_ circumstances.
Seems like a good idea to have a way how to modify protective or hybrid
MBR on GPR devices.
# fdisk -l /dev/sda
Disk /dev/sda: 149.1 GiB, 160041885696 bytes, 312581808 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: gpt
Disk identifier: 3549290F-417C-4941-8503-F7835109B821
Device Start End Size Type
/dev/sda1 2048 2050047 1000M EFI System
/dev/sda2 2050048 6146047 2G Microsoft basic data
/dev/sda3 6146048 26462207 9.7G Linux swap
/dev/sda4 26462208 98142207 34.2G Microsoft basic data
/dev/sda5 98142208 230662143 63.2G Microsoft basic data
/dev/sda6 230662144 312580095 39.1G Microsoft basic data
but when GPT is disabled we can access PMBR:
# fdisk -l -t dos /dev/sda
Disk /dev/sda: 149.1 GiB, 160041885696 bytes, 312581808 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0x00000000
Device Boot Start End Blocks Id System
/dev/sda1 1 312581807 156290903+ ee GPT
> On a related note, fdisk cannot differentiate between lower and upper-case
> command input (e.g., `G' vs. `g' is rather pointless as things stand).
This is already fixed in git tree.
.. all will be in v2.24-rc2. Thanks.
Karel
--
Karel Zak <kzak@redhat.com>
http://karelzak.blogspot.com
next prev parent reply other threads:[~2013-10-09 14:16 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-10-09 11:23 ***Urgent***! Fdisk: GPT support utterly breaks hybrid MBR; *must* have disable option! :( Craig
2013-10-09 14:16 ` Karel Zak [this message]
2013-10-10 0:39 ` Craig
2013-10-10 11:10 ` Karel Zak
2013-10-11 3:45 ` Craig
2013-10-11 9:04 ` Karel Zak
2013-10-11 21:34 ` Craig
2013-11-24 18:18 ` H. Peter Anvin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20131009141628.GB940@x2.net.home \
--to=kzak@redhat.com \
--cc=util-linux@vger.kernel.org \
--cc=util-linux_contact@magister.com.au \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox