PDA

View Full Version : [ubuntu] Boot Problem on New installation



burobaaje
May 24th, 2011, 06:48 AM
I used a USB drive to install ubuntu 10.04 on a HP Mini 5102's internal HD and all works fine, except when I shut down completely, it won't cold boot from the Mini's internal HD unless the USB drive is attached. With the USB drive attached, it boots directly off the HP's internal HD. I can eject the USB drive and the system runs great. It can sleep and resume and run any and all installed programs.

If the USB drive is not attached from a cold boot it goes through some sort of test and then says "No System Disk Found".

How can I get the system to boot from HD without USB drive attached?

Hedgehog1
May 24th, 2011, 10:19 AM
It sounds like you installed the grub boot loader onto the USB drive rather than your internal drive.

To give us a look at your install please do this:

http://bootinfoscript.sourceforge.net/
Follow the instruction on the website and post the results here.

Please press the '#' button when posting and place the the script results between the
& tags.

http://img854.imageshack.us/img854/4563/codetags.png


The Hedge

:KS

burobaaje
May 24th, 2011, 10:47 AM
Here are the results. Note that the netbook was booted with the USB Drive attached. The USB drive is the same drive that I used to install ubuntu. I simply followed the instructions. But may have missed something.

Thanks for helping!






Boot Info Script 0.60 from 17 May 2011


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

=> No boot loader is installed in the MBR of /dev/sdb.

sdb1: __________________________________________________ ________________________

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

sdb2: __________________________________________________ ________________________

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

sdb5: __________________________________________________ ________________________

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

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

Drive: sdb __________________________________________________ ___________________

Disk /dev/sdb: 320.1 GB, 320072933376 bytes
255 heads, 63 sectors/track, 38913 cylinders, total 625142448 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 613,146,623 613,144,576 83 Linux
/dev/sdb2 613,148,670 625,141,759 11,993,090 5 Extended
/dev/sdb5 613,148,672 625,141,759 11,993,088 82 Linux swap / Solaris


"blkid" output: __________________________________________________ ______________

Device UUID TYPE LABEL

/dev/sdb1 35da0c8e-eeb2-4e9a-b7a3-6826dbbc6f11 ext4
/dev/sdb5 29beec89-a32c-4d9d-aef1-a46be19b269e swap

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

Device Mount_Point Type Options

/dev/sdb1 / ext4 (rw,errors=remount-ro)


=========================== sdb1/boot/grub/grub.cfg: ===========================

--------------------------------------------------------------------------------
#
# 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,1)'
search --no-floppy --fs-uuid --set 35da0c8e-eeb2-4e9a-b7a3-6826dbbc6f11
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,1)'
search --no-floppy --fs-uuid --set 35da0c8e-eeb2-4e9a-b7a3-6826dbbc6f11
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.32-31-generic' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod ext2
set root='(hd0,1)'
search --no-floppy --fs-uuid --set 35da0c8e-eeb2-4e9a-b7a3-6826dbbc6f11
linux /boot/vmlinuz-2.6.32-31-generic root=UUID=35da0c8e-eeb2-4e9a-b7a3-6826dbbc6f11 ro quiet splash
initrd /boot/initrd.img-2.6.32-31-generic
}
menuentry 'Ubuntu, with Linux 2.6.32-31-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod ext2
set root='(hd0,1)'
search --no-floppy --fs-uuid --set 35da0c8e-eeb2-4e9a-b7a3-6826dbbc6f11
echo 'Loading Linux 2.6.32-31-generic ...'
linux /boot/vmlinuz-2.6.32-31-generic root=UUID=35da0c8e-eeb2-4e9a-b7a3-6826dbbc6f11 ro single
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-2.6.32-31-generic
}
menuentry 'Ubuntu, with Linux 2.6.32-21-generic' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod ext2
set root='(hd0,1)'
search --no-floppy --fs-uuid --set 35da0c8e-eeb2-4e9a-b7a3-6826dbbc6f11
linux /boot/vmlinuz-2.6.32-21-generic root=UUID=35da0c8e-eeb2-4e9a-b7a3-6826dbbc6f11 ro quiet splash
initrd /boot/initrd.img-2.6.32-21-generic
}
menuentry 'Ubuntu, with Linux 2.6.32-21-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod ext2
set root='(hd0,1)'
search --no-floppy --fs-uuid --set 35da0c8e-eeb2-4e9a-b7a3-6826dbbc6f11
echo 'Loading Linux 2.6.32-21-generic ...'
linux /boot/vmlinuz-2.6.32-21-generic root=UUID=35da0c8e-eeb2-4e9a-b7a3-6826dbbc6f11 ro single
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-2.6.32-21-generic
}
### END /etc/grub.d/10_linux ###

### BEGIN /etc/grub.d/20_memtest86+ ###
menuentry "Memory test (memtest86+)" {
insmod ext2
set root='(hd0,1)'
search --no-floppy --fs-uuid --set 35da0c8e-eeb2-4e9a-b7a3-6826dbbc6f11
linux16 /boot/memtest86+.bin
}
menuentry "Memory test (memtest86+, serial console 115200)" {
insmod ext2
set root='(hd0,1)'
search --no-floppy --fs-uuid --set 35da0c8e-eeb2-4e9a-b7a3-6826dbbc6f11
linux16 /boot/memtest86+.bin console=ttyS0,115200n8
}
### END /etc/grub.d/20_memtest86+ ###

### BEGIN /etc/grub.d/30_os-prober ###
if [ ${timeout} != -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 ###
--------------------------------------------------------------------------------

=============================== sdb1/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/sdb1 during installation
UUID=35da0c8e-eeb2-4e9a-b7a3-6826dbbc6f11 / ext4 errors=remount-ro 0 1
# swap was on /dev/sdb5 during installation
UUID=29beec89-a32c-4d9d-aef1-a46be19b269e none swap sw 0 0
--------------------------------------------------------------------------------

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

GiB - GB File Fragment(s)

64.133579254 = 68.862906368 boot/grub/core.img 1
218.595550537 = 234.715185152 boot/grub/grub.cfg 1
64.140998840 = 68.870873088 boot/initrd.img-2.6.32-21-generic 1
64.203323364 = 68.937793536 boot/initrd.img-2.6.32-31-generic 1
64.132167816 = 68.861390848 boot/vmlinuz-2.6.32-21-generic 1
64.144767761 = 68.874919936 boot/vmlinuz-2.6.32-31-generic 1
64.203323364 = 68.937793536 initrd.img 1
64.140998840 = 68.870873088 initrd.img.old 1
64.144767761 = 68.874919936 vmlinuz 1
64.132167816 = 68.861390848 vmlinuz.old 1

======================== Unknown MBRs/Boot Sectors/etc: ========================

Unknown BootLoader on sdb2

00000000 ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff |................|
*
000001b0 ff ff ff ff ff ff ff ff ff ff ff ff ff ff 00 fe |................|
000001c0 ff ff 82 fe ff ff 02 00 00 00 00 00 b7 00 00 00 |................|
000001d0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................|
*
000001f0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 55 aa |..............U.|
00000200

Hedgehog1
May 25th, 2011, 04:32 AM
Please boot off your LiveUSB, select 'TRY'

In the Terminal (Menu to: Applications >> Accessories >> Terminal):


sudo mount /dev/sdb1 /mnt

sudo grub-install --root-directory=/mnt /dev/sdb

Then power down and remove the LiveUSB. Power up and you should be booting off the internal drive.


The Hedge

:KS

burobaaje
May 25th, 2011, 11:35 AM
Thanks Hedge,

Results:

When I start the computer with LiveUSB, I get option to boot from LiveUSB or the HP's HD. No matter which one I choose it boots using the LiveUSB but completes boot from HP's HD. I can remove the LiveUSB and all is well

I am never given a choice of TRY or booting exclusively from the LiveUSB.

I tried selecting both options and the result is the same.

I went ahead and installed grub on sdb and did not get error msg, but no change.

FYI I made the LiveUSB using LiLi USB Creator. Could there be code in there that causes a problem.

If the LiveUSB is not plugged in on cold boot, it immediately goes to Yukon PXE Pre-boot execution environment and after a minute give the msg "Non-System Disk or disk error"

I then remade the LiveUSB and reinstalled and the results going through all you suggested were the same.

The bright side: I made the last LiveUSB with a small USB stick and it does serve to prevent anyone from booting the computer unless they have it :) May as well look on the bright side.

Dudley

mhopeng
January 11th, 2012, 03:20 PM
I know this is an old thread, but just for completeness, I had the same issue, and the problem was as described here- the USB installer defaults to installing grub on the USB key, not on the HD (at least in some situations). So, at the very last step in the install, click on the "Advanced" button and change the location of the grub install to your harddrive.

Mark Phelps
January 12th, 2012, 02:36 PM
Actually, the problem is more generic...

The GRUB installer defaults to the "first" hard drive it sees.

When booting from USB, it's not unusual for the USB drive to be mounted as the "first" drive.

So basically, GRUB is behaving normally.

Problem is, most folks aren't aware of this.

What SHOULD happen, is that the installer should detect that it is installing to a USB drive and offer a CHOICE as to WHERE to install GRUB -- but that would be asking too much, wouldn't it.