Results 1 to 3 of 3

Thread: dualbooting 2 ubuntu servers (encrypted lvm)

  1. #1
    Join Date
    Oct 2008
    Almere, The Netherlands
    Ubuntu 9.04 Jaunty Jackalope

    dualbooting 2 ubuntu servers (encrypted lvm)

    Okay, so I want to dualboot 2 ubuntu servers 13.10 on a single hdd. I have created 4 primary partitions (2x boot, non-encrypted) and two encrypted LVM in which the home, root & swap logical volumes are contained. Basically this is the setup:

    - sda1: boot partition server 1
    - sda2: encrypted LVM server 1 (root, home & swap)
    - sda3: boot partition server 2
    - sda4: encrypted LVM server 2 (root, home & swap)

    Installation of server 1 went just fine. I could boot into the server. After the installation of server 2 (I chose to install GRUB in sda3), the system still booted in in server 1 (sda1 & 2). So I did an update-grub, but still it just found the images of server1 and not the ones on sda3. So after a lot of searching I found this page, which is pretty much the same problem I have. So I tried the solution that was given there (boot-repair), but unfortunately it did not solve my problem. It did however made a very detailed summary of my current setup:

    It looks like the grub on sda1 is missing or corrupt. But actually that is the one that works!

    Does anyone have an idea how I can make this work?


    oh, btw: I have also tried to install the GRUB of server 2 on the MBR. That way I could boot into server 2, but not into 1.
    Last edited by PrSdNt; February 4th, 2014 at 08:13 PM.

  2. #2
    Join Date
    Jun 2009
    SW Forida
    Ubuntu 16.04 Xenial Xerus

    Re: dualbooting 2 ubuntu servers (encrypted lvm)

    I do not know LVM and encryption.

    But have you tried just copying the entire boot stanza of the first entry of second install into 40_custom of first install and see if that boots? Not sure when you get asked for passphrase.

    gksudo gedit /etc/grub.d/40_custom

    sudo update-grub

    Then grub menu in first root should have entry for second root.

     menuentry 'Ubuntu' --class ubuntu --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-simple-2de282af-752e-46f5-8bd8-40b9b7fc2988' {
    gfxmode $linux_gfx_mode
    insmod gzio
    insmod part_msdos
    insmod ext2
    set root='hd0,msdos3'
    if [ x$feature_platform_search_hint = xy ]; then
      search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos3 --hint-efi=hd0,msdos3 --hint-baremetal=ahci0,msdos3  a5275030-553d-434a-bf4f-1c42c05e35c8
      search --no-floppy --fs-uuid --set=root a5275030-553d-434a-bf4f-1c42c05e35c8
    linux	/vmlinuz-3.11.0-12-generic root=/dev/mapper/vg02-root ro   
    initrd	/initrd.img-3.11.0-12-generic
    For more info on UEFI boot install & repair - Regularly Updated :
    Please use Thread Tools above first post to change to [Solved] when/if answered completely.

  3. #3
    Join Date
    Oct 2008
    Almere, The Netherlands
    Ubuntu 9.04 Jaunty Jackalope

    Re: dualbooting 2 ubuntu servers (encrypted lvm)

    I should have thought of that myself. It works perfectly! Thanks very much for the help.


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts