[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

RE: changing from BIOS to GPT



(sending again through hotmail's web interface -- apologies for
anything my MUA may do to the content)

> Date: Sun, 7 Jun 2015 14:23:40 -0500
> From: deblis@lionunicorn.co.uk
>
> Quoting Gary Dale:
>> Arno Schuring said:
>>> "reconfigure grub" in this case meant uninstalling grub-pc and
>>> installing grub-efi, right?
>> No actually. I never uninstalled grub-pc. The machine seemed to have
>> grub-efi-amd64 all along. What I meant was the more mundane
>> update-grub sequence. Also, I've been using EF02 as the gpt partition
>> type for the efi partition. So far I've never had a problem with that.
>
> I don't think that matters. I have read that converting a disk from
> MBR to GPT, quite simply, breaks grub, whichever version. So it needs to
> be reinstalled.

It does, but what it breaks is the installed bootloader, not the grub
installation. So "it needs to be reinstalled" is correct, but "aptitude
reinstall grub-pc" is the wrong solution. You should be running
update-grub and grub-install, using the package manager will not solve
the issue (except for the fact that both update-grub and grub-install
/may/ be triggered as part of the package installation).

On top of that, grub installs its stage2 bootloader in the unclaimed
space between the MBR and the first partition. That space is not unused
in the GPT disk format, so when you simply convert your existing
partitions, grub will have no place to install its stage2 and
grub-install will error out. To have grub-pc boot from a GPT disk, you
need to have a Bios Boot Partition (gdisk partition type ef02) of at
least 128kB.

Luckily, most partition tools start their first partition at the 1MB
boundary, so you can usually create that bios boot partition between
sectors 40 and 2048, but that's not a given.

Note that the above applies if simply switching from dos-style to
gpt-style partitioning. It doesn't apply when switching from legacy
boot to efi boot.


Regards,
Arno

 		 	   		  

Reply to: