Page 1 of 1

No GRUB in dual-boot Win7 Mga2

PostPosted: Apr 30th, '13, 14:55
by Max
I successfully installed Mga2 onto an Asus X401A.
During installation I selected to use the graphical boot menu, and I added the Windows 7 boot option.
However, when booting up it always goes straight to Windows.
I tried having Windows as the default, I tried having Linux as the default. No matter what, it skips GRUB and goes straight to Windows on boot.
How do I fix this?

Re: No GRUB in dual-boot Win7 Mga2

PostPosted: Apr 30th, '13, 20:33
by gohlip
Need clarification...

o installed grub-legacy or grub2?
o "I tried having Windows as the default, I tried having Linux as the default. No matter what, it skips GRUB and goes straight to Windows on boot."
If it goes straight to windows, how did you try to set any default when Mageia is not booting? Please explain.
Do you get any grub menu at all? (any version grub menu will make things much easier) - not even a grub prompt?


If it is possible, get output of "fdisk -lu" and "blkid" ( you can also boot up livecd to find this).

Re: No GRUB in dual-boot Win7 Mga2

PostPosted: Apr 30th, '13, 20:59
by Max
gohlip wrote:Need clarification...

o installed grub-legacy or grub2?

grub-legacy
gohlip wrote:o "I tried having Windows as the default, I tried having Linux as the default. No matter what, it skips GRUB and goes straight to Windows on boot."
If it goes straight to windows, how did you try to set any default when Mageia is not booting? Please explain.

I installed Mageia, added Windows to the menu and set it as default.
Didn't work.
Booted from Live USB, installed again (on the same / partition), added Windows to the boot menu, but set Linux as the default.
Didn't work.
gohlip wrote: Do you get any grub menu at all? (any version grub menu will make things much easier) - not even a grub prompt?

Nothing at all, not even grub prompt. Just the Asus splash screen, a blank screen for a few seconds, then the Windows splash screen.

gohlip wrote:If it is possible, get output of "fdisk -lu" and "blkid" ( you can also boot up livecd to find this).

Code: Select all
[root@localhost live]# fdisk -lu

WARNING: GPT (GUID Partition Table) detected on '/dev/sda'! The util fdisk doesn't support GPT. Use GNU Parted.


Disk /dev/sda: 320.1 GB, 320072933376 bytes
255 heads, 63 sectors/track, 38913 cylinders, total 625142448 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
Disk identifier: 0x830463eb

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1               1   625142447   312571223+  ee  GPT

Disk /dev/sdb: 8000 MB, 8000110592 bytes
64 heads, 32 sectors/track, 7629 cylinders, total 15625216 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
Disk identifier: 0x228d5a78

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1   *           1     1345535      672767+  17  Hidden HPFS/NTFS
[root@localhost live]# blkid
/dev/loop0: TYPE="squashfs"
/dev/sda2: LABEL="SYSTEM" UUID="CCF4-FD64" TYPE="vfat"
/dev/sda3: LABEL="OS" UUID="B4FE0A0CFE09C796" TYPE="ntfs"
/dev/sda4: LABEL="Recovery" UUID="72F41CFCF41CC3EF" TYPE="ntfs"
/dev/sda5: UUID="5f59b90f-f0e7-442f-a136-06ca2d1390d2" TYPE="ext4"
/dev/sda6: UUID="96f45137-c38c-4f95-9985-3defdbc08d45" TYPE="swap"
/dev/sda7: UUID="724ac76c-b02d-45c3-ac72-005fcb64b8ee" TYPE="ext4"
[root@localhost live]#

Re: No GRUB in dual-boot Win7 Mga2

PostPosted: Apr 30th, '13, 21:44
by martinw
Looks like your machine has been set up to boot Windows using UEFI boot mode. In the BIOS setup, can you find an option to enable "legacy boot"? This should let you get to the GRUB menu. However, you won't then be able to boot into WIndows from GRUB. Two options:
  • Reinstall Windows using legacy boot mode (you'll probably need a Windows setup disk to do this).
  • Boot Mageia using an EFI boot manager.
As I have a Windows 8 machine, the first option was not available. I described how I achieved the second option here, and have subsequently repeated the process for Mageia-2. Note that if you have just installed Mageia-2, you will need to update the kernel first, as the original 3.3.8 kernel did not have EFI boot support enabled.

Browse the rest of that thread for other suggestions.

Re: No GRUB in dual-boot Win7 Mga2

PostPosted: Apr 30th, '13, 21:57
by Max
Thanks.
But I don't have a Windows install disc, just the recovery partition on the laptop, so I guess I'll have to use the second option too.

Re: No GRUB in dual-boot Win7 Mga2

PostPosted: May 1st, '13, 02:45
by gohlip
Unless grub2 has been upgraded in Mga2, recommend you try out Mga3 (beta4 or RC). The grub2 there will make installation much easier for UEFI/GPT.
And don't forget to disable 'secure boot' (aka restricted boot) in BIOS. But first disable secure boot and see if your Windows 8 boot up before you install Mageia. If it don't boot up, you may have to reinstall Windows 8 with secure boot disabled before proceeding with linux installation.
Good luck.

Re: No GRUB in dual-boot Win7 Mga2

PostPosted: May 1st, '13, 09:01
by Max
It's Windows 7....

Re: No GRUB in dual-boot Win7 Mga2

PostPosted: May 1st, '13, 09:25
by gohlip
Max wrote:It's Windows 7....

okay. but still same. best to use uefi/gpt with latest grub2 from m3rc, secure boot disabled.

can't see why anyone would use boot-legacy when there's uefi
then again, can't see why anyone would use grub.....nevermind. your choice, good luck

Re: No GRUB in dual-boot Win7 Mga2

PostPosted: May 1st, '13, 09:37
by Max
gohlip wrote:
then again, can't see why anyone would use grub.....nevermind. your choice, good luck


It works. It's been proven to work and has worked for many years.
If it ain't broke don't fix it.
Of course, Microsoft went and broke it so... :shrugs:

Re: No GRUB in dual-boot Win7 Mga2

PostPosted: May 3rd, '13, 04:26
by delduin
Try holding the shift key right after BIOS POST- this may bring up grub boot list.

Re: No GRUB in dual-boot Win7 Mga2

PostPosted: May 30th, '13, 13:17
by Max
Will installing Mga3 fix this issue? Does it matter which install medium is used?

Re: No GRUB in dual-boot Win7 Mga2

PostPosted: Jun 2nd, '13, 10:50
by doktor5000
There is no support for UEFI boot by default, you have to add that yourself. But there's some support for grub2 in the installer. You may have to try it, but be careful.
You may want to look at https://wiki.mageia.org/en/UEFI_booting

Re: No GRUB in dual-boot Win7 Mga2

PostPosted: Jun 5th, '13, 13:29
by Max
I was in contact with the Asus support people, since my BIOS does not have the option to disable secure boot.
Apparently this is because there is no secure boot for Win 7 computers.
Therefore the problem must be in the Mageia installation.
Now I know that Win 7 cheats the MBR. It has a boot partition of ~300 MB that is the boot. In other computers that I've installed this isn't a problem. But in this case, the BIOS won't let me point to a physical drive for boot, but to a boot partition, namely the Win 7 boot partition.
So, how do I fix it so that the Mageia boot partition (Mga2 or Mga3, GRUB or GRUB2) shows up in the BIOS and I can boot to it?

Re: No GRUB in dual-boot Win7 Mga2

PostPosted: Jun 5th, '13, 21:08
by doktor5000
So it seems you're using (U)EFI. AFAIK only grub2-efi supports this.

You may want to look at viewtopic.php?p=30892#p30892
or https://wiki.archlinux.org/index.php/Gummiboot

For grub2-efi, look at the documentation/readme that is included in the package.

Re: No GRUB in dual-boot Win7 Mga2

PostPosted: Jun 10th, '13, 10:08
by Max
If I instal grub2-efi on a live DVD, and then install to disk, will that work? That seems like the simplest answer...

Re: No GRUB in dual-boot Win7 Mga2

PostPosted: Jun 10th, '13, 21:22
by doktor5000
Nope, you would be installing it into the overlay filesystem which resides in memory.

Re: No GRUB in dual-boot Win7 Mga2

PostPosted: Jun 10th, '13, 21:28
by Max
Then how can I install grub2-efi? Can it be done during the installation?

Re: No GRUB in dual-boot Win7 Mga2

PostPosted: Jun 10th, '13, 21:40
by doktor5000
It's on the DVDs. For the other media it should be able to install it from online repos during installation, if they don't contain it.

You may also want to check https://wiki.mageia.org/en/Mageia_3_Errata#Grub2

Also the following from release notes:

Grub2 can now be installed at the summary step, it can also be installed in a partition. However, please see the errata for information on how to multi-boot into the system. Integration in drakboot is only partial, if you feel that you need to customize the menu then please read /usr/share/doc/grub2/README.Mageia for the native grub2 techniques, or you could maybe try grub-customizer.