After openSUSE installed for double OS, Win 7 loader is gone.

There are two HDDs in my laptop. I have already installed Win 7 x86_64 on one HDD and now I try to both install OpenSUSE 13.2 on another HDD.

My laptop support UEFI and when I installed OpenSUSE 13.2 with U Disk (DVD iso), it automatically makes four partitions seperately mounted to /boot, swap, / and /home. After OpenSUSE is installed and reboot I can’t find my Windows 7 bootloader. My Win 7 is booted in BIOS mode not UEFI.

Then I found a problem, if I want to use Windows 7, I should turn off the UEFI supporting in BIOS. Then if I want to use OpenSUSE, I should turn on the UEFI supporting.

When I want to reinstall OpenSUSE with UEFI shut down but I even can’t boot from U Disk this time. It’s awful to modify BIOS every time I log in. So how can I solve this problem. My disk info viewed by Windows 7 is as follows (I translate Chinese in the fig to English).

http://e.picphotos.baidu.com/album/s%3D1100%3Bq%3D90/sign=d7def4f428dda3cc0fe4bc2131d90270/f636afc379310a552ff1b39fb14543a983261087.jpg

Thanks in advance!

You can switch opensuse to legacy MBR booting without actually having to reinstall.

Run Yast → System → Boot Loader

and change the boot loader from “grub2-efi” to “grub2”.

Unfortunately, there’s complication. However, you will have the same complication if you reinstall or if you convert as suggested. The problem is that you have two disks. So how do you want the computer to boot?

One way is to tell the BIOS to boot the opensuse disk. But there you are making BIOS changes for every boot (unless maybe F12 during boot allows just a boot selection).

Another possibility is to set grub2 to boot from the MBR of the Windows disk. This puts some boot code in that MBR but doesn’t otherwise change anything on the Windows disk. It is probably the easier choice to use.

If you want more details, then provide us the output from:

# fdisk -l

Put that output in code block for easier reading.

Thanks a lot. The details are as follows.

Disk /dev/sda: 111.8 GiB, 120034123776 bytes, 234441648 sectorsUnits: 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: 0x0ad19cc0


Device     Boot     Start       End   Sectors  Size Id Type
/dev/sda1  *         2048 125833215 125831168   60G  7 HPFS/NTFS/exFAT
/dev/sda2       125833216 234440703 108607488 51.8G  f W95 Ext'd (LBA)
/dev/sda5       125835264 234440703 108605440 51.8G  7 HPFS/NTFS/exFAT


Disk /dev/sdb: 298.1 GiB, 320072933376 bytes, 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
Disklabel type: gpt
Disk identifier: AC5EB979-8DDD-4D7F-BB89-06F80FA67990


Device         Start       End   Sectors  Size Type
/dev/sdb1       2048    321535    319488  156M EFI System
/dev/sdb2     321536   4530175   4208640    2G Microsoft basic data
/dev/sdb3    4530176 214243327 209713152  100G Microsoft basic data
/dev/sdb4  214243328 625141759 410898432  196G Microsoft basic data

Did you say had install openSUSE?
Because there is no indication of that

I notice sdb is a GPT
And sda is DOS

If Windows was installed in EFI mode it would have to have GPT (IIRC)
And if it was then (IIRC) openSUSE would need to be too

I have already installed openSUSE, you can see item “/sdb”, that is where I installed openSUSE.

Thank you!

Thanks for the listing.

My read on them is a little different from that of caf4926,

Windows is on “/dev/sda”. Probably “/dev/sdb2” is swap, and maybe “/dev/sdb3” is the root partition and “/dev/sdb4” is “/home”. But I’m guessing.

What makes it a bit confusing is that those partitions are listed as “Microsoft Basic Data”. But I think that’s what “parted” does, at least for the version of “parted” used by the opensuse 13.2 installer.

I definitely recommend booting from the MBR of the first disk.

I’m doing a dry run here to see the details.

Start Yast, select “System” → “Boot Loader”

It will list the Boot loader as “grub2-efi”. Change that to “grub2”

At that point, the screen will change content.

Next click on the box “Boot Loader Installation Details”

That will list the order of the disks. Make sure that it has “/dev/sda” first and “/dev/sdb” second. There are “move up” and “move down” buttons to change the order. Having “/dev/sda” first is needed for booting from the MBR of that Windows disk.

When you have that set in the right order, click “OK”. That gets you back to the previous screen.

Now make sure that “Boot from Master Boot Record” is checked, and other boxes are unchecked in that section (labeled “Boot loader location”)

If desired, you can go into “Bootloader Options” and set the timeout. Also make sure that the box “Probe foreign OS” is checked.

The Yast defaults should be okay for everything else. Click “OK” to save the changes. Or click “Cancel” to abort.

Now you will have to reboot into BIOS settings, and set the computer to use legacy booting (or CSM booting). It should still boot into opensuse, but there should now be a menu item to boot Windows.

If you don’t switch to legacy booting (i.e. if you leave it at efi booting), there might still be a menu item for Windows but it probably won’t work because that menu item depends on legacy booting.

Thanks for your instructions! But I got a problem again because after I processsed as you told, I cannot log into both OS. Before I doing as your instructions, I can log into Win7 with legacy booting, but now I can see only opensuse loader with no win7 item. The worse is when I try to log into opensuse, error comes as follows.

can't find command `linuxefi'.
can't find command `initrdefi'.

So I reboot depends on efi-booting, this time I could log into openSUSE but still with no Win7 item.

I’m sorry to bother you again because I have only one laptop and it took me long time to get another access to the Internet.

Thanks in advance!

Well mixing boot modes makes a mess and untangling can get complicated. Chances are you will never get it right trying to patch stuff because GPT and DOS partitioning is different and stores different info at different places and if you have both it can confuse things. Also with different modes you can not chain from one OS in one mode to another in a different mode thus you have to use the BIOS to chose which to boot

I suggest you backup any important data and wipe both drives and start again this time using the same mode for each OS. Does not matter which mode but they must both be the same.

Oops. That’s a bug in my opinion. When you switched to grub2, the “efi” part should not have been put there.

Boot from rescue media and mount whichever partition has “/boot”.

Then edit “/boot/grub2/grub.cfg” and change “linuxefi” to “linux” and “initrdefi” to “initrd”.

That’s a temporary fix that should allow booting, at least to opensuse.

Once you are booted into opensuse, edit “/etc/default/grub” and find the line “GRUB_USE_LINUXEFI=true”. Change that to “false” – or I think commenting out the line also works.

After that, future updates to grub.cfg should not have the problem. You can update with

# grub2-mkconfig -o /boot/grub2/grub.cfg

and then check.

Thank you for your help. When I set bootloader when using YaST2

In Boot Code Options Tab, there is an item called Protective MBR flag, which one should I choose?

I successfully log into openSUSE in legacy booting mode according to your instructions. But I still can’t see Windows 7 loader.

I usually uncheck that, but I don’t think it matters – particularly since this is your second drive (“/dev/sdb”).

So running “grub2-mkconfig” as suggested did not add an entry?

Then I guess we need a grub2 expert to help us out here.

If all else fails, it should now be possible to manually add a chainload entry to boot Windows. But I’ll wait a bit to see if someone with more expertise on grub2 can offer help.

I’m truly grateful for your help. And before new solution coming up, I will learn something on myself.

Is the probe for foreign OS box checked in yast (note I think it is on the third tab). If not check it then accept that should be enough to add Windows to the menu