PDA

View Full Version : [all variants] No grub menu after Natty upgrade



blimbo
May 4th, 2011, 01:11 PM
I upgraded to Natty yesterday and my system boots into it ok but I don't get a grub menu (and so no other options like recovery mode which I really need right now). I tried purging grub and re-installing it on /dev/sda but still no joy. Here's the info from the Boot Info Script. I've also tried uncommenting GRUB_GFXMODE=640x480 in /etc/default/grub but that doesn't help.

Can anyone see how I can get the menu back?

Thanks,

Tim


Boot Info Script 0.56 from 8 February 2011


============================= Boot Info Summary: ===============================

=> Grub2 (v1.99) is installed in the MBR of /dev/sda and looks at sector 1 of
the same hard drive for core.img. core.img is at this location and looks
for (,msdos1)/boot/grub on this drive.
=> Windows is installed in the MBR of /dev/sdb.

sda1: __________________________________________________ ________________________

File system: ext4
Boot sector type: Grub2 (v1.99)
Boot sector info: Grub2 (v1.99) is installed in the boot sector of sda1
and looks at sector 46407984 of the same hard drive
for core.img. core.img is at this location and looks
for (,msdos1)/boot/grub on this drive.
Operating System: Ubuntu 11.04
Boot files: /boot/grub/grub.cfg /etc/fstab /boot/grub/core.img

sda2: __________________________________________________ ________________________

File system: Extended Partition
Boot sector type: -
Boot sector info:

sda5: __________________________________________________ ________________________

File system: swap
Boot sector type: -
Boot sector info:

sdb1: __________________________________________________ ________________________

File system: ext4
Boot sector type: -
Boot sector info:
Operating System:
Boot files:

============================ Drive/Partition Info: =============================

Drive: 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

Partition Boot Start Sector End Sector # of Sectors Id System

/dev/sda1 * 2,048 1,797,273,599 1,797,271,552 83 Linux
/dev/sda2 1,797,275,646 1,953,523,711 156,248,066 5 Extended
/dev/sda5 1,797,275,648 1,953,523,711 156,248,064 82 Linux swap / Solaris


Drive: sdb __________________________________________________ ___________________

Disk /dev/sdb: 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

Partition Boot Start Sector End Sector # of Sectors Id System

/dev/sdb1 2,048 1,953,523,711 1,953,521,664 83 Linux


"blkid" output: __________________________________________________ ______________

Device UUID TYPE LABEL

/dev/sda1 a717e728-70c3-44c7-87ff-e07b8f369d09 ext4
/dev/sda5 acaaf9fa-8201-4d57-a676-c1d8431cc3e1 swap
/dev/sdb1 cb984fd4-5141-4c5d-86cd-8b9dd58eeffe ext4

================================ Mount points: =================================

Device Mount_Point Type Options

/dev/sda1 / ext4 (rw,errors=remount-ro,commit=0)
/dev/sdb1 /home ext4 (rw,commit=0)


=========================== sda1/boot/grub/grub.cfg: ===========================

--------------------------------------------------------------------------------
#
# DO NOT EDIT THIS FILE
#
# It is automatically generated by 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
set have_grubenv=true
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
}

function load_video {
insmod vbe
insmod vga
insmod video_bochs
insmod video_cirrus
}

insmod part_msdos
insmod ext2
set root='(/dev/sda,msdos1)'
search --no-floppy --fs-uuid --set=root a717e728-70c3-44c7-87ff-e07b8f369d09
if loadfont /usr/share/grub/unicode.pf2 ; then
set gfxmode=auto
load_video
insmod gfxterm
fi
terminal_output gfxterm
insmod part_msdos
insmod ext2
set root='(/dev/sda,msdos1)'
search --no-floppy --fs-uuid --set=root a717e728-70c3-44c7-87ff-e07b8f369d09
set locale_dir=($root)/boot/grub/locale
set lang=en_GB
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
if background_color 44,0,30; then
clear
fi
### END /etc/grub.d/05_debian_theme ###

### BEGIN /etc/grub.d/10_linux ###
if [ ${recordfail} != 1 ]; then
if [ -e ${prefix}/gfxblacklist.txt ]; then
if hwmatch ${prefix}/gfxblacklist.txt 3; then
if [ ${match} = 0 ]; then
set linux_gfx_mode=keep
else
set linux_gfx_mode=text
fi
else
set linux_gfx_mode=text
fi
else
set linux_gfx_mode=keep
fi
else
set linux_gfx_mode=text
fi
export linux_gfx_mode
if [ "$linux_gfx_mode" != "text" ]; then load_video; fi
menuentry 'Ubuntu, with Linux 2.6.38-8-generic' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
set gfxpayload=$linux_gfx_mode
insmod part_msdos
insmod ext2
set root='(/dev/sda,msdos1)'
search --no-floppy --fs-uuid --set=root a717e728-70c3-44c7-87ff-e07b8f369d09
linux /boot/vmlinuz-2.6.38-8-generic root=UUID=a717e728-70c3-44c7-87ff-e07b8f369d09 ro quiet splash vt.handoff=7
initrd /boot/initrd.img-2.6.38-8-generic
}
menuentry 'Ubuntu, with Linux 2.6.38-8-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
set gfxpayload=$linux_gfx_mode
insmod part_msdos
insmod ext2
set root='(/dev/sda,msdos1)'
search --no-floppy --fs-uuid --set=root a717e728-70c3-44c7-87ff-e07b8f369d09
echo 'Loading Linux 2.6.38-8-generic ...'
linux /boot/vmlinuz-2.6.38-8-generic root=UUID=a717e728-70c3-44c7-87ff-e07b8f369d09 ro single
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-2.6.38-8-generic
}
submenu "Previous Linux versions" {
menuentry 'Ubuntu, with Linux 2.6.35-28-generic' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
set gfxpayload=$linux_gfx_mode
insmod part_msdos
insmod ext2
set root='(/dev/sda,msdos1)'
search --no-floppy --fs-uuid --set=root a717e728-70c3-44c7-87ff-e07b8f369d09
linux /boot/vmlinuz-2.6.35-28-generic root=UUID=a717e728-70c3-44c7-87ff-e07b8f369d09 ro quiet splash vt.handoff=7
initrd /boot/initrd.img-2.6.35-28-generic
}
menuentry 'Ubuntu, with Linux 2.6.35-28-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
set gfxpayload=$linux_gfx_mode
insmod part_msdos
insmod ext2
set root='(/dev/sda,msdos1)'
search --no-floppy --fs-uuid --set=root a717e728-70c3-44c7-87ff-e07b8f369d09
echo 'Loading Linux 2.6.35-28-generic ...'
linux /boot/vmlinuz-2.6.35-28-generic root=UUID=a717e728-70c3-44c7-87ff-e07b8f369d09 ro single
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-2.6.35-28-generic
}
}
### 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+ ###
menuentry "Memory test (memtest86+)" {
insmod part_msdos
insmod ext2
set root='(/dev/sda,msdos1)'
search --no-floppy --fs-uuid --set=root a717e728-70c3-44c7-87ff-e07b8f369d09
linux16 /boot/memtest86+.bin
}
menuentry "Memory test (memtest86+, serial console 115200)" {
insmod part_msdos
insmod ext2
set root='(/dev/sda,msdos1)'
search --no-floppy --fs-uuid --set=root a717e728-70c3-44c7-87ff-e07b8f369d09
linux16 /boot/memtest86+.bin console=ttyS0,115200n8
}
### END /etc/grub.d/20_memtest86+ ###

### BEGIN /etc/grub.d/30_os-prober ###
if [ "x${timeout}" != "x-1" ]; then
if keystatus; then
if keystatus --shift; then
set timeout=-1
else
set timeout=0
fi
else
if sleep --interruptible 3 ; then
set timeout=0
fi
fi
fi
### 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 $prefix/custom.cfg ]; then
source $prefix/custom.cfg;
fi
### END /etc/grub.d/41_custom ###
--------------------------------------------------------------------------------

=============================== sda1/etc/fstab: ================================

--------------------------------------------------------------------------------
# /etc/fstab: static file system information.
#
# Use 'blkid -o value -s UUID' to print the universally unique identifier
# for a device; this may be used with UUID= as a more robust way to name
# devices that works even if disks are added and removed. See fstab(5).
#
# <file system> <mount point> <type> <options> <dump> <pass>
proc /proc proc nodev,noexec,nosuid 0 0
# / was on /dev/sda1 during installation
UUID=a717e728-70c3-44c7-87ff-e07b8f369d09 / ext4 errors=remount-ro 0 1
# /home was on /dev/sdb1 during installation
UUID=cb984fd4-5141-4c5d-86cd-8b9dd58eeffe /home ext4 defaults 0 2
# swap was on /dev/sda5 during installation
UUID=acaaf9fa-8201-4d57-a676-c1d8431cc3e1 none swap sw 0 0
--------------------------------------------------------------------------------

=================== sda1: Location of files loaded by Grub: ====================

GiB - GB File Fragment(s)

22.140335083 = 23.773003776 boot/grub/core.img 1
334.169094086 = 358.811332608 boot/grub/grub.cfg 1
361.422851562 = 388.074831872 boot/initrd.img-2.6.35-28-generic 2
0.514389038 = 0.552321024 boot/initrd.img-2.6.38-8-generic 3
0.770507812 = 0.827326464 boot/vmlinuz-2.6.35-28-generic 2
359.872379303 = 386.410024960 boot/vmlinuz-2.6.38-8-generic 1
0.514389038 = 0.552321024 initrd.img 3
361.422851562 = 388.074831872 initrd.img.old 2
359.872379303 = 386.410024960 vmlinuz 1
0.770507812 = 0.827326464 vmlinuz.old 2

========= Devices which don't seem to have a corresponding hard drive: =========

sdc

=============================== StdErr Messages: ===============================

unlzma: Decoder error
unlzma: Decoder error

Quackers
May 4th, 2011, 01:35 PM
If you only have one operating system installed grub does not show by default. If you want to see grub try holding down the shift key during boot.

blimbo
May 4th, 2011, 01:36 PM
Ah thanks for the tip. Do you know if there's a config option to get it to show regardless?

Quackers
May 4th, 2011, 01:42 PM
I've always had more than one system installed so have never come up against your problem. I'm not sure that there is an option to display grub in your circumstances. Maybe somebody else could advise.

blimbo
May 4th, 2011, 08:32 PM
Ah found it, looks like this needs to be changed in /etc/default/grub:

GRUB_HIDDEN_TIMEOUT=0 on single operating system computers.
No menu is displayed. The system is immediately booted to the default OS.
This is the default setting with only one identified operating system.

To display the menu under this condition, place a # symbol at the start of the line and ensure the GRUB_TIMEOUT setting is a positive integer.

https://help.ubuntu.com/community/Grub2