Bug 846831

Summary: The openSUSE 13.1 RC1 install medium is not able to load the kernel when booted via UEFI
Product: [openSUSE] openSUSE 13.1 Reporter: Richard Biener <rguenther>
Component: BootloaderAssignee: Michael Chang <mchang>
Status: RESOLVED WONTFIX QA Contact: Jiri Srain <jsrain>
Severity: Normal    
Priority: P5 - None CC: coolo, er2003, jsrain, karstenanderson, lnussel
Version: RC 1Flags: mchang: needinfo? (rguenther)
coolo: SHIP_STOPPER-
Target Milestone: ---   
Hardware: x86-64   
OS: Other   
Whiteboard:
Found By: Development Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---

Description Richard Biener 2013-10-21 11:51:48 UTC
When not using the legacy boot option to boot the RC1 install DVD medium then,
while grub starts just fine, the install system does not boot because grub cannot
load the kernel.  On the grub command-line the kernel file is clearly visible
in the path it tries to load, so this seems to be a bug in grub?

The system is an Intel DHSK3 software development platform (Haswell) with
up-to-date firmware.
Comment 2 Erik Riedel 2013-10-24 17:14:19 UTC
Same problem on ASUS notebook N56VJ
Comment 4 Michael Chang 2013-10-25 06:58:54 UTC
Dup of bnc#841426.

*** This bug has been marked as a duplicate of bug 841426 ***
Comment 5 Michael Chang 2013-10-25 08:30:30 UTC
reopen per the reply.

I have secure boot disabled but still grub says

"Loading kernel ..."
"error: Can't read kernel /boot/x86_64/loader/linux."
"Loading initial ramdisk ..."
"error: you need to load the kernel first."

so not sure this is really a duplicate.  Note that the Beta1 medium had
the very same issue.
Comment 6 Michael Chang 2013-10-25 08:44:11 UTC
Hi Richard,

How about using USB as installation media ? Are you using AHCI mode ?
Comment 7 Richard Biener 2013-10-25 08:53:23 UTC
(In reply to comment #6)
> Hi Richard,
> 
> How about using USB as installation media ? Are you using AHCI mode ?

Yes, I am using AHCI mode, I did not try using USB as install media
(not sure how to set that up and I am currently lacking a USB stick
at the office).

The DVD works fine when booting via legacy BIOS.
Comment 8 Michael Chang 2013-10-25 09:23:16 UTC
We used to have AHCI bugs and fixed(workaround) by smaller chunk reads. The fix is included in our factory (13.1) by this upstream commit revision.

------------------------------------------------------------
revno: 4859
author: Peter Jones <pjones@redhat.com>
committer: Vladimir 'phcoder' Serbinenko <phcoder@gmail.com>
branch nick: grub
timestamp: Mon 2013-04-15 09:12:14 +0200
message:
        * grub-core/disk/efi/efidisk.c: Limit disk read or write chunk to 0x500
        sectors.
        Based on patch by Peter Jones.
Comment 9 Michael Chang 2013-10-25 09:28:45 UTC
In addition, please help to grab some log from your grub shell ? Press 'e' to enter editing mode and add this line

 set debug=efidisk

And F10 or Ctrl+X to boot.

And also try use other mode (like IDE) if available to check whether it's AHCI specific or not ?
Comment 10 Richard Biener 2013-10-25 09:52:31 UTC
(In reply to comment #9)
> In addition, please help to grab some log from your grub shell ? Press 'e' to
> enter editing mode and add this line
> 
>  set debug=efidisk
> 
> And F10 or Ctrl+X to boot.

Stops with

reading 0x980 sectors at the secrot 0xa9d0 from cd0
closing cd0

which would confirm the large read issue.

> And also try use other mode (like IDE) if available to check whether it's AHCI
> specific or not ?

Doesn't work with IDE mode either.
Comment 11 Michael Chang 2013-10-25 10:17:59 UTC
So this seems NOT AHCI problem we previously have. Based on your report
1. IDE mode not work either
2. You did see error like this "error: failure reading sector 0xab from cd0"

I'm trying to figure out what's other possibilities. Could you identify this a "regression" bug or not of openSUSE ?

Thanks.
Comment 12 Michael Chang 2013-10-25 10:19:15 UTC
(In reply to comment #11)

> 2. You did see error like this "error: failure reading sector 0xab from cd0"

s/did/didn't/
Comment 13 Richard Biener 2013-10-25 10:28:01 UTC
(In reply to comment #11)
> So this seems NOT AHCI problem we previously have. Based on your report
> 1. IDE mode not work either
> 2. You did see error like this "error: failure reading sector 0xab from cd0"

No, I didn't see an error.  Previous reads were all short though.

> I'm trying to figure out what's other possibilities. Could you identify this a
> "regression" bug or not of openSUSE ?

I'm sure it will affect SLE12.  Not sure if any UEFI DVD media ever worked.

> Thanks.
Comment 14 Michael Chang 2013-10-25 11:20:07 UTC
(In reply to comment #13)

> No, I didn't see an error.  Previous reads were all short though.

Even without "error: Can't read kernel /boot/x86_64/loader/linux." ? How about this (sorry these are pretty blind shots ) ?

press 'c' to enter command mode
 set debug=all
 /boot/x86_64/loader/linux
 boot
Comment 15 Michael Chang 2013-10-25 11:21:12 UTC
Correction.

press 'c' to enter command mode
  set debug=all
  linuxefi /boot/x86_64/loader/linux
  boot
Comment 16 Richard Biener 2013-10-25 11:29:15 UTC
(In reply to comment #14)
> (In reply to comment #13)
> 
> > No, I didn't see an error.  Previous reads were all short though.
> 
> Even without "error: Can't read kernel /boot/x86_64/loader/linux." ? How about

Yes.

> this (sorry these are pretty blind shots ) ?
> 
> press 'c' to enter command mode
>  set debug=all
>  /boot/x86_64/loader/linux
>  boot

with that the fail is already

Detecting iso9660...
reading 0x10 sectors at the sector 0x3a0 from cd0
Closing `cd0'
closing cd0

I can mount the disk quite fine and also read /boot/x86_64/loader/linux.
Comment 17 Karsten Anderson 2013-10-26 16:46:52 UTC
I'm also getting this failed to load kernel on an Asus S500CA ultrabook.  This is using RC1 on a USB stick as there is no DVD drive on the system.  I enabled debug mode in grub and this is what it output:

Loading kernel...
disk/efi/efidisk.c:489: opening hd0
disk/efi/efidisk.c:519: m = 0xbc3df598, last block = f0afff, block size = 200
disk/efi/efidisk.c:529: opening hd0 succeeded
disk/efi/efidisk.c:581: reading 0x40 sectors at the sector 0x80 from hd0
disk/efi/efidisk.c:581: reading 0x40 sectors at the sector 0x40 from hd0
disk/efi/efidisk.c:581: reading 0x40 sectors at the sector 0x0 from hd0
disk/efi/efidisk.c:581: reading 0x40 sectors at the sector 0xe80 from hd0
disk/efi/efidisk.c:581: reading 0x40 sectors at the sector 0x2a700 from hd0
disk/efi/efidisk.c:581: reading 0x2600 sectors at the sector 0x2a740 from hd0
disk/efi/efidisk.c:581: reading 0x40 sectors at the sector 0x2cd40 from hd0


Then it just hangs.  Let me know if there's any other things I can try to help.
Comment 18 Karsten Anderson 2013-10-26 17:58:49 UTC
I replaced bootx64.efi as outlined in this post: https://bugzilla.novell.com/show_bug.cgi?id=841426#c23 on the USB stick and it booted correctly and got 13.1RC1 installed, so maybe it is related to shim?
Comment 19 Michael Chang 2013-10-28 07:02:22 UTC
Probably, honestly I have no idea now. (If you could get 13.1 milestone work but not after Beta or after probably you hit the shim bug ..).
Comment 20 Ludwig Nussel 2013-10-28 15:42:14 UTC
Did you try 12.3? Does that one boot?
Comment 21 Ludwig Nussel 2013-10-29 10:00:41 UTC
We tried build 82 which has the original 12.3 shim on Richard's machine. DVD didn't work but from a USB stick it worked.
Comment 22 Michael Chang 2013-10-30 09:42:08 UTC
Hi Ludwig/Richard,

Could you please verify that this is general "read" broken issue on iso9660 ? We need a general grub2 disk which would allow us to run more testings (the installer disk's grub2.efi has no additional modules ..)

 zypper install libburnia-tools (for xorriso)
 mkdir isoroot
 cp -rf /boot isoroot
 grub2-mkrescue -o test.iso isoroot

And burn this test.iso to DVD for testing ..

once booted, you should be dropped by grub shell, try these commands to see what happened ?

grub> linux /boot/vmlinuz-3.10.6-1.gbd99dce-desktop
grub> boot

grub> linuxefi /boot/vmlinuz-3.10.6-1.gbd99dce-desktop
grub> boot

grub> md5sum  /boot/vmlinuz-3.10.6-1.gbd99dce-desktop

If those all failed then would indicate a general efi problem, and please post any error message you have ..

Thanks.
Comment 23 Michael Chang 2013-10-30 09:43:25 UTC
Btw you have to disable secureboot for these testings.
Comment 24 Richard Biener 2013-11-04 10:22:40 UTC
I've now tried RC2 (build 84) and still get

Loading kernel...
error: Can't read kernel /boot/x86_64/loader/linux.

same debug output as before.  I have secureboot disabled anyway.

Sorry, didn't get around producing the debug media as stated in comment #22.
Comment 25 Stephan Kulow 2013-11-05 13:50:55 UTC
after talking also with steffen, it seems to be one of these BIOS problems. So I remove the ship stopper flag and we all curse UEFI ;(
Comment 26 Michael Chang 2015-01-29 06:51:11 UTC
Close as firmware related problem.