grub2 error on grub-probe, does not boot

Bug #190147 reported by aleneguou
26
This bug affects 1 person
Affects Status Importance Assigned to Milestone
grub2 (Debian)
Fix Released
Unknown
grub2 (Ubuntu)
Fix Released
Undecided
Unassigned

Bug Description

Binary package hint: grub2

With the latest version of grub2, update-grub reports:

grub-probe: error: Cannot get the real path of `/dev/sda'

And if I use grub2 via the grub chainloader, it repeatedly prints "Syntax error" and does not boot.

I have an internal IDE hard drive.

ProblemType: Bug
Architecture: i386
Date: Fri Feb 8 05:44:57 2008
DistroRelease: Ubuntu 8.04
NonfreeKernelModules: nvidia
Package: grub2 1.96+20080203-1
PackageArchitecture: i386
SourcePackage: grub2
Uname: Linux wobbly 2.6.24-7-generic #1 SMP Thu Feb 7 01:29:58 UTC 2008 i686 GNU/Linux

Tags: apport-bug
Revision history for this message
aleneguou (alexandergould) wrote :
Revision history for this message
Matteo Croce (teknoraver) wrote :

edit /boot/grub/grub.cfg and modify this code:

if font (hd0,2)/grub/unifont.pff ; then
  set gfxmode=640x480
  insmod gfxterm
  insmod vbe
  terminal gfxterm
fi

with the right one:

set gfxmode=640x480
insmod gfxterm
insmod vbe
terminal gfxterm

Changed in grub2:
status: New → Confirmed
Revision history for this message
Matteo Croce (teknoraver) wrote :

Seems that Debian has this bug too: http://bugs.debian.org/464464

Revision history for this message
Matteo Croce (teknoraver) wrote :

*i missed a line

edit /boot/grub/grub.cfg and modify this code:

if font (hd0,2)/grub/unifont.pff ; then
   set gfxmode=640x480
   insmod gfxterm
   insmod vbe
   terminal gfxterm
 fi

with the right one:

font (hd0,2)/grub/unifont.pff
set gfxmode=640x480
insmod gfxterm
insmod vbe
terminal gfxterm

Revision history for this message
Matteo Croce (teknoraver) wrote :
Revision history for this message
Tormod Volden (tormodvolden) wrote :

Please try what was suggested in the Debian bug report:
"This is a bug in GRUB itself not grub.cfg. Just (re-)run grub-install."

Changed in grub2:
status: Unknown → Fix Released
Revision history for this message
aleneguou (alexandergould) wrote :

This error comes up on installing the 2.6.24-10-generic kernel.

Setting up linux-image-2.6.24-10-generic (2.6.24-10.16) ...
Running depmod.
update-initramfs: Generating /boot/initrd.img-2.6.24-10-generic
The provided postinst hook script [/usr/sbin/update-grub] could not be run.
dpkg: error processing linux-image-2.6.24-10-generic (--configure):
 subprocess post-installation script returned error exit status 2

If I run:
# update-grub
grub-probe: error: Cannot get the real path of `/dev/hda'

I tried what Tormod Volden suggests above:
# grub-install /dev/hda
and get the same error.

Revision history for this message
Tormod Volden (tormodvolden) wrote :

What I suggested above was for the other bug: You reported two bugs in one report, which ends up in confusion...

Can you please run: bash -x /usr/sbin/update-grub > update-grub.txt 2>&1
and attach the file update-grub.txt?

Revision history for this message
Tormod Volden (tormodvolden) wrote :

I noticed in your original report it was /dev/sda, and now it is /dev/hda. Is this correct? What does "df /" say?

Revision history for this message
aleneguou (alexandergould) wrote :

df / reports
Filesystem 1K-blocks Used Available Use% Mounted on
/dev/sda1 191802332 46414436 135644880 26% /

(however, running grub-install /dev/sda results in the same error)

I have attached the file you requested.

Revision history for this message
Luite van Zelst (luitevanzelst) wrote :

Does it help at all to run "grub-mkdevicemap" begore running "update-grub" ?
Is the content of /boot/grub/device.map ok?

Revision history for this message
Greg A (etulfetulf) wrote :

This should be fixed in Ubuntu Intrepid. Please could someone confirm?

Revision history for this message
Andreas Moog (ampelbein) wrote :

Issue did not get more reports, setting to FixReleased.

Changed in grub2 (Ubuntu):
status: Confirmed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.