Menu

Help on getting a dual boot to work

2016-11-30
2016-12-04
  • Brett Benson

    Brett Benson - 2016-11-30

    ) am having trouble getting a Linux install to boot on a dual boot system with Windows 10 Enterprise.

    Details:

    I am attempting to create a dual boot installation of Windows 10 Enterprise with Ubuntu 14.04. The Ubuntu installation in question exists on several laptops, that have been slightly modified by a vendor of some proprietary software (used to perform audio/video recordings) to automatically launch their software in a window manager (though you can access a terminal from the software's help menu). While the vendor is fine with the creation of a dual boot system on the laptops they provide us, they do not have installation disks for their modded distro (they install it over a network), so I cannot do a fresh install, I have to move the existing installation over.

    To create the dual boot, I set the laptops into UEFI mode (orginally in BIOS mode), then installed Windows 10 Enterprise on a fresh hard drive (GPT) of an identical make/model/capacity as the existing hard drive. I made a copy of the existing hard drive (MBR) and used GParted to copy/paste the existing Linux partitions to the fresh hard drive. I had to resize one of the partitions (used for recording storage) to fit, but did not touch used space. I then booted into Windows 10 and installed grub2win. After initial configuation, grub2win launches Windows 10 fine, but I cannot get it configured properly to launch the Ubuntu install. The closest I have been able to get is, by doing custom code based on the code sample for Ubuntu, it will display the echo messages normally then just go to a blank screen with no real disk activity afterwords (the automatic methods could not find the kernel)

    The kernel is located in /boot, which also contains a grub config. I have checked the UUID in the /boot grub config and they match the drive in grub2win config for the Linux menu entry.

    Could the the existing grub on the Linux install be interfering with the booting process?

    Config files attached.

     

    Last edit: Brett Benson 2016-11-30
  • Drummer

    Drummer - 2016-11-30

    Hi Brett,

    I just need to understand a few things in order to help you out:

    Does the blue Grub2Win menu appear at boot time (not the Ubuntu grub menu)?

    On the Ubuntu boot partition, are the /vmlinuz and /initrd.img files present and properly linked to the Ubuntu kernel files in the /boot directory?

    I do recommend using partition labels to locate the Ubuntu partition at boot time. This is much more reliable then manually setting the partition number.

    Instructions on setting the labels are in the "Setting your labels" section of Grub2Win help.
    You will then need to run Grub2Win and tell it to search by the partition label you have set.

    I have seen blank screen problems depending on graphics mode.

    Using Grub2Win, edit the Ubuntu menu entry. Try removing the "nomodeset" Linux Boot Parm. If that doesn't work, try changing the "OS Graphics" for the Ubuntu menu entry from "auto" to an explicit value like 1024x768.

    Ubuntu is quite sensitive to these settings on some graphics cards. You many have to play around with graphics parameters until you find the one that works.

    Please send me your C:\grub2\update.log file for further analysis. Also the model of your graphics card or motherboard if the graphics are integrated.

    Hope this helps,

    Dave

     

    Last edit: Drummer 2016-11-30
    • Brett Benson

      Brett Benson - 2016-12-01

      Dave,

      Thanks for the quick response!

      Question: Does the blue Grub2Win menu appear at boot time (not the Ubuntu grub menu)?

      Answer: Yes, the Grub2Win menu appears at boot time and looks as expected from the configs I chose setting it up.

      Question: On the Ubuntu boot partition, are the /vmlinuz and /initrd.img files present and properly linked to the Ubuntu kernel files in the /boot directory?

      Answer: Yes, /vmlinuz and /initrd.img are present as files in the /boot partition, and there are symlinks to both of them in the / partition. In the attachments, files 2 and 3 show this. There may be some hidden issue with the symlinks but at least they are visibly present where they are supposed to be.

      I initially tried a partition label for the boot partition, but it could not find the kernel. I may try it again if I can get the current problem sorted.

      So, thanks to you, some progress has been made.

      Removing nomodeset by itself resulted in no change, but leaving it off and changing the OS Graphics setting to 1024x768 produced the output you see in file 1. From some googling around I found this http://askubuntu.com/questions/137655/boot-drops-to-a-initramfs-prompts-busybox which I am going to try as a solution to this problem. I will update you on the progress, does not seem to be a grub2win issue, though.

      The hardware is the exact same laptop (Dell Latitude E6440) that the install was originally on.

      Update.log attached.

       

      Last edit: Brett Benson 2016-12-01
  • Drummer

    Drummer - 2016-12-01

    Hi Brett,

    I think I have your answer.

    The confusion arises from your having separate /boot and root (/) partitions. I usually install Linux to a single partition as I find it clearer and less prone to problems with symbolic links etc. However, this is a matter of personal preference and I digress. If you are careful, you can use separate partitions as follows:

    You need to have grub loading everything from the root partition, in your case partition 7. The grub linux and initrd commands should point to the /vmlinuz and /initrd.img links in the root partition. This avoids the need to change them every time a new kernel is created, as the links are automatically updated by the Ubuntu maintenance program to point to the proper kernel files.

    I have attached a sample of the Ubuntu grub entries as they should appear in your C:\grub2\grub.cfg file.

    Note that if you use partition labels, they should always point to the root partition (number 7).

    Please let me know how this works for you,

    Dave

     

    Last edit: Drummer 2016-12-01
  • Brett Benson

    Brett Benson - 2016-12-01

    Dave,

    Just a quick reply with what I implemented so far based on your last answer.

    Using the first code sample you provided (Ubuntu - using symbolic links), it fails to boot with the following error in Grub2win:

    error: file `/vmlinuz' not found.
    unalingned pointer 0xbba91628
    Aborted. Press any key to exit
    

    I then set the partion label on the partition to your example (ubuntu-14.04), and tried a new entry with searching for the partition label set to the same and the os graphics to 1024x768 in the drop down, applied/ok'd out. Here is the output of grub2win when attempting to boot into the install:

    error: file `/vmlinuz' not found.
    alloc magic is broken at 0xbb8990e0: 0
    Aborted. Press any key to exit.
    

    I then deleted that entry, created a custom code entry for Ubuntu, and cut and pasted your example code for the partition label entry. Received the following error in grub2win when trying to boot into the install:

    Grub is setting root to hdo,gpt7  The boot partition label is ubuntu-14.04
    
    error: file `/vmlinuz' not found.
    alloc magic is broken at 0xbb8990e0: 0
    Aborted. Press any key to exit.
    
     

    Last edit: Brett Benson 2016-12-01
  • Drummer

    Drummer - 2016-12-01

    Hi Brett,

    I've attached the Ubuntu menu entry.

    Long term, you may want to consider merging the /boot code to the main partition to simplify things.

    I can send you the steps to merge the code if you are interested.

    Please let me know how you make out.

    Dave

     
    • Brett Benson

      Brett Benson - 2016-12-01

      Dave,

      That last code example worked perfectly!!!!! Thank you very much!!!

      Please send me the steps to merge the code, I will experiment with that once I get this deployed.

       
  • Drummer

    Drummer - 2016-12-01

    Hi Brett,

    Thanks for everything!

    Here are the steps to merge the /boot partition.

    Dave

     
    • Ed  P

      Ed P - 2016-12-02

      Dave, Brett,

      If partition 5 is deleted won't partition 7 become partition 6?

      Ed

       
  • Drummer

    Drummer - 2016-12-04

    Hi Ed (and Brett),

    Depends on how the partitions are stacked on the drive. This is the reason I recommend using partition labels instead of hard partition numbers. Grub will reliably find a partition by it's label. Yes UUID's will work as well, but meaningful labels are so much more human friendly.

    Dave

     

Log in to post a comment.