Results 1 to 8 of 8

Thread: Need some help triple booting

  1. #1
    Join Date
    Mar 2011
    Location
    Norway
    Posts
    77

    Default Need some help triple booting

    Hi everyone

    I'm trying to set up a triple boot between openSUSE 12.2, Archlinux and Windows 7, but can't seem to make grub2 list my Arch install. Not too familiar with grub2 just yet.
    Code:
    # os-prober
       No volume groups found
     /dev/sdb4::Arch:linux 
     /dev/sdc1:Windows 7 (loader):Windows:chain
    Code:
    # grub2-mkconfig -o /boot/grub2/grub.cfg
     Generating grub.cfg ... 
     Found theme: /boot/grub2/themes/openSUSE/theme.txt 
     Found linux image: /boot/vmlinuz-3.4.6-2.10-desktop 
     Found initrd image: /boot/initrd-3.4.6-2.10-desktop 
       No volume groups found 
     Found Arch on /dev/sdb4 
     Found Windows 7 (loader) on /dev/sdc1 
     done
    So I have this set up on three disks. /dev/sdc is all used for Windows 7, so no need to worry 'bout that one.
    The other two are a 40 GB SSD with this partition table:
    Code:
    fdisk -l /dev/sdb
    
     Disk /dev/sdb: 40.0 GB, 40018599936 bytes 
     255 heads, 63 sectors/track, 4865 cylinders, total 78161328 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: 0x000432b9 
      
        Device Boot      Start         End      Blocks   Id  System 
    
     /dev/sdb1   *        2048     1026047      512000   83  Linux    # boot partition for openSUSE 12.2
     /dev/sdb2         1026048    42969087    20971520   83  Linux     # root partition opensuse 12.2
     /dev/sdb3        42969088    43993087      512000   83  Linux     # boot partiton for Arch
     /dev/sdb4        43993088    78161327    17084120   83  Linux     # root partition for Arch
    And a 1TB SATA disk with this partition table:
    Code:
    fdisk -l /dev/sda
    
     Disk /dev/sda: 1000.2 GB, 1000204886016 bytes 
     255 heads, 63 sectors/track, 121601 cylinders, total 1953525168 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: 0x000835f9 
      
        Device Boot      Start         End      Blocks   Id  System 
    /dev/sda1            2048     4196351     2097152   82  Linux swap / Solaris     # swap to be used by both
    /dev/sda2         4196352    25167871    10485760   83  Linux                 # /var openSUSE 12.2
    /dev/sda3        25167872    46139391    10485760   83  Linux                 # shared /tmp openSUSE 12.2 + Arch
    /dev/sda4        46139392  1953525167   953692888    5  Extended 
    /dev/sda5        46141440    67112959    10485760   83  Linux                 # /var Archlinux
    /dev/sda6        67115008  1953525167   943205080   83  Linux                 # shared /home openSUSE 12.2 + Arch
    Grub2 is written to MBR on /dev/sdb, and is set as primary boot device in BIOS. Why doesn't Grub2 make an Archlinux entry, when it seems as if it sees it when issuing the command 'os-prober'?

    Help and advice would be greatly appreciated. Thanks for your time

    Regards,

  2. #2
    Join Date
    Mar 2010
    Location
    Austin - Texas
    Posts
    10,140
    Blog Entries
    48

    Default Re: Need some help triple booting

    You would think it would be found, but because it uses a separate /boot and /var partition and does not share /boot with openSUSE 12.2, perhaps that is why it fails? If we had a copy of your grub.cfg file posted inside of code # tags using the advanced text editor, we might be able to formulate a chain load entry that would work for you. You can find several tools to deal with grub 2 in this bash script:

    GNU Grub2 Command Help/Config Editor - Version: 1.75 - Blogs - openSUSE Forums

    Thank You,
    My Blog: https://forums.opensuse.org/blogs/jdmcdaniel3/

    Software efficiency halves every 18 months, thus compensating for Moore's Law

    Its James again from Austin, Texas

  3. #3
    Join Date
    Mar 2011
    Location
    Norway
    Posts
    77

    Default Re: Need some help triple booting

    Thanks for your reply, jdmcdaniel3

    This is the current content of '/boot/grub2/grub.cfg':
    Code:
    #
    # DO NOT EDIT THIS FILE
    #
    # It is automatically generated by grub2-mkconfig using templates
    # from /etc/grub.d and settings from /etc/default/grub
    #
    
    ### BEGIN /etc/grub.d/00_header ###
    if [ -s $prefix/grubenv ]; then
      load_env
    fi
    set default="${saved_entry}"
    
    if [ x"${feature_menuentry_id}" = xy ]; then
      menuentry_id_option="--id"
    else
      menuentry_id_option=""
    fi
    
    export menuentry_id_option
    
    if [ "${prev_saved_entry}" ]; then
      set saved_entry="${prev_saved_entry}"
      save_env saved_entry
      set prev_saved_entry=
      save_env prev_saved_entry
      set boot_once=true
    fi
    
    function savedefault {
      if [ -z "${boot_once}" ]; then
        saved_entry="${chosen}"
        save_env saved_entry
      fi
    }
    
    function load_video {
      if [ x$feature_all_video_module = xy ]; then
        insmod all_video
      else
        insmod efi_gop
        insmod efi_uga
        insmod ieee1275_fb
        insmod vbe
        insmod vga
        insmod video_bochs
        insmod video_cirrus
      fi
    }
    
    if [ x$feature_default_font_path = xy ] ; then
       font=unicode
    else
    insmod part_msdos
    insmod ext2
    set root='hd1,msdos2'
    if [ x$feature_platform_search_hint = xy ]; then
      search --no-floppy --fs-uuid --set=root --hint-bios=hd1,msdos2 --hint-efi=hd1,msdos2 --hint-baremetal=ahci1,msdos2 --hint='hd1,msdos2'  e1451502-7bc1-4e01-bb74-e04798b880a7
    else
      search --no-floppy --fs-uuid --set=root e1451502-7bc1-4e01-bb74-e04798b880a7
    fi
        font="/usr/share/grub2/unicode.pf2"
    fi
    
    if loadfont $font ; then
      set gfxmode=1280x1024
      load_video
      insmod gfxterm
      set locale_dir=$prefix/locale
      set lang=POSIX
      insmod gettext
    fi
    terminal_output gfxterm
    insmod part_msdos
    insmod ext2
    set root='hd1,msdos1'
    if [ x$feature_platform_search_hint = xy ]; then
      search --no-floppy --fs-uuid --set=root --hint-bios=hd1,msdos1 --hint-efi=hd1,msdos1 --hint-baremetal=ahci1,msdos1 --hint='hd1,msdos1'  190cd9c4-f81b-47d2-a378-630022fd3b52
    else
      search --no-floppy --fs-uuid --set=root 190cd9c4-f81b-47d2-a378-630022fd3b52
    fi
    insmod gfxmenu
    loadfont ($root)/grub2/themes/openSUSE/DejaVuSans-Bold14.pf2
    loadfont ($root)/grub2/themes/openSUSE/DejaVuSans10.pf2
    loadfont ($root)/grub2/themes/openSUSE/DejaVuSans12.pf2
    loadfont ($root)/grub2/themes/openSUSE/ascii.pf2
    insmod png
    set theme=($root)/grub2/themes/openSUSE/theme.txt
    export theme
    if sleep --interruptible 0 ; then
      set timeout=8
    fi
    ### END /etc/grub.d/00_header ###
    
    ### BEGIN /etc/grub.d/10_linux ###
    menuentry 'openSUSE 12.2' --class opensuse --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-simple-e1451502-7bc1-4e01-bb74-e04798b880a7' {
        load_video
        set gfxpayload=keep
        insmod gzio
        insmod part_msdos
        insmod ext2
        set root='hd1,msdos1'
        if [ x$feature_platform_search_hint = xy ]; then
          search --no-floppy --fs-uuid --set=root --hint-bios=hd1,msdos1 --hint-efi=hd1,msdos1 --hint-baremetal=ahci1,msdos1 --hint='hd1,msdos1'  190cd9c4-f81b-47d2-a378-630022fd3b52
        else
          search --no-floppy --fs-uuid --set=root 190cd9c4-f81b-47d2-a378-630022fd3b52
        fi
        echo    'Loading Linux 3.4.6-2.10-desktop ...'
        linux    /vmlinuz-3.4.6-2.10-desktop root=UUID=e1451502-7bc1-4e01-bb74-e04798b880a7   resume=/dev/disk/by-id/ata-ST31000524AS_6VPBQLYJ-part1 splash=silent quiet showopts
        echo    'Loading initial ramdisk ...'
        initrd    /initrd-3.4.6-2.10-desktop
    }
    submenu 'Advanced options for openSUSE 12.2' $menuentry_id_option 'gnulinux-advanced-e1451502-7bc1-4e01-bb74-e04798b880a7' {
        menuentry 'openSUSE 12.2, with Linux 3.4.6-2.10-desktop' --class opensuse --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-3.4.6-2.10-desktop-advanced-e1451502-7bc1-4e01-bb74-e04798b880a7' {
            load_video
            set gfxpayload=keep
            insmod gzio
            insmod part_msdos
            insmod ext2
            set root='hd1,msdos1'
            if [ x$feature_platform_search_hint = xy ]; then
              search --no-floppy --fs-uuid --set=root --hint-bios=hd1,msdos1 --hint-efi=hd1,msdos1 --hint-baremetal=ahci1,msdos1 --hint='hd1,msdos1'  190cd9c4-f81b-47d2-a378-630022fd3b52
            else
              search --no-floppy --fs-uuid --set=root 190cd9c4-f81b-47d2-a378-630022fd3b52
            fi
            echo    'Loading Linux 3.4.6-2.10-desktop ...'
            linux    /vmlinuz-3.4.6-2.10-desktop root=UUID=e1451502-7bc1-4e01-bb74-e04798b880a7   resume=/dev/disk/by-id/ata-ST31000524AS_6VPBQLYJ-part1 splash=silent quiet showopts
            echo    'Loading initial ramdisk ...'
            initrd    /initrd-3.4.6-2.10-desktop
        }
        menuentry 'openSUSE 12.2, with Linux 3.4.6-2.10-desktop (recovery mode)' --class opensuse --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-3.4.6-2.10-desktop-recovery-e1451502-7bc1-4e01-bb74-e04798b880a7' {
            load_video
            set gfxpayload=keep
            insmod gzio
            insmod part_msdos
            insmod ext2
            set root='hd1,msdos1'
            if [ x$feature_platform_search_hint = xy ]; then
              search --no-floppy --fs-uuid --set=root --hint-bios=hd1,msdos1 --hint-efi=hd1,msdos1 --hint-baremetal=ahci1,msdos1 --hint='hd1,msdos1'  190cd9c4-f81b-47d2-a378-630022fd3b52
            else
              search --no-floppy --fs-uuid --set=root 190cd9c4-f81b-47d2-a378-630022fd3b52
            fi
            echo    'Loading Linux 3.4.6-2.10-desktop ...'
            linux    /vmlinuz-3.4.6-2.10-desktop root=UUID=e1451502-7bc1-4e01-bb74-e04798b880a7  showopts apm=off noresume edd=off powersaved=off nohz=off highres=off processor.max_cstate=1 nomodeset x11failsafe
            echo    'Loading initial ramdisk ...'
            initrd    /initrd-3.4.6-2.10-desktop
        }
    }
    
    ### END /etc/grub.d/10_linux ###
    
    ### BEGIN /etc/grub.d/20_linux_xen ###
    ### END /etc/grub.d/20_linux_xen ###
    
    ### BEGIN /etc/grub.d/20_ppc_terminfo ###
    ### END /etc/grub.d/20_ppc_terminfo ###
    
    ### BEGIN /etc/grub.d/30_os-prober ###
    
    menuentry 'Windows 7 (loader) (on /dev/sdc1)' --class windows --class os $menuentry_id_option 'osprober-chain-AA42B67942B64A39' {
        insmod part_msdos
        insmod ntfs
        set root='hd2,msdos1'
        if [ x$feature_platform_search_hint = xy ]; then
          search --no-floppy --fs-uuid --set=root --hint-bios=hd2,msdos1 --hint-efi=hd2,msdos1 --hint-baremetal=ahci2,msdos1 --hint='hd2,msdos1'  AA42B67942B64A39
        else
          search --no-floppy --fs-uuid --set=root AA42B67942B64A39
        fi
        chainloader +1
    }
    ### END /etc/grub.d/30_os-prober ###
    
    ### BEGIN /etc/grub.d/40_custom ###
    # This file provides an easy way to add custom menu entries.  Simply type the
    # menu entries you want to add after this comment.  Be careful not to change
    # the 'exec tail' line above.
    ### END /etc/grub.d/40_custom ###
    
    ### BEGIN /etc/grub.d/41_custom ###
    if [ -f  ${config_directory}/custom.cfg ]; then
      source ${config_directory}/custom.cfg
    elif [ -z "${config_directory}" -a -f  $prefix/custom.cfg ]; then
      source $prefix/custom.cfg;
    fi
    ### END /etc/grub.d/41_custom ###
    
    ### BEGIN /etc/grub.d/90_persistent ###
    ### END /etc/grub.d/90_persistent ###
    Guess I have rather peculiar partitioning scheme then :-)

    I also do see an error message before the grub screen, but I'm unable to make out what it say - cause it's only there for about 0.3 seconds.

    I'll have a look into that Bash-script as well

  4. #4
    Join Date
    Mar 2011
    Location
    Norway
    Posts
    77

    Default Re: Need some help triple booting

    Probably did something wrong whilst installing Arch. So started over again, with the same partitioning scheme, issued the same commands, and the os-prober recognized the Arch install. Everything is hunky dory again.

    Cheers

  5. #5
    Join Date
    Mar 2010
    Location
    Austin - Texas
    Posts
    10,140
    Blog Entries
    48

    Smile Re: Need some help triple booting

    Quote Originally Posted by back_space View Post
    Probably did something wrong whilst installing Arch. So started over again, with the same partitioning scheme, issued the same commands, and the os-prober recognized the Arch install. Everything is hunky dory again.

    Cheers
    Well I love it when a plan comes together and the user, i.e.You, fixes their own system without further help from me. That being said, happy to hear you found and fixed your problem. Good work back_space!

    Thank You,
    My Blog: https://forums.opensuse.org/blogs/jdmcdaniel3/

    Software efficiency halves every 18 months, thus compensating for Moore's Law

    Its James again from Austin, Texas

  6. #6

    Default Re: Need some help triple booting

    Quote Originally Posted by back_space View Post
    Code:
        Device Boot      Start         End      Blocks   Id  System 
    /dev/sda1            2048     4196351     2097152   82  Linux swap / Solaris     # swap to be used by both
    /dev/sda2         4196352    25167871    10485760   83  Linux                 # /var openSUSE 12.2
    /dev/sda3        25167872    46139391    10485760   83  Linux                 # shared /tmp openSUSE 12.2 + Arch
    /dev/sda4        46139392  1953525167   953692888    5  Extended 
    /dev/sda5        46141440    67112959    10485760   83  Linux                 # /var Archlinux
    /dev/sda6        67115008  1953525167   943205080   83  Linux                 # shared /home openSUSE 12.2 + Arch
    Just in case you have trouble starting X some day and you wonder why: you have /tmp and /var on different file systems. And here's what will happen when the keymap occasionally needs to be recompiled *AND* the TMPDIR variable is set (it it's not, no worry). I mentioned this a couple times and nobody seems to care. It's also an old bug (much older than the following bug report) which affects X on all distros: https://bugs.launchpad.net/ubuntu/+s...er/+bug/972324. I have been dealing with it for years - I first noticed this behaviour as FreeNX/NX sessions were unable to start, and most people still believe that it is a FreeNX bug. But this one is not a FreeNX bug (for a change). My work around is to unset TMPDIR in the X start files and set it back later.


    Quote Originally Posted by back_space View Post
    Why doesn't Grub2 make an Archlinux entry, when it seems as if it sees it when issuing the command 'os-prober'?
    Because for some reason it was not able to mount the ArchLinux partition read only. It might happen again, with various distros (but more specifically Ubuntu Oneiric). This is not the fact that you reinstalled Arch that helped, but the fact that you rebooted it and mounted/unmounted its boot partition again. Btw you do NOT need a /boot partition, really. Hummm ... If I correctly remember, it's not impossible that Arch will complain when you install without a separate /boot, but Arch is wrong on this.

    I've been reporting and trying to fix this bug ... but without success. However my os-prober version includes a DEBUG flag that will show you if a partition could not be mounted. This version (1.53) is in my repo. It has less bugs (includes Fedora and Arch patches) and more features (I added support for ufs2 (BSD) filesystems).

    You can see an example in this bug report https://bugzilla.novell.com/show_bug.cgi?id=767272 where the boot entry was missing for Ubuntu Oneiric. Please add a comment to the bug report if it happens again to you. (this report needs INFO). I might also suggest using my os-prober version and running this command as root:

    Code:
    # OSPDEBUG=yes os-prober

    Another interesting bug report: https://bugzilla.novell.com/show_bug.cgi?id=758732

    If you want to try os-prober 1.53, install my repo and use this command:

    Code:
    # zypper install os-prober-1.53-78.1.x86_64
    Or try this before to find out the latest version (I might still update it):

    Code:
    #  zypper in -r PTA os-prober
    Loading repository data...
    Reading installed packages...
    'os-prober' is already installed.
    There is an update candidate for 'os-prober', but it is from different vendor. Use 'zypper install os-prober-1.53-78.1.x86_64' to install this candidate.
    Resolving package dependencies...
    
    Nothing to do.

    To downgrade os-prober and reinstall the version from openSUSE-12.2-Oss repo, use this command:

    Code:
    #  zypper in --force  os-prober-1.49-2.1.2.x86_64
    You can do it ten times a day (I do on many systems). It won't hurt your Grub or anything.

  7. #7
    Join Date
    Mar 2011
    Location
    Norway
    Posts
    77

    Default Re: Need some help triple booting

    A very educational and informative post please_try_again, thank you!

    I'll take some a that to heart, and leave a message in one of those bug reports if this should happen again. I also added your 12.2 repository just in case I'll need to debug 'os-prober'. In the meantime I'll just brace myself for something to break on my install. If, or maybe when, it breaks, hopefully I've learned something along the way :-)

  8. #8

    Default Re: Need some help triple booting

    I just noticed this 5 minutes ago on Arch systems here after today's update:

    Code:
    # pacman -Q | grep os-prober
    os-prober 1.55-1
    It's probably a good news ... but it also means there is more work to come (for me). I will compare this version with what I have and update the package for openSUSE as soon as I get time...

    I would be surprised if they applied my patches ... but who knows? The Fedora guys did last time ... or more exactly they found the same bug and fixed it the same way (which is normal). Thus I removed my own patch and included theirs, because we're not going to skin the same cat different ways (to James, if he's still following this thread ).

Posting Permissions

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