[Bug 499849] Re: "Failed to boot default entries." with grub-efi-amd64 upon reboot on HP 8530p with UEFI enabled

Launchpad Bug Tracker 499849 at bugs.launchpad.net
Tue May 5 05:30:57 UTC 2020


[Expired for grub2 (Ubuntu) because there has been no activity for 60
days.]

** Changed in: grub2 (Ubuntu)
       Status: Incomplete => Expired

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to grub2 in Ubuntu.
https://bugs.launchpad.net/bugs/499849

Title:
  "Failed to boot default entries." with grub-efi-amd64 upon reboot on
  HP 8530p with UEFI enabled

Status in grub2 package in Ubuntu:
  Expired

Bug description:
  Binary package hint: grub-efi-amd64

  Spoiler alert: I am able to build grub2 from source and get it to work
  successfully / as expected.  This report details problems I face with
  the Ubuntu package.  This is also interesting in relation to grub
  itself as it seems that almost all [U]EFI testing has been on Apple
  hardware.  I'm using the above-mentioned HP 8530p with UEFI enabled.

  $ dpkg -l | grep grub
  ii  grub-common                          1.97~beta4-1ubuntu4.1                      GRand Unified Bootloader, version 2 (common 
  ii  grub-efi-amd64                       1.97~beta4-1ubuntu4.1                      GRand Unified Bootloader, version 2 (EFI-AMD

  I'm using Karmic on an HP 8530p with UEFI enabled in the "BIOS." The
  EFI partition (vfat) is mounted as /boot.

  $ mount | grep sda
  /dev/sda6 on / type ext3 (rw,errors=remount-ro)
  /dev/sda1 on /boot type vfat (rw,utf8,umask=007,gid=46)

  $ uname -a
  Linux jackson 2.6.31-14-generic #48-Ubuntu SMP Fri Oct 16 14:05:01 UTC 2009 x86_64 GNU/Linux

  Steps to cause the problem:

  aptitude install grub-efi-amd64
  grub-install
  update-grub

  Following reboot, and manually selecting (hd0,1)/grub/grub.efi using
  the BIOS EFI menu that this laptop supports (I confirmed that the
  entire grub directory is created by grub-install, and the grub.cfg
  file is created by update-grub), the following error appears (copied
  manually):

    Failed to boot default entries.
  Press any key to continue...
  error: unknown command `linux'

  Actually pressing a key causes this cycle to repeat indefinitely.
  Ctrl+Alt+Del or power cycle is required.

  In an attempt to find the cause of the problem, I also (informed by
  http://grub.enbug.org/TestingOnEFI, but not the same) obtained the
  grub source from:

  svn co svn://svn.sv.gnu.org/grub/trunk_moved_to_bazaar/grub2
  ...and did ./configure --with-platform=efi; make; make install

  I did 'aptitude purge grub-efi-amd64' and 'rm -rf /boot/grub' and then
  (from the source):

  # grub-install --modules="linux ls lspci gptsync boot cat chain echo
  ext2 fat fs_uuid hello help hexdump kernel normal part_gpt reboot
  search"

  This creates and populates /boot/grub with everything but a grub.cfg.
  I'm using the following:

  set timeout=30
  set default=0
  menuentry "GNU/Linux" {
  	set root=(hd0,1)
  	linux /vmlinuz-2.6.31-14-generic root=/dev/sda6 ro
  	initrd /initrd.img-2.6.31-14-generic
  }

  At this point I can boot successfully.  The rest of this report
  details the things I tried to get the Ubuntu package working
  (unsuccessfully).

  First, I deleted the from-source installation and reinstalled the
  Ubuntu package and simply changed to the known-good config file
  instead of using the automatically generated one.  Upon selecting the
  entry, I get:

  error: unknown command `initrd'

  Deleting the config file altogether gives a prompt like the following:

  rescue:grub>

  ls yields (from memory):

  (cd0) (hd0)

  The following commands also fail (I forget the exact error message;
  something to the tune of no such partition or unknown filesystem)
  (also, note that this works fine with the version I built from
  source):

  set root=(hd0,1)
  ls (hd0,1)/

  
  I thought perhaps this was a lack of necessary grub2 modules.  Since I
  could not actually access the filesystem from the grub rescue prompt,
  I could not insmod anything. I then booted via another method (working
  EFI grub from a directory other than (hd0,1)/grub) and created a
  simple script to capture command line arguments and invoked the Ubuntu
  package's grub-install with --grub-mkimage=[my script].  Only the fat
  and gpt_part modules are loaded (as opposed to the --modules list I
  used with the source version above).

  I tried using the Ubuntu grub-install with the --modules list above.
  However, upon booting the resulting grub installation the system still
  behaves as if none of the modules are present.  The errors are
  generally to the tune of:

  error: unknown command `linux'
  error: unknown command `initrd'

  Whenever one of these errors appears the grub rescue prompt is
  basically worthless. It seems all the partitions are inaccessible and
  insmod does not work.

  As a "hybrid" I used the Ubuntu package's grub-mkimage command
  manually to create grub.efi using the -d option to specify the
  directory where I built grub from source as the directory of modules
  to use.  This too failed.

  I'm sorry that the level of detail decreases but it is tedious to keep
  track of all of this manually.  I am happy to run a particular test if
  it proves to be useful in debugging this problem.  I "know what I'm
  doing" with respect to making sure the from-source and Ubuntu package
  versions do not clobber each other, but I'm also human.

  Thanks for all the hard work to make Ubuntu as great as it is.  I hope
  my help can make it a little bit better.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/grub2/+bug/499849/+subscriptions



More information about the foundations-bugs mailing list