PDA

View Full Version : [ubuntu] Grub rescue, no such partition after expanding partition w/ Gparted



justins1983
February 22nd, 2011, 10:13 PM
Here is my bootscript results file. sdb can be ignored. That was a second drive I hooked up after I couldnt boot up ubuntu.


Boot Info Script 0.55 dated February 15th, 2010

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

=> Grub 2 is installed in the MBR of /dev/sda and looks on the same drive in
partition #6 for /boot/grub.
=> Grub 0.97 is installed in the MBR of /dev/sdb and looks on the same drive
in partition #1 for /boot/grub/stage2 and /boot/grub/menu.lst.

sda1: __________________________________________________ _______________________

File system: ext4
Boot sector type: -
Boot sector info:
Operating System: Ubuntu 10.10
Boot files/dirs: /boot/grub/grub.cfg /etc/fstab /boot/grub/core.img

sda2: __________________________________________________ _______________________

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

sdb1: __________________________________________________ _______________________

File system: ext3
Boot sector type: -
Boot sector info:
Operating System: Ubuntu 10.04.1 LTS
Boot files/dirs: /boot/grub/menu.lst /etc/fstab

sdb2: __________________________________________________ _______________________

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

sdb5: __________________________________________________ _______________________

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

=========================== 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 End Size Id System

/dev/sda1 * 63 1,951,297,533 1,951,297,471 83 Linux
/dev/sda2 1,951,297,534 1,953,520,064 2,222,531 82 Linux swap / Solaris


Drive: sdb ___________________ __________________________________________________ ___

Disk /dev/sdb: 160.0 GB, 160041885696 bytes
255 heads, 63 sectors/track, 19457 cylinders, total 312581808 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes

Partition Boot Start End Size Id System

/dev/sdb1 * 63 306,905,759 306,905,697 83 Linux
/dev/sdb2 306,905,760 312,576,704 5,670,945 5 Extended
/dev/sdb5 306,905,823 312,576,704 5,670,882 82 Linux swap / Solaris


blkid -c /dev/null: __________________________________________________ __________

Device UUID TYPE LABEL

/dev/loop0 squashfs
/dev/sda1 56a68319-2b33-4324-9520-4e75cca2e6c4 ext4
/dev/sda2 21626f1d-91d8-4e58-8232-7008371f77bf swap /dev/sda5
/dev/sda: PTTYPE="dos"
/dev/sdb1 3d25de7d-f45e-4916-981d-4f8b8e8c6ea9 ext3
/dev/sdb2: PTTYPE="dos"
/dev/sdb5 3a1a7fa1-76ee-402e-8ae0-4fc6bde0bed0 swap
/dev/sdb: PTTYPE="dos"

============================ "mount | grep ^/dev output: ===========================

Device Mount_Point Type Options

aufs / aufs (rw)
/dev/sr0 /cdrom iso9660 (ro,noatime)
/dev/loop0 /rofs squashfs (ro,noatime)
/dev/sda1 /media/56a68319-2b33-4324-9520-4e75cca2e6c4 ext4 (rw,nosuid,nodev,uhelper=udisks)


=========================== 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 part_msdos
insmod ext2
set root='(hd0,msdos1)'
search --no-floppy --fs-uuid --set 56a68319-2b33-4324-9520-4e75cca2e6c4
if loadfont /usr/share/grub/unicode.pf2 ; then
set gfxmode=640x480
load_video
insmod gfxterm
fi
terminal_output gfxterm
insmod part_msdos
insmod ext2
set root='(hd0,msdos1)'
search --no-floppy --fs-uuid --set 56a68319-2b33-4324-9520-4e75cca2e6c4
set locale_dir=($root)/boot/grub/locale
set lang=en
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.35-25-generic' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod part_msdos
insmod ext2
set root='(hd0,msdos1)'
search --no-floppy --fs-uuid --set 56a68319-2b33-4324-9520-4e75cca2e6c4
linux /boot/vmlinuz-2.6.35-25-generic root=UUID=56a68319-2b33-4324-9520-4e75cca2e6c4 ro quiet splash
initrd /boot/initrd.img-2.6.35-25-generic
}
menuentry 'Ubuntu, with Linux 2.6.35-25-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod part_msdos
insmod ext2
set root='(hd0,msdos1)'
search --no-floppy --fs-uuid --set 56a68319-2b33-4324-9520-4e75cca2e6c4
echo 'Loading Linux 2.6.35-25-generic ...'
linux /boot/vmlinuz-2.6.35-25-generic root=UUID=56a68319-2b33-4324-9520-4e75cca2e6c4 ro single
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-2.6.35-25-generic
}
menuentry 'Ubuntu, with Linux 2.6.35-24-generic' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod part_msdos
insmod ext2
set root='(hd0,msdos1)'
search --no-floppy --fs-uuid --set 56a68319-2b33-4324-9520-4e75cca2e6c4
linux /boot/vmlinuz-2.6.35-24-generic root=UUID=56a68319-2b33-4324-9520-4e75cca2e6c4 ro quiet splash
initrd /boot/initrd.img-2.6.35-24-generic
}
menuentry 'Ubuntu, with Linux 2.6.35-24-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod part_msdos
insmod ext2
set root='(hd0,msdos1)'
search --no-floppy --fs-uuid --set 56a68319-2b33-4324-9520-4e75cca2e6c4
echo 'Loading Linux 2.6.35-24-generic ...'
linux /boot/vmlinuz-2.6.35-24-generic root=UUID=56a68319-2b33-4324-9520-4e75cca2e6c4 ro single
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-2.6.35-24-generic
}
menuentry 'Ubuntu, with Linux 2.6.35-22-generic' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod part_msdos
insmod ext2
set root='(hd0,msdos1)'
search --no-floppy --fs-uuid --set 56a68319-2b33-4324-9520-4e75cca2e6c4
linux /boot/vmlinuz-2.6.35-22-generic root=UUID=56a68319-2b33-4324-9520-4e75cca2e6c4 ro quiet splash
initrd /boot/initrd.img-2.6.35-22-generic
}
menuentry 'Ubuntu, with Linux 2.6.35-22-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod part_msdos
insmod ext2
set root='(hd0,msdos1)'
search --no-floppy --fs-uuid --set 56a68319-2b33-4324-9520-4e75cca2e6c4
echo 'Loading Linux 2.6.35-22-generic ...'
linux /boot/vmlinuz-2.6.35-22-generic root=UUID=56a68319-2b33-4324-9520-4e75cca2e6c4 ro single
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-2.6.35-22-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='(hd0,msdos1)'
search --no-floppy --fs-uuid --set 56a68319-2b33-4324-9520-4e75cca2e6c4
linux16 /boot/memtest86+.bin
}
menuentry "Memory test (memtest86+, serial console 115200)" {
insmod part_msdos
insmod ext2
set root='(hd0,msdos1)'
search --no-floppy --fs-uuid --set 56a68319-2b33-4324-9520-4e75cca2e6c4
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=56a68319-2b33-4324-9520-4e75cca2e6c4 / ext4 errors=remount-ro 0 1
# swap was on /dev/sda5 during installation
UUID=0f24b1b0-c481-4ef5-941b-7b4fb00a957f none swap sw 0 0

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


58.1GB: boot/grub/core.img
8.0GB: boot/grub/grub.cfg
.9GB: boot/initrd.img-2.6.35-22-generic
99.5GB: boot/initrd.img-2.6.35-24-generic
66.8GB: boot/initrd.img-2.6.35-25-generic
58.1GB: boot/vmlinuz-2.6.35-22-generic
58.1GB: boot/vmlinuz-2.6.35-24-generic
58.1GB: boot/vmlinuz-2.6.35-25-generic
66.8GB: initrd.img
99.5GB: initrd.img.old
58.1GB: vmlinuz
58.1GB: vmlinuz.old

=========================== sdb1/boot/grub/menu.lst: ===========================

# menu.lst - See: grub(8), info grub, update-grub(8)
# grub-install(8), grub-floppy(8),
# grub-md5-crypt, /usr/share/doc/grub
# and /usr/share/doc/grub-doc/.

## default num
# Set the default entry to the entry number NUM. Numbering starts from 0, and
# the entry number 0 is the default if the command is not used.
#
# You can specify 'saved' instead of a number. In this case, the default entry
# is the entry saved with the command 'savedefault'.
# WARNING: If you are using dmraid do not change this entry to 'saved' or your
# array will desync and will not let you boot your system.
default 0

## timeout sec
# Set a timeout, in SEC seconds, before automatically booting the default entry
# (normally the first entry defined).
timeout 3

## hiddenmenu
# Hides the menu by default (press ESC to see the menu)
hiddenmenu

# Pretty colours
#color cyan/blue white/blue

## password ['--md5'] passwd
# If used in the first section of a menu file, disable all interactive editing
# control (menu entry editor and command-line) and entries protected by the
# command 'lock'
# e.g. password topsecret
# password --md5 $1$gLhU0/$aW78kHK1QfV3P2b2znUoe/
# password topsecret

#
# examples
#
# title Windows 95/98/NT/2000
# root (hd0,0)
# makeactive
# chainloader +1
#
# title Linux
# root (hd0,1)
# kernel /vmlinuz root=/dev/hda2 ro
#

#
# Put static boot stanzas before and/or after AUTOMAGIC KERNEL LIST

### BEGIN AUTOMAGIC KERNELS LIST
## lines between the AUTOMAGIC KERNELS LIST markers will be modified
## by the debian update-grub script except for the default options below

## DO NOT UNCOMMENT THEM, Just edit them to your needs

## ## Start Default Options ##
## default kernel options
## default kernel options for automagic boot options
## If you want special options for specific kernels use kopt_x_y_z
## where x.y.z is kernel version. Minor versions can be omitted.
## e.g. kopt=root=/dev/hda1 ro
## kopt_2_6_8=root=/dev/hdc1 ro
## kopt_2_6_8_2_686=root=/dev/hdc2 ro
# kopt=root=UUID=3d25de7d-f45e-4916-981d-4f8b8e8c6ea9 ro

## default grub root device
## e.g. groot=(hd0,0)
# groot=(hd0,0)

## should update-grub create alternative automagic boot options
## e.g. alternative=true
## alternative=false
# alternative=true

## should update-grub lock alternative automagic boot options
## e.g. lockalternative=true
## lockalternative=false
# lockalternative=false

## additional options to use with the default boot option, but not with the
## alternatives
## e.g. defoptions=vga=791 resume=/dev/hda5
# defoptions=quiet splash

## should update-grub lock old automagic boot options
## e.g. lockold=false
## lockold=true
# lockold=false

## Xen hypervisor options to use with the default Xen boot option
# xenhopt=

## Xen Linux kernel options to use with the default Xen boot option
# xenkopt=console=tty0

## altoption boot targets option
## multiple altoptions lines are allowed
## e.g. altoptions=(extra menu suffix) extra boot options
## altoptions=(recovery) single
# altoptions=(recovery mode) single

## controls how many kernels should be put into the menu.lst
## only counts the first occurence of a kernel, not the
## alternative kernel options
## e.g. howmany=all
## howmany=7
# howmany=all

## specify if running in Xen domU or have grub detect automatically
## update-grub will ignore non-xen kernels when running in domU and vice versa
## e.g. indomU=detect
## indomU=true
## indomU=false
# indomU=detect

## should update-grub create memtest86 boot option
## e.g. memtest86=true
## memtest86=false
# memtest86=true

## should update-grub adjust the value of the default booted system
## can be true or false
# updatedefaultentry=false

## should update-grub add savedefault to the default options
## can be true or false
# savedefault=false

## ## End Default Options ##

title Ubuntu 10.04.1 LTS, kernel 2.6.32-26-generic
root (hd0,0)
kernel /boot/vmlinuz-2.6.32-26-generic root=UUID=3d25de7d-f45e-4916-981d-4f8b8e8c6ea9 ro quiet splash
initrd /boot/initrd.img-2.6.32-26-generic
quiet

title Ubuntu 10.04.1 LTS, kernel 2.6.32-26-generic (recovery mode)
root (hd0,0)
kernel /boot/vmlinuz-2.6.32-26-generic root=UUID=3d25de7d-f45e-4916-981d-4f8b8e8c6ea9 ro single
initrd /boot/initrd.img-2.6.32-26-generic

title Ubuntu 10.04.1 LTS, kernel 2.6.31-22-generic
root (hd0,0)
kernel /boot/vmlinuz-2.6.31-22-generic root=UUID=3d25de7d-f45e-4916-981d-4f8b8e8c6ea9 ro quiet splash
initrd /boot/initrd.img-2.6.31-22-generic
quiet

title Ubuntu 10.04.1 LTS, kernel 2.6.31-22-generic (recovery mode)
root (hd0,0)
kernel /boot/vmlinuz-2.6.31-22-generic root=UUID=3d25de7d-f45e-4916-981d-4f8b8e8c6ea9 ro single
initrd /boot/initrd.img-2.6.31-22-generic

title Ubuntu 10.04.1 LTS, kernel 2.6.24-24-generic
root (hd0,0)
kernel /boot/vmlinuz-2.6.24-24-generic root=UUID=3d25de7d-f45e-4916-981d-4f8b8e8c6ea9 ro quiet splash
initrd /boot/initrd.img-2.6.24-24-generic
quiet

title Ubuntu 10.04.1 LTS, kernel 2.6.24-24-generic (recovery mode)
root (hd0,0)
kernel /boot/vmlinuz-2.6.24-24-generic root=UUID=3d25de7d-f45e-4916-981d-4f8b8e8c6ea9 ro single
initrd /boot/initrd.img-2.6.24-24-generic

title Ubuntu 10.04.1 LTS, kernel 2.6.24-23-generic
root (hd0,0)
kernel /boot/vmlinuz-2.6.24-23-generic root=UUID=3d25de7d-f45e-4916-981d-4f8b8e8c6ea9 ro quiet splash
initrd /boot/initrd.img-2.6.24-23-generic
quiet

title Ubuntu 10.04.1 LTS, kernel 2.6.24-23-generic (recovery mode)
root (hd0,0)
kernel /boot/vmlinuz-2.6.24-23-generic root=UUID=3d25de7d-f45e-4916-981d-4f8b8e8c6ea9 ro single
initrd /boot/initrd.img-2.6.24-23-generic

title Ubuntu 10.04.1 LTS, kernel 2.6.24-22-generic
root (hd0,0)
kernel /boot/vmlinuz-2.6.24-22-generic root=UUID=3d25de7d-f45e-4916-981d-4f8b8e8c6ea9 ro quiet splash
initrd /boot/initrd.img-2.6.24-22-generic
quiet

title Ubuntu 10.04.1 LTS, kernel 2.6.24-22-generic (recovery mode)
root (hd0,0)
kernel /boot/vmlinuz-2.6.24-22-generic root=UUID=3d25de7d-f45e-4916-981d-4f8b8e8c6ea9 ro single
initrd /boot/initrd.img-2.6.24-22-generic

title Ubuntu 10.04.1 LTS, kernel 2.6.24-21-generic
root (hd0,0)
kernel /boot/vmlinuz-2.6.24-21-generic root=UUID=3d25de7d-f45e-4916-981d-4f8b8e8c6ea9 ro quiet splash
initrd /boot/initrd.img-2.6.24-21-generic
quiet

title Ubuntu 10.04.1 LTS, kernel 2.6.24-21-generic (recovery mode)
root (hd0,0)
kernel /boot/vmlinuz-2.6.24-21-generic root=UUID=3d25de7d-f45e-4916-981d-4f8b8e8c6ea9 ro single
initrd /boot/initrd.img-2.6.24-21-generic

title Ubuntu 10.04.1 LTS, kernel 2.6.24-19-generic
root (hd0,0)
kernel /boot/vmlinuz-2.6.24-19-generic root=UUID=3d25de7d-f45e-4916-981d-4f8b8e8c6ea9 ro quiet splash
initrd /boot/initrd.img-2.6.24-19-generic
quiet

title Ubuntu 10.04.1 LTS, kernel 2.6.24-19-generic (recovery mode)
root (hd0,0)
kernel /boot/vmlinuz-2.6.24-19-generic root=UUID=3d25de7d-f45e-4916-981d-4f8b8e8c6ea9 ro single
initrd /boot/initrd.img-2.6.24-19-generic

title Ubuntu 10.04.1 LTS, kernel 2.6.24-18-generic
root (hd0,0)
kernel /boot/vmlinuz-2.6.24-18-generic root=UUID=3d25de7d-f45e-4916-981d-4f8b8e8c6ea9 ro quiet splash
initrd /boot/initrd.img-2.6.24-18-generic
quiet

title Ubuntu 10.04.1 LTS, kernel 2.6.24-18-generic (recovery mode)
root (hd0,0)
kernel /boot/vmlinuz-2.6.24-18-generic root=UUID=3d25de7d-f45e-4916-981d-4f8b8e8c6ea9 ro single
initrd /boot/initrd.img-2.6.24-18-generic

title Ubuntu 10.04.1 LTS, kernel 2.6.24-17-generic
root (hd0,0)
kernel /boot/vmlinuz-2.6.24-17-generic root=UUID=3d25de7d-f45e-4916-981d-4f8b8e8c6ea9 ro quiet splash
initrd /boot/initrd.img-2.6.24-17-generic
quiet

title Ubuntu 10.04.1 LTS, kernel 2.6.24-17-generic (recovery mode)
root (hd0,0)
kernel /boot/vmlinuz-2.6.24-17-generic root=UUID=3d25de7d-f45e-4916-981d-4f8b8e8c6ea9 ro single
initrd /boot/initrd.img-2.6.24-17-generic

title Ubuntu 10.04.1 LTS, kernel 2.6.24-16-generic
root (hd0,0)
kernel /boot/vmlinuz-2.6.24-16-generic root=UUID=3d25de7d-f45e-4916-981d-4f8b8e8c6ea9 ro quiet splash
initrd /boot/initrd.img-2.6.24-16-generic
quiet

title Ubuntu 10.04.1 LTS, kernel 2.6.24-16-generic (recovery mode)
root (hd0,0)
kernel /boot/vmlinuz-2.6.24-16-generic root=UUID=3d25de7d-f45e-4916-981d-4f8b8e8c6ea9 ro single
initrd /boot/initrd.img-2.6.24-16-generic

title Ubuntu 10.04.1 LTS, kernel 2.6.22-14-generic
root (hd0,0)
kernel /boot/vmlinuz-2.6.22-14-generic root=UUID=3d25de7d-f45e-4916-981d-4f8b8e8c6ea9 ro quiet splash
initrd /boot/initrd.img-2.6.22-14-generic
quiet

title Ubuntu 10.04.1 LTS, kernel 2.6.22-14-generic (recovery mode)
root (hd0,0)
kernel /boot/vmlinuz-2.6.22-14-generic root=UUID=3d25de7d-f45e-4916-981d-4f8b8e8c6ea9 ro single
initrd /boot/initrd.img-2.6.22-14-generic

title Ubuntu 10.04.1 LTS, kernel 2.6.20-16-generic
root (hd0,0)
kernel /boot/vmlinuz-2.6.20-16-generic root=UUID=3d25de7d-f45e-4916-981d-4f8b8e8c6ea9 ro quiet splash
initrd /boot/initrd.img-2.6.20-16-generic
quiet

title Ubuntu 10.04.1 LTS, kernel 2.6.20-16-generic (recovery mode)
root (hd0,0)
kernel /boot/vmlinuz-2.6.20-16-generic root=UUID=3d25de7d-f45e-4916-981d-4f8b8e8c6ea9 ro single
initrd /boot/initrd.img-2.6.20-16-generic

title Ubuntu 10.04.1 LTS, memtest86+
root (hd0,0)
kernel /boot/memtest86+.bin
quiet

### END DEBIAN AUTOMAGIC KERNELS LIST

=============================== sdb1/etc/fstab: ===============================

# /etc/fstab: static file system information.
#
# -- This file has been automaticly generated by ntfs-config --
#
# <file system> <mount point> <type> <options> <dump> <pass>

proc /proc proc defaults 0 0
# Entry for /dev/sda1 :
UUID=3d25de7d-f45e-4916-981d-4f8b8e8c6ea9 / ext3 nouser,defaults,errors=remount-ro,atime,auto,rw,dev,exec,suid 0 1
# Entry for /dev/sda5 :
UUID=3a1a7fa1-76ee-402e-8ae0-4fc6bde0bed0 none swap sw 0 0
/dev/hdc /media/cdrom0 udf,iso9660 user,atime,noauto,rw,dev,exec,suid 0 0
/dev/fd0 /media/floppy0 auto user,atime,noauto,rw,dev,exec,suid 0 0
/dev/hdb1 /60GB ext3 auto,user 0 0
/dev/hda1 <mount\040point> auto user,noauto,atime,rw,nodev,noexec,nosuid 0 0

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


143.5GB: boot/grub/menu.lst
89.4GB: boot/grub/stage2
91.8GB: boot/initrd.img-2.6.20-16-generic
89.4GB: boot/initrd.img-2.6.20-16-generic.bak
140.0GB: boot/initrd.img-2.6.22-14-generic
136.8GB: boot/initrd.img-2.6.22-14-generic.bak
139.0GB: boot/initrd.img-2.6.24-16-generic
91.8GB: boot/initrd.img-2.6.24-16-generic.bak
139.0GB: boot/initrd.img-2.6.24-17-generic
138.9GB: boot/initrd.img-2.6.24-17-generic.bak
90.7GB: boot/initrd.img-2.6.24-18-generic
90.1GB: boot/initrd.img-2.6.24-18-generic.bak
8.0GB: boot/initrd.img-2.6.24-19-generic
89.5GB: boot/initrd.img-2.6.24-19-generic.bak
147.1GB: boot/initrd.img-2.6.24-21-generic
105.7GB: boot/initrd.img-2.6.24-21-generic.bak
25.3GB: boot/initrd.img-2.6.24-22-generic
105.3GB: boot/initrd.img-2.6.24-22-generic.bak
93.5GB: boot/initrd.img-2.6.24-23-generic
90.4GB: boot/initrd.img-2.6.24-23-generic.bak
147.0GB: boot/initrd.img-2.6.24-24-generic
134.4GB: boot/initrd.img-2.6.24-24-generic.bak
90.4GB: boot/initrd.img-2.6.31-22-generic
154.2GB: boot/initrd.img-2.6.32-26-generic
89.8GB: boot/vmlinuz-2.6.20-16-generic
138.8GB: boot/vmlinuz-2.6.22-14-generic
91.3GB: boot/vmlinuz-2.6.24-16-generic
89.5GB: boot/vmlinuz-2.6.24-17-generic
139.1GB: boot/vmlinuz-2.6.24-18-generic
21.4GB: boot/vmlinuz-2.6.24-19-generic
91.3GB: boot/vmlinuz-2.6.24-21-generic
123.4GB: boot/vmlinuz-2.6.24-22-generic
89.5GB: boot/vmlinuz-2.6.24-23-generic
99.3GB: boot/vmlinuz-2.6.24-24-generic
144.9GB: boot/vmlinuz-2.6.31-22-generic
90.4GB: boot/vmlinuz-2.6.32-26-generic
154.2GB: initrd.img
90.4GB: initrd.img.old
90.4GB: vmlinuz
144.9GB: vmlinuz.old

Quackers
February 22nd, 2011, 10:17 PM
More details would be nice :-)
Which partition has been resized with gparted, for instance? Was the Ubuntu system booted when the partition was resized?

drs305
February 22nd, 2011, 10:21 PM
Your Grub2 is looking for partition 6, which no longer exists.

Boot the LiveCD and run these commands. It will mount your real Ubuntu partition (sda1) and then put Grub2 in the MBR and point it to sda1:


sudo mount /dev/sda1 /mnt
sudo grub-install --root-directory=/mnt /dev/sda

Do not use the partition number in the second command.

Reboot and it should boot your sda1 Ubuntu installation.

justins1983
February 22nd, 2011, 10:47 PM
More details would be nice :-)
Which partition has been resized with gparted, for instance? Was the Ubuntu system booted when the partition was resized?

I deleted a partition, reduced the size of swap partition and resized sda1 to include the new free space. I did this from ubuntu live cd.


Your Grub2 is looking for partition 6, which no longer exists.

Boot the LiveCD and run these commands. It will mount your real Ubuntu partition (sda1) and then put Grub2 in the MBR and point it to sda1:


sudo mount /dev/sda1 /mnt
sudo grub-install --root-directory=/mnt /dev/sda

Do not use the partition number in the second command.

Reboot and it should boot your sda1 Ubuntu installation.

No luck, rebooted and got a blank screen. I will try again.

drs305
February 22nd, 2011, 11:19 PM
I deleted a partition, reduced the size of swap partition and resized sda1 to include the new free space. I did this from ubuntu live cd.

No luck, rebooted and got a blank screen. I will try again.

A grub failure won't produce a blank screen. It will provide an error message of some sort produced by BIOS, a "grub" or a "grub rescue" prompt. You could try holding down the SHIFT key to see if a Grub menu appears. If it does, it probably means you are having an issue after Grub passes control to the OS. Grub would give you an error message but the OS may not.

If you have a blinking cursor in the upper left corner of the screen it could be a video issue, but since this all happened after resizing the chances are it is something else.

justins1983
February 23rd, 2011, 12:37 AM
I removed the other drive and ran the boot info script again.


Boot Info Script 0.55 dated February 15th, 2010

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

=> Grub 2 is installed in the MBR of /dev/sda and looks on the same drive in
partition #1 for /boot/grub.

sda1: __________________________________________________ _______________________

File system: ext4
Boot sector type: -
Boot sector info:
Operating System: Ubuntu 10.10
Boot files/dirs: /boot/grub/grub.cfg /etc/fstab /boot/grub/core.img

sda2: __________________________________________________ _______________________

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

=========================== 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 End Size Id System

/dev/sda1 * 63 1,951,297,533 1,951,297,471 83 Linux
/dev/sda2 1,951,297,534 1,953,520,064 2,222,531 82 Linux swap / Solaris


blkid -c /dev/null: __________________________________________________ __________

Device UUID TYPE LABEL

/dev/loop0 squashfs
/dev/sda1 56a68319-2b33-4324-9520-4e75cca2e6c4 ext4
/dev/sda2 21626f1d-91d8-4e58-8232-7008371f77bf swap /dev/sda5
/dev/sda: PTTYPE="dos"

============================ "mount | grep ^/dev output: ===========================

Device Mount_Point Type Options

aufs / aufs (rw)
/dev/sr0 /cdrom iso9660 (ro,noatime)
/dev/loop0 /rofs squashfs (ro,noatime)


=========================== 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 part_msdos
insmod ext2
set root='(hd0,msdos1)'
search --no-floppy --fs-uuid --set 56a68319-2b33-4324-9520-4e75cca2e6c4
if loadfont /usr/share/grub/unicode.pf2 ; then
set gfxmode=640x480
load_video
insmod gfxterm
fi
terminal_output gfxterm
insmod part_msdos
insmod ext2
set root='(hd0,msdos1)'
search --no-floppy --fs-uuid --set 56a68319-2b33-4324-9520-4e75cca2e6c4
set locale_dir=($root)/boot/grub/locale
set lang=en
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.35-25-generic' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod part_msdos
insmod ext2
set root='(hd0,msdos1)'
search --no-floppy --fs-uuid --set 56a68319-2b33-4324-9520-4e75cca2e6c4
linux /boot/vmlinuz-2.6.35-25-generic root=UUID=56a68319-2b33-4324-9520-4e75cca2e6c4 ro quiet splash
initrd /boot/initrd.img-2.6.35-25-generic
}
menuentry 'Ubuntu, with Linux 2.6.35-25-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod part_msdos
insmod ext2
set root='(hd0,msdos1)'
search --no-floppy --fs-uuid --set 56a68319-2b33-4324-9520-4e75cca2e6c4
echo 'Loading Linux 2.6.35-25-generic ...'
linux /boot/vmlinuz-2.6.35-25-generic root=UUID=56a68319-2b33-4324-9520-4e75cca2e6c4 ro single
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-2.6.35-25-generic
}
menuentry 'Ubuntu, with Linux 2.6.35-24-generic' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod part_msdos
insmod ext2
set root='(hd0,msdos1)'
search --no-floppy --fs-uuid --set 56a68319-2b33-4324-9520-4e75cca2e6c4
linux /boot/vmlinuz-2.6.35-24-generic root=UUID=56a68319-2b33-4324-9520-4e75cca2e6c4 ro quiet splash
initrd /boot/initrd.img-2.6.35-24-generic
}
menuentry 'Ubuntu, with Linux 2.6.35-24-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod part_msdos
insmod ext2
set root='(hd0,msdos1)'
search --no-floppy --fs-uuid --set 56a68319-2b33-4324-9520-4e75cca2e6c4
echo 'Loading Linux 2.6.35-24-generic ...'
linux /boot/vmlinuz-2.6.35-24-generic root=UUID=56a68319-2b33-4324-9520-4e75cca2e6c4 ro single
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-2.6.35-24-generic
}
menuentry 'Ubuntu, with Linux 2.6.35-22-generic' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod part_msdos
insmod ext2
set root='(hd0,msdos1)'
search --no-floppy --fs-uuid --set 56a68319-2b33-4324-9520-4e75cca2e6c4
linux /boot/vmlinuz-2.6.35-22-generic root=UUID=56a68319-2b33-4324-9520-4e75cca2e6c4 ro quiet splash
initrd /boot/initrd.img-2.6.35-22-generic
}
menuentry 'Ubuntu, with Linux 2.6.35-22-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod part_msdos
insmod ext2
set root='(hd0,msdos1)'
search --no-floppy --fs-uuid --set 56a68319-2b33-4324-9520-4e75cca2e6c4
echo 'Loading Linux 2.6.35-22-generic ...'
linux /boot/vmlinuz-2.6.35-22-generic root=UUID=56a68319-2b33-4324-9520-4e75cca2e6c4 ro single
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-2.6.35-22-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='(hd0,msdos1)'
search --no-floppy --fs-uuid --set 56a68319-2b33-4324-9520-4e75cca2e6c4
linux16 /boot/memtest86+.bin
}
menuentry "Memory test (memtest86+, serial console 115200)" {
insmod part_msdos
insmod ext2
set root='(hd0,msdos1)'
search --no-floppy --fs-uuid --set 56a68319-2b33-4324-9520-4e75cca2e6c4
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=56a68319-2b33-4324-9520-4e75cca2e6c4 / ext4 errors=remount-ro 0 1
# swap was on /dev/sda5 during installation
UUID=0f24b1b0-c481-4ef5-941b-7b4fb00a957f none swap sw 0 0

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


59.0GB: boot/grub/core.img
8.0GB: boot/grub/grub.cfg
.9GB: boot/initrd.img-2.6.35-22-generic
99.5GB: boot/initrd.img-2.6.35-24-generic
66.8GB: boot/initrd.img-2.6.35-25-generic
58.1GB: boot/vmlinuz-2.6.35-22-generic
58.1GB: boot/vmlinuz-2.6.35-24-generic
58.1GB: boot/vmlinuz-2.6.35-25-generic
66.8GB: initrd.img
99.5GB: initrd.img.old
58.1GB: vmlinuz
58.1GB: vmlinuz.old

[QUOTE=drs305;10484459]A grub failure won't produce a blank screen. It will provide an error message of some sort produced by BIOS, a "grub" or a "grub rescue" prompt. You could try holding down the SHIFT key to see if a Grub menu appears. If it does, it probably means you are having an issue after Grub passes control to the OS. Grub would give you an error message but the OS may not.

If you have a blinking cursor in the upper left corner of the screen it could be a video issue, but since this all happened after resizing the chances are it is something else.[/QUOTE

Shift does nothing, its just a blank screen.

Safex
April 24th, 2011, 12:41 AM
Thank you this worked!


sudo mount /dev/sda1 /mnt
sudo grub-install --root-directory=/mnt /dev/sda

I changed my default os in grub with startup manager, and got the no such partition error after restart. So I booted from LiveCD checked which partition was the root on (in my case sda9) then changed the sda1 to sda9 using the code above and it worked, thank you!