I don't get Grub running

Hi Folks,

my system disk crashed yesterday so I replaced it. I applied a clonezilla image to the new disk and das OS is installed.
Of course the boot loader has to be modified because the old disk isn’t available anymore.
Sounds easy, but doesn’t work.

I’m using Yast2 to do the grub configuration. But the system always throws Grub error 22 at start up. If start from clonezilla dist it finds the OS and starts.

Can somebody tell me how to configure the boot loader with Yast2?

Here comes the data:

OS: openSuSE 12.3

fstab


/dev/disk/by-id/ata-HITACHI_HTS725050A7E630_TF1500Y9GZ17TB-part1        swap    swap    defaults 0 0 
/dev/disk/by-id/ata-HITACHI_HTS725050A7E630_TF1500Y9GZ17TB-part2        /       ext4    acl,user_xattr 1 1 
/dev/md1        /home   ext4    defaults 1 2 
proc    /proc   proc    defaults 0 0 
sysfs   /sys    sysfs   noauto 0 0 
debugfs /sys/kernel/debug       debugfs noauto 0 0 
usbfs   /proc/bus/usb   usbfs   noauto 0 0 
devpts  /dev/pts        devpts  mode=0620,gid=5 0 0 
192.168.2.9:/home/karsten/Music /home/karsten/Music     nfs     defaults 0 0 

/etc/default/grub


# Modified by YaST2. Last modification on Thu May 23 11:38:45 CEST 2013
# THIS FILE WILL BE PARTIALLY OVERWRITTEN by perl-Bootloader
# For the new kernel it try to figure out old parameters. In case we are not able to recognize it (e.g. change of flavor or strange install order ) it it use as fallback installation parameters from /etc/sysconfig/bootloader

# If you change this file, run 'grub2-mkconfig -o /boot/grub2/grub.cfg' afterwards to update
# /boot/grub2/grub.cfg.
GRUB_DISTRIBUTOR="openSUSE 12.3"
GRUB_DEFAULT=saved
GRUB_HIDDEN_TIMEOUT=0
GRUB_HIDDEN_TIMEOUT_QUIET=true
GRUB_TIMEOUT=8
GRUB_CMDLINE_LINUX_DEFAULT=" resume=/dev/disk/by-id/ata-HITACHI_HTS725050A7E630_TF1500Y9GZ17TB-part2 splash=silent quiet showopts"
# kernel command line options for failsafe mode
GRUB_CMDLINE_LINUX_RECOVERY="showopts apm=off noresume edd=off powersaved=off nohz=off highres=off processor.max_cstate=1 nomodeset x11failsafe"
GRUB_CMDLINE_LINUX=""
# Uncomment to enable BadRAM filtering, modify to suit your needs
# This works with Linux (no patch required) and with any kernel that obtains
# the memory map information from GRUB (GNU Mach, kernel of FreeBSD ...)
#GRUB_BADRAM=0x01234567,0xfefefefe,0x89abcdef,0xefefefef
# Uncomment to disable graphical terminal (grub-pc only)
GRUB_TERMINAL=gfxterm
# The resolution used on graphical terminal
# note that you can use only modes which your graphic card supports via VBE
# you can see them in real GRUB with the command `vbeinfo'
GRUB_GFXMODE=auto
# Uncomment if you don't want GRUB to pass "root=UUID=xxx" parameter to Linux
#GRUB_DISABLE_LINUX_UUID=true
# Uncomment to disable generation of recovery mode menu entries
#GRUB_DISABLE_LINUX_RECOVERY=true
# Uncomment to get a beep at grub start
#GRUB_INIT_TUNE="480 440 1"
# Skip 30_os-prober if you experienced very slow in probing them
# WARNING foregin OS menu entries will be lost if set true here
GRUB_DISABLE_OS_PROBER=false
GRUB_THEME=/boot/grub2/themes/openSUSE/theme.txt
GRUB_BACKGROUND=/boot/grub2/themes/openSUSE/background.png

/etc/default/grub_installedevice


(hd0,2)
(hd0)
(hd0,2)
activate
generic_mbr

/boot/grub2/grub.cfg


#
# 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='hd0,msdos2'
if  x$feature_platform_search_hint = xy ]; then
  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos2 --hint-efi=hd0,msdos2 --hint-baremetal=ahci0,msdos2 --hint='hd0,msdos2'  48657300-404b-4fe1-af5b-8215f784a424
else
  search --no-floppy --fs-uuid --set=root 48657300-404b-4fe1-af5b-8215f784a424
fi
    font="/usr/share/grub2/unicode.pf2"
fi

if loadfont $font ; then
  set gfxmode=auto
  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='hd0,msdos2'
if  x$feature_platform_search_hint = xy ]; then
  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos2 --hint-efi=hd0,msdos2 --hint-baremetal=ahci0,msdos2 --hint='hd0,msdos2'  48657300-404b-4fe1-af5b-8215f784a424
else
  search --no-floppy --fs-uuid --set=root 48657300-404b-4fe1-af5b-8215f784a424
fi
insmod gfxmenu
loadfont ($root)/boot/grub2/themes/openSUSE/DejaVuSans-Bold14.pf2
loadfont ($root)/boot/grub2/themes/openSUSE/DejaVuSans10.pf2
loadfont ($root)/boot/grub2/themes/openSUSE/DejaVuSans12.pf2
loadfont ($root)/boot/grub2/themes/openSUSE/ascii.pf2
insmod png
set theme=($root)/boot/grub2/themes/openSUSE/theme.txt
export theme
if  x${boot_once} = xtrue ]; then
  set timeout=0
elif sleep --interruptible 0 ; then
  set timeout=8
fi
### END /etc/grub.d/00_header ###

### BEGIN /etc/grub.d/10_linux ###
menuentry 'openSUSE 12.3' --class 'opensuse-12-3' --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-simple-48657300-404b-4fe1-af5b-8215f784a424' {
    load_video
    set gfxpayload=keep
    insmod gzio
    insmod part_msdos
    insmod ext2
    set root='hd0,msdos2'
    if  x$feature_platform_search_hint = xy ]; then
      search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos2 --hint-efi=hd0,msdos2 --hint-baremetal=ahci0,msdos2 --hint='hd0,msdos2'  48657300-404b-4fe1-af5b-8215f784a424
    else
      search --no-floppy --fs-uuid --set=root 48657300-404b-4fe1-af5b-8215f784a424
    fi
    echo    'Loading Linux 3.7.10-1.4-desktop ...'
    linux    /boot/vmlinuz-3.7.10-1.4-desktop root=UUID=48657300-404b-4fe1-af5b-8215f784a424   resume=/dev/disk/by-id/ata-HITACHI_HTS725050A7E630_TF1500Y9GZ17TB-part2 splash=silent quiet showopts
    echo    'Loading initial ramdisk ...'
    initrd    /boot/initrd-3.7.10-1.4-desktop
}
submenu 'Advanced options for openSUSE 12.3' $menuentry_id_option 'gnulinux-advanced-48657300-404b-4fe1-af5b-8215f784a424' {
    menuentry 'openSUSE 12.3, with Linux 3.7.10-1.4-desktop' --class 'opensuse-12-3' --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-3.7.10-1.4-desktop-advanced-48657300-404b-4fe1-af5b-8215f784a424' {
        load_video
        set gfxpayload=keep
        insmod gzio
        insmod part_msdos
        insmod ext2
        set root='hd0,msdos2'
        if  x$feature_platform_search_hint = xy ]; then
          search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos2 --hint-efi=hd0,msdos2 --hint-baremetal=ahci0,msdos2 --hint='hd0,msdos2'  48657300-404b-4fe1-af5b-8215f784a424
        else
          search --no-floppy --fs-uuid --set=root 48657300-404b-4fe1-af5b-8215f784a424
        fi
        echo    'Loading Linux 3.7.10-1.4-desktop ...'
        linux    /boot/vmlinuz-3.7.10-1.4-desktop root=UUID=48657300-404b-4fe1-af5b-8215f784a424   resume=/dev/disk/by-id/ata-HITACHI_HTS725050A7E630_TF1500Y9GZ17TB-part2 splash=silent quiet showopts
        echo    'Loading initial ramdisk ...'
        initrd    /boot/initrd-3.7.10-1.4-desktop
    }
    menuentry 'openSUSE 12.3, with Linux 3.7.10-1.4-desktop (recovery mode)' --class 'opensuse-12-3' --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-3.7.10-1.4-desktop-recovery-48657300-404b-4fe1-af5b-8215f784a424' {
        load_video
        set gfxpayload=keep
        insmod gzio
        insmod part_msdos
        insmod ext2
        set root='hd0,msdos2'
        if  x$feature_platform_search_hint = xy ]; then
          search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos2 --hint-efi=hd0,msdos2 --hint-baremetal=ahci0,msdos2 --hint='hd0,msdos2'  48657300-404b-4fe1-af5b-8215f784a424
        else
          search --no-floppy --fs-uuid --set=root 48657300-404b-4fe1-af5b-8215f784a424
        fi
        echo    'Loading Linux 3.7.10-1.4-desktop ...'
        linux    /boot/vmlinuz-3.7.10-1.4-desktop root=UUID=48657300-404b-4fe1-af5b-8215f784a424  showopts apm=off noresume edd=off powersaved=off nohz=off highres=off processor.max_cstate=1 nomodeset x11failsafe
        echo    'Loading initial ramdisk ...'
        initrd    /boot/initrd-3.7.10-1.4-desktop
    }
    menuentry 'openSUSE 12.3, with Linux 3.7.10-1.1-desktop' --class 'opensuse-12-3' --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-3.7.10-1.1-desktop-advanced-48657300-404b-4fe1-af5b-8215f784a424' {
        load_video
        set gfxpayload=keep
        insmod gzio
        insmod part_msdos
        insmod ext2
        set root='hd0,msdos2'
        if  x$feature_platform_search_hint = xy ]; then
          search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos2 --hint-efi=hd0,msdos2 --hint-baremetal=ahci0,msdos2 --hint='hd0,msdos2'  48657300-404b-4fe1-af5b-8215f784a424
        else
          search --no-floppy --fs-uuid --set=root 48657300-404b-4fe1-af5b-8215f784a424
        fi
        echo    'Loading Linux 3.7.10-1.1-desktop ...'
        linux    /boot/vmlinuz-3.7.10-1.1-desktop root=UUID=48657300-404b-4fe1-af5b-8215f784a424   resume=/dev/disk/by-id/ata-HITACHI_HTS725050A7E630_TF1500Y9GZ17TB-part2 splash=silent quiet showopts
        echo    'Loading initial ramdisk ...'
        initrd    /boot/initrd-3.7.10-1.1-desktop
    }
    menuentry 'openSUSE 12.3, with Linux 3.7.10-1.1-desktop (recovery mode)' --class 'opensuse-12-3' --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-3.7.10-1.1-desktop-recovery-48657300-404b-4fe1-af5b-8215f784a424' {
        load_video
        set gfxpayload=keep
        insmod gzio
        insmod part_msdos
        insmod ext2
        set root='hd0,msdos2'
        if  x$feature_platform_search_hint = xy ]; then
          search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos2 --hint-efi=hd0,msdos2 --hint-baremetal=ahci0,msdos2 --hint='hd0,msdos2'  48657300-404b-4fe1-af5b-8215f784a424
        else
          search --no-floppy --fs-uuid --set=root 48657300-404b-4fe1-af5b-8215f784a424
        fi
        echo    'Loading Linux 3.7.10-1.1-desktop ...'
        linux    /boot/vmlinuz-3.7.10-1.1-desktop root=UUID=48657300-404b-4fe1-af5b-8215f784a424  showopts apm=off noresume edd=off powersaved=off nohz=off highres=off processor.max_cstate=1 nomodeset x11failsafe
        echo    'Loading initial ramdisk ...'
        initrd    /boot/initrd-3.7.10-1.1-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_memtest86+ ###
### END /etc/grub.d/20_memtest86+ ###

### BEGIN /etc/grub.d/20_ppc_terminfo ###
### END /etc/grub.d/20_ppc_terminfo ###

### BEGIN /etc/grub.d/30_os-prober ###
### 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 ###

Hi Folks,

meanwhile I am one step further.
The new disk wasn’t configured in the BIOS as the Boot Device. Hence no boot loader could be found.
I changed that.

Now I’m getting Error 15 at start up.

Still no idea why the boot loader isn’t found now.

Anybody here who could give me a hint?

Regards,

Karsten

Error 22 and Error 15 means you are you using grub legacy, not grub2. Is it correct?

Well, at least not on purpose;) I try to get the system running with grub2. Before the disk crash it has been configured to grub2. I have no idea why old grub is back again.