Windows Update changes MBR table to GPT - Linux no longer boots properly
Linux - Laptop and NetbookHaving a problem installing or configuring Linux on your laptop? Need help running Linux on your netbook? This forum is for you. This forum is for any topics relating to Linux and either traditional laptops or netbooks (such as the Asus EEE PC, Everex CloudBook or MSI Wind).
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Windows Update changes MBR table to GPT - Linux no longer boots properly
I've just encountered the weirdest problem and so far, internet searches don't help ... so: (apologies for the saga ... I think it helps though)
I recently purchased a LENOVO Thinkpad Edge E540 for my daughter. As a linux-only family I really wanted to nuke the windows partition, but my husband had one piece of software that was not running properly under wine or linux ...
SO,
* I shrunk the windows partition
* installed MAGEIA on the remaining space
These were both successful, and the only drawback was that if you needed to boot to WINDOWS you had to go into the BIOS and set it back to boot in both UEFI and LEGACY mode. Inconvenient, but it solved the minor need to access windows.
Then, after the last boot into windows (my husband needed to access his propriety software) windows decided to do some kind of update. We cared less about the update, and so I said just *hit the power button and reboot into the bios* (yes not the most sensible thing ... but hey, we didn't care about the windows side much). After a couple of tries, (weird! but my husband was driving the keyboard) we get into the BIOS and change back to LEGACY boot only.
REBOOT time ... and the system gets stuck.
It was really odd - I couldn't see anything immediately wrong (log in as root, look at system logs etc.) and then something twigged me to look at the partition table. IT HAD BEEN CHANGED TO A GPT !!!!! All the linux partitions were labelled as microsoft basic data partition types. WHAT THE #¤%#&¤!!!!
Has anyone seen this kind of sneaky update before?
Does anyone have a (non destructive) way of restoring the MBR table? (Fortunately my daughter has very little data on it, and in rescue mode I can still see all the files etc.)
On principal, I do not like being dictated by the OS on how I set up my system, esp. the way it was done here. However, if the best option really is to convert it properly to a GPT : how should I go about doing this?
Anyway, all comments and opinions as well as help are greatly appreciated.
Sounds very suss to me. Are we to presume this is Win8(.1) and it still boots ok ?.
For Linux to boot gpt on BIOS, the bootloader will need to be re-installed into a special BIOS boot partition. And of course the partition type for Linux partition(s) would need to change.
All of this, and the conversion back to MBR can be done by gdisk. Use at your peril - gdisk will work, but may not retain (all) your data, or worse may do what you ask, not necessarily what you thought you asked for.
Sounds very suss to me. Are we to presume this is Win8(.1) and it still boots ok ?.
For Linux to boot gpt on BIOS, the bootloader will need to be re-installed into a special BIOS boot partition. And of course the partition type for Linux partition(s) would need to change.
All of this, and the conversion back to MBR can be done by gdisk. Use at your peril - gdisk will work, but may not retain (all) your data, or worse may do what you ask, not necessarily what you thought you asked for.
Note my sigline.
Thanks!
I haven't tried booting Windows again (and yes, it's Win8(.1)). I'll give that a go and see what happens. When you say "suss"
do you mean the partition table being changed? I've never come across anything like it before. I asked my colleagues (I work
in HPC), and they've not encountered it either.
Up to now, what I found on the net said exactly what you mentioned ... you can restore MBR but it will probably not work
quite right. There are a few guidelines for installing linux under GPT and so far it sounds like my best bet is to reinstall.
If your windows 8 was pre-installed on the computer, it was likely installed using UEFI/GPT and you would need to install Mageia using UEFI/GPT or you will get...well, you've experiened what happens. If you are using the Legacy BIOS, you need a very small BIOS Boot partition to use GPT. If you are using UEFI, you should have a FAT32 partition near the beginning of the drive, 200-500MB in size which should contain both the windows and Linux efi files.
You should not have to make changes in the BIOS to boot either.
It might be that not doing a proper shutdown of windows is part of the problem. Windows 8 usually doesn't shut down but hibernates which causes problems also.
Distribution: Primarily Deb/Ubuntu, and some CentOS
Posts: 829
Rep:
Hi,
Have you considered a Windows virtual machine? This way your main OS is Linux and whenever you need windows, just fire up the VM without having to go through all that trouble.
The Arch wiki has great instructions on how to install GRUB on a UEFI system: https://wiki.archlinux.org/index.php/GRUB
It seems that GRUB can't detect other OSes in UEFI mode, so you have to manually add Windows to the boot menu. The link above has step-by step instructions on how to do that.
Note: I have a UEFI laptop, and mine always hangs for about 2 seconds before it will let me do any selections. I don't know if it's just my laptop, or UEFI in general, but if it happens to you it shouldn't be a problem.
Distribution: Primarily Deb/Ubuntu, and some CentOS
Posts: 829
Rep:
verayh,
You do not need a separate disk for a Virtual Machine, though you can put the virtual machine on a seperate disk if you wanted to. It uses space you allocate to the VM. I personally dislike dualbooting, but thats just me.
In case you want to try going this way instead, here is the link to downloading Virtual Box. I use it for my Windows 7 Pro VM and a few other Linux distros. Works great, way better than dual-booting if you ask me.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.