LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 08-30-2009, 09:19 AM   #1
cheshirex
LQ Newbie
 
Registered: Aug 2009
Distribution: Ubuntu 9.04
Posts: 11

Rep: Reputation: 1
After Ubuntu 9.04 install, getting "DISK BOOT FAILURE"


I've been playing with Ubuntu for a little bit before, and since we now have a separate computer for the Windows-dependent, and a brand new HD (both my HDs are SATA, if that makes a difference), I decided to do a clean Ubuntu install and leave everything else off of the system.

I've installed 9.04 from an amd64 live install CD. The install CD worked fine, but when I try to boot the system, I get the standard "DISK BOOT FAILURE..." message which indicates that the computer can't find anything to boot off of. If I insert the live CD and then select "Boot off of first hard disk", then the computer boots up just fine.

On trying to figure this out for myself, most similar errors Google found indicate that Grub needs to be reinstalled. So I tried two slightly different solutions I found. I tried

Code:
sudo grub-install /dev/sda
It seemed to succeed, but when I rebooted, I got the same error message. The other solution I tried was to start grub's interface and issued:

Code:
find /grub/stage1
which returned (hd0,0)

So I issued

Code:
root (hd0,0)
setup (hd0)
Again, everything seemed to work, but again, when I rebooted, no change.

I couldn't find anything via Google that seemed to address this, and I'm out of ideas to figure this out. My computer functions as long as I boot off of the live CD and select "Boot off of first hard drive", but I'd really rather remove that dependency. Can anyone help please?

(I did post this question on ubuntuforums.org before, but haven't gotten any responses that lead anywhere there.)

Thanks!
 
Old 08-30-2009, 09:52 AM   #2
mdg
Member
 
Registered: Sep 2003
Distribution: Slackware
Posts: 626

Rep: Reputation: 38
Do you have a menu.lst file correctly configured in your grub directory?
 
Old 08-30-2009, 01:29 PM   #3
VipX1
Member
 
Registered: Jun 2009
Location: Dublin, IRL
Distribution: Ubuntu Budgie
Posts: 36
Blog Entries: 1

Rep: Reputation: 15
Quote:
Originally Posted by cheshirex View Post
If I insert the live CD and then select "Boot off of first hard disk", then the computer boots up just fine.
Just a thought I had, is the case that the Motherboard is set to boot from the CD drive ONLY and Disk 0 (the master hard drive) is not listed in the "Boot Device Priority" menu in the motherboard BIOS. Then you would get the Error when NO CD was in the CD drive because the motherboard would not move on to the second boot device, in this case Disk 0. It would work as you said above with the CD in the drive.

Go into the m/board BIOS and check either "Boot Menu" or "Boot device priority"
You should have the CD drive 1st and then Disk 0 2nd, 3rd removable device or something (not important, a 3rd device isn't available usually )

Last edited by VipX1; 08-30-2009 at 01:32 PM.
 
Old 08-31-2009, 02:56 AM   #4
cheshirex
LQ Newbie
 
Registered: Aug 2009
Distribution: Ubuntu 9.04
Posts: 11

Original Poster
Rep: Reputation: 1
mdg, I do have menu.lst in place, and it seems sane enough to me. (Besides, if it wasn't correct, wouldn't grub give an error message of some sort? This error says to me that the computer isn't seeing the boot drive at all, whereas I would think a bad or missing menu.lst would give a different error.)

VipX1, I double-checked the BIOS settings, and the boot priority is set to "CDROM", "Hard Drive", then "Removable". The BIOS also definitely sees the HD (it reports the HD settings correctly on boot and in the BIOS setup, anyway).

Any other possibilities?

Thanks!
 
Old 08-31-2009, 11:38 AM   #5
mdg
Member
 
Registered: Sep 2003
Distribution: Slackware
Posts: 626

Rep: Reputation: 38
There's a small bash script at Sourceforge which will check what's in the MBR, how your drives are setup, etc. It's for troubleshooting boot problems,
it might shed some light on the problem.

Just run it in a console as root:
Code:
sh boot_info_script032.sh
 
Old 08-31-2009, 12:29 PM   #6
tredegar
LQ 5k Club
 
Registered: May 2003
Location: London, UK
Distribution: Fedora38
Posts: 6,147

Rep: Reputation: 435Reputation: 435Reputation: 435Reputation: 435Reputation: 435
Quote:
"DISK BOOT FAILURE..."
Means grub didn't run.

I'll second the usefulness of boot_info_script - it digs around and finds all the gory details for you. It'll take you a while to read through the output, but your answer is likely to be there.
 
Old 08-31-2009, 12:34 PM   #7
amani
Senior Member
 
Registered: Jul 2006
Location: Kolkata, India
Distribution: Debian 64-bit GNU/Linux, Kubuntu64, Fedora QA, Slackware,
Posts: 2,766

Rep: Reputation: Disabled
Otherwise check with parted magic CD.

can this be due to an unclean partition?
 
Old 09-01-2009, 03:31 AM   #8
cheshirex
LQ Newbie
 
Registered: Aug 2009
Distribution: Ubuntu 9.04
Posts: 11

Original Poster
Rep: Reputation: 1
Here's the output from boot_info_script032.sh (in the attached file).

Oddly enough, it reports my second drive as being a Windows boot drive, but I don't think that drive ever was such. (It was used for data storage, and I haven't gotten around to converting it from NTFS yet, but the old drive that I used to boot Windows off of died and is en route for a warranty replacement.)

The traces of LILO are from a friend who suggested that I try installing LILO instead of Grub to see if it resolves the problem (obviously it didn't).

I've gone over the output myself, and haven't seen anything that obviously shouts out "Here's the problem!".

amani: I don't expect it's an unclean partition. My boot drive is new, passed Spinrite testing, and was partitioned and set up by Ubuntu installation.
Attached Files
File Type: txt RESULTS1.txt (19.0 KB, 20 views)
 
Old 09-01-2009, 01:03 PM   #9
mdg
Member
 
Registered: Sep 2003
Distribution: Slackware
Posts: 626

Rep: Reputation: 38
From your results file:
Code:
/dev/sda1: UUID="bc8937a6-76d6-4de9-8d91-5b2d2f337747" TYPE="ext4" 
/dev/sda5: UUID="86957342-2534-4cac-ad1b-6ee07b3500c0" TYPE="swap" 
/dev/sda6: UUID="a9aeb29c-9c12-4f78-bd82-cfb39fa272e7" TYPE="ext4" 
/dev/sdb1: UUID="0AA06346A063377B" LABEL="Drive2" TYPE="ntfs"
From your sda1 menu.lst:
Code:
title		Ubuntu 9.04, kernel 2.6.28-15-generic
uuid		bc8937a6-76d6-4de9-8d91-5b2d2f337747
kernel		/vmlinuz-2.6.28-15-generic root=UUID=a9aeb29c-9c12-4f78-bd82-cfb39fa272e7 ro quiet splash 
initrd		/initrd.img-2.6.28-15-generic
quiet
The root drive in menu.lst is designated as sda6. Grub is booting sda1 but is trying to use the kernel from sda6.

Also, you have the "hiddenmenu" option enabled in menu.lst. This won't stop grub from working, but you won't see the menu.
 
Old 09-02-2009, 01:32 AM   #10
cheshirex
LQ Newbie
 
Registered: Aug 2009
Distribution: Ubuntu 9.04
Posts: 11

Original Poster
Rep: Reputation: 1
mdg, I tried modifying this by changing the root UUID to match sda1's UUID (and commenting out hiddenmenu), but it didn't help. It still got the same error message.

When I then booted off of the CD, and told it to boot off of the first HD, I did see the grub menu, but grub failed to boot the kernel. So it looks like booting off of the CD and telling it to use my first HD causes grub to start the way I would expect it to by simply booting without the CD. Changing the root UUID seems (at a guess) to indicate that that should be the filesystem root, not the root of the boot partition. Maybe I should have stuck with having a single partition instead of separating my boot partition... (although it would have reduced complication, I'm not sure it would have solved this issue). Bleah.

So it looks like my BIOS isn't seeing the grub installation at all...
 
Old 09-02-2009, 03:25 AM   #11
mdg
Member
 
Registered: Sep 2003
Distribution: Slackware
Posts: 626

Rep: Reputation: 38
Try using the traditional grub labels, ie: comment out your main Ubuntu entry in your menu.lst and put in an entry with hd0.
Code:
title		Ubuntu 9.04, grub-label
root		(hd0,0)
kernel		/vmlinuz-2.6.28-15-generic root=UUID=bc8937a6-76d6-4de9-8d91-5b2d2f337747 ro quiet splash 
initrd		/initrd.img-2.6.28-15-generic
quiet

#title		Ubuntu 9.04, kernel 2.6.28-15-generic
#uuid		bc8937a6-76d6-4de9-8d91-5b2d2f337747
#kernel		/vmlinuz-2.6.28-15-generic root=UUID=bc8937a6-76d6-4de9-8d91-5b2d2f337747 ro quiet splash 
#initrd		/initrd.img-2.6.28-15-generic
#quiet
 
Old 09-03-2009, 06:49 AM   #12
cheshirex
LQ Newbie
 
Registered: Aug 2009
Distribution: Ubuntu 9.04
Posts: 11

Original Poster
Rep: Reputation: 1
mdg, I'm certain we're not approaching the problem correctly.

The problem is that grub isn't starting at all. The menu.lst file isn't being processed, so no amount of changes to it will help me here.

My understanding of the boot process is that the BIOS reads the MBR of the first HD to figure out how to boot. Grub is written to the MBR, but the BIOS isn't recognizing it somehow.

(I did try your recommendation, just to be sure -- no effect.)

What could be causing this?

Thanks!
 
Old 09-03-2009, 06:58 AM   #13
cheshirex
LQ Newbie
 
Registered: Aug 2009
Distribution: Ubuntu 9.04
Posts: 11

Original Poster
Rep: Reputation: 1
On re-reading my own post, I think I've answered my own question. The problem must be with the BIOS, not the drive, since the drive seems to be responding correctly when something does try to boot off of it.

I want to be careful how I handle this, but I'm going to see if I can, after backing up current settings, update my BIOS or clear its settings, and start it from scratch.
 
Old 09-03-2009, 01:07 PM   #14
cheshirex
LQ Newbie
 
Registered: Aug 2009
Distribution: Ubuntu 9.04
Posts: 11

Original Poster
Rep: Reputation: 1
Problem solved!

It turns out my machine's BIOS is smarter than I gave it credit for. Apparently it knew what drives I had in my system before, and kept track of that. Well, I used to have two 250GB drives. One of those (the boot drive) failed, and I took it out and sent it in for warranty replacement -- and bought a new 500GB drive to use in addition. The new drive is the new boot drive.

Well, in addition to the boot device priority list (which is used to determine whether to boot off of a CD or the HD), the BIOS has another boot priority list that it maintains. It saw that the second HD had been in place before, so that drive had a higher boot priority than the new drive, even though the new drive was hooked up as the first SATA device.

So all this time, when I've been booting via the Live CD, and choosing "Boot off of first hard drive", it was literally booting off of the first hard drive -- but when I booted directly, the BIOS was trying to boot off of the second hard drive. Once I spotted this priority list, I was able to modify it so the new drive has priority, and voila -- everything works.

Thanks for the help!
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Stuck on "GRUB_" Screen - Will boot from Live CD "Boot from first hard disk" option Snowman11 Linux - Newbie 10 02-01-2009 06:52 PM
uninstall boot loader "Lilo" install "Grub" sethis Linux - Newbie 6 11-30-2006 09:32 AM
"Successful install" results in "Boot device not found" slackr007 Linux - Newbie 2 05-31-2005 08:02 PM
"Disk boot failure..." after lilo writes to the MBR alexko Linux - Hardware 6 11-16-2004 09:43 AM
"Disk boot failure. Enter system disk and press enter" Fear58 Linux - Hardware 3 06-25-2004 05:17 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 02:02 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration