Grub ukáže menu, ale Linux nenabootuje

Hanka S.

Grub ukáže menu, ale Linux nenabootuje
« kdy: 05. 09. 2012, 10:41:34 »
Na notebooku jsme měli dualboot: Win 7 a Ubuntu 11 a bootovalo se
pomocí grubu. Poté, co byl NTB v opravě, došlo k následující závadě:
Při zapnutí počítače se objeví menu grubu, ale linux se nedá naládovat
- boot skončí v initramfs. Windowsy bootují v pořádku.

Na webu jsem našla různé návody co dělat, když je grub úplně
rozhašený, tzn. nesouhlasí uuid disku, nebo se hledá linux na jiné
partišně, ale to není můj případ. Pro úplnost přikládám výpis blkid:

Kód: [Vybrat]
/dev/loop0: TYPE="squashfs"
/dev/sda1: UUID="9C2410B72410967C" TYPE="ntfs"
/dev/sda2: UUID="86F4-D40A" TYPE="vfat"
/dev/sda5: UUID="fdb3f40f-a5c4-476c-bb8e-28ec863cc0cd" TYPE="swap"
/dev/sda6: UUID="dc2b97b2-aa02-457c-b821-9882303d3436" TYPE="ext4"

grub.cfg:

Kód: [Vybrat]
#
# DO NOT EDIT THIS FILE
#
# It is automatically generated by /usr/sbin/grub-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="0"
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 recordfail {
  set recordfail=1
  if [ -n ${have_grubenv} ]; then if [ -z ${boot_once} ]; then save_env recordfail; fi; fi
}
insmod ext2
set root='(hd0,6)'
search --no-floppy --fs-uuid --set dc2b97b2-aa02-457c-b821-9882303d3436
if loadfont /usr/share/grub/unicode.pf2 ; then
  set gfxmode=640x480
  insmod gfxterm
  insmod vbe
  if terminal_output gfxterm ; then true ; else
    # For backward compatibility with versions of terminal.mod that don't
    # understand terminal_output
    terminal gfxterm
  fi
fi
insmod ext2
set root='(hd0,6)'
search --no-floppy --fs-uuid --set dc2b97b2-aa02-457c-b821-9882303d3436
set locale_dir=($root)/boot/grub/locale
set lang=cs
insmod gettext
if [ ${recordfail} = 1 ]; then
  set timeout=-1
else
  set timeout=10
fi
### END /etc/grub.d/00_header ###

### BEGIN /etc/grub.d/05_debian_theme ###
set menu_color_normal=white/black
set menu_color_highlight=black/light-gray
### END /etc/grub.d/05_debian_theme ###

### BEGIN /etc/grub.d/10_linux ###
menuentry 'Ubuntu, with Linux 2.6.32-33-generic' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod ext2
set root='(hd0,6)'
search --no-floppy --fs-uuid --set dc2b97b2-aa02-457c-b821-9882303d3436
linux /boot/vmlinuz-2.6.32-33-generic root=UUID=dc2b97b2-aa02-457c-b821-9882303d3436 ro   quiet splash
initrd /boot/initrd.img-2.6.32-33-generic
}
menuentry 'Ubuntu, with Linux 2.6.32-33-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod ext2
set root='(hd0,6)'
search --no-floppy --fs-uuid --set dc2b97b2-aa02-457c-b821-9882303d3436
echo 'Loading Linux 2.6.32-33-generic ...'
linux /boot/vmlinuz-2.6.32-33-generic root=UUID=dc2b97b2-aa02-457c-b821-9882303d3436 ro single
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-2.6.32-33-generic
}
menuentry 'Ubuntu, with Linux 2.6.32-29-generic' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod ext2
set root='(hd0,6)'
search --no-floppy --fs-uuid --set dc2b97b2-aa02-457c-b821-9882303d3436
linux /boot/vmlinuz-2.6.32-29-generic root=UUID=dc2b97b2-aa02-457c-b821-9882303d3436 ro   quiet splash
initrd /boot/initrd.img-2.6.32-29-generic
}
menuentry 'Ubuntu, with Linux 2.6.32-29-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod ext2
set root='(hd0,6)'
search --no-floppy --fs-uuid --set dc2b97b2-aa02-457c-b821-9882303d3436
echo 'Loading Linux 2.6.32-29-generic ...'
linux /boot/vmlinuz-2.6.32-29-generic root=UUID=dc2b97b2-aa02-457c-b821-9882303d3436 ro single
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-2.6.32-29-generic
}
menuentry 'Ubuntu, with Linux 2.6.32-28-generic' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod ext2
set root='(hd0,6)'
search --no-floppy --fs-uuid --set dc2b97b2-aa02-457c-b821-9882303d3436
linux /boot/vmlinuz-2.6.32-28-generic root=UUID=dc2b97b2-aa02-457c-b821-9882303d3436 ro   quiet splash
initrd /boot/initrd.img-2.6.32-28-generic
}
menuentry 'Ubuntu, with Linux 2.6.32-28-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod ext2
set root='(hd0,6)'
search --no-floppy --fs-uuid --set dc2b97b2-aa02-457c-b821-9882303d3436
echo 'Loading Linux 2.6.32-28-generic ...'
linux /boot/vmlinuz-2.6.32-28-generic root=UUID=dc2b97b2-aa02-457c-b821-9882303d3436 ro single
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-2.6.32-28-generic
}
menuentry 'Ubuntu, with Linux 2.6.32-27-generic' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod ext2
set root='(hd0,6)'
search --no-floppy --fs-uuid --set dc2b97b2-aa02-457c-b821-9882303d3436
linux /boot/vmlinuz-2.6.32-27-generic root=UUID=dc2b97b2-aa02-457c-b821-9882303d3436 ro   quiet splash
initrd /boot/initrd.img-2.6.32-27-generic
}
menuentry 'Ubuntu, with Linux 2.6.32-27-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod ext2
set root='(hd0,6)'
search --no-floppy --fs-uuid --set dc2b97b2-aa02-457c-b821-9882303d3436
echo 'Loading Linux 2.6.32-27-generic ...'
linux /boot/vmlinuz-2.6.32-27-generic root=UUID=dc2b97b2-aa02-457c-b821-9882303d3436 ro single
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-2.6.32-27-generic
}
menuentry 'Ubuntu, with Linux 2.6.32-24-generic' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod ext2
set root='(hd0,6)'
search --no-floppy --fs-uuid --set dc2b97b2-aa02-457c-b821-9882303d3436
linux /boot/vmlinuz-2.6.32-24-generic root=UUID=dc2b97b2-aa02-457c-b821-9882303d3436 ro   quiet splash
initrd /boot/initrd.img-2.6.32-24-generic
}
menuentry 'Ubuntu, with Linux 2.6.32-24-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod ext2
set root='(hd0,6)'
search --no-floppy --fs-uuid --set dc2b97b2-aa02-457c-b821-9882303d3436
echo 'Loading Linux 2.6.32-24-generic ...'
linux /boot/vmlinuz-2.6.32-24-generic root=UUID=dc2b97b2-aa02-457c-b821-9882303d3436 ro single
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-2.6.32-24-generic
}
### END /etc/grub.d/10_linux ###

### BEGIN /etc/grub.d/20_memtest86+ ###
menuentry "Memory test (memtest86+)" {
insmod ext2
set root='(hd0,6)'
search --no-floppy --fs-uuid --set dc2b97b2-aa02-457c-b821-9882303d3436
linux16 /boot/memtest86+.bin
}
menuentry "Memory test (memtest86+, serial console 115200)" {
insmod ext2
set root='(hd0,6)'
search --no-floppy --fs-uuid --set dc2b97b2-aa02-457c-b821-9882303d3436
linux16 /boot/memtest86+.bin console=ttyS0,115200n8
}
### END /etc/grub.d/20_memtest86+ ###

### BEGIN /etc/grub.d/30_os-prober ###
menuentry "Windows 7 (loader) (on /dev/sda1)" {
insmod ntfs
set root='(hd0,1)'
search --no-floppy --fs-uuid --set 9C2410B72410967C
chainloader +1
}
menuentry "Windows Vista (loader) (on /dev/sda2)" {
insmod fat
set root='(hd0,2)'
search --no-floppy --fs-uuid --set 86f4-d40a
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 ###

Může mi někdo poradit, co je špatně a jak to mám opravit?
« Poslední změna: 06. 09. 2012, 08:37:37 od Petr Krčmář »


Hanka S.

Re:grub ukáže menu, ale linux nenabootuje
« Odpověď #1 kdy: 05. 09. 2012, 11:30:44 »
Tak si odpovím sama - zřejmě to byl mírně nabořený disk. Nabootovala jsem z DVD, přimountovala jsem partišnu s linuxem a chvíli si ji prohlížela. Pak jsem znovu zkusila boot pomocí grubu a naskočila obrazovka Ubuntu a začal se kontrolovat disk. Po kontrole to znovu spadlo do grubu, ale podruhé už se nabootovalo v pořádku. Teď počítač jede a zdá se, že je vše v pořádku.

alfonz

Re:Grub ukáže menu, ale Linux nenabootuje
« Odpověď #2 kdy: 06. 09. 2012, 10:53:25 »
Ano máte pravdu. Toto se někdy stane právě při hrách s diskem(kontrolách, operacích nad partitions, neuzavření přesování atd..), obvykle to spraví právě to spuštění z jiného jádra, které v pohodě nabootuje a rovnou opraví FS disku, který se někdy při startu normálního systému nedá udělat.