Re: [edk2] Shell2 cannot be re-used unless started/restarted on a stable volume

Subject: Re: [edk2] Shell2 cannot be re-used unless started/restarted on a stable volume

From: Laszlo Ersek <lersek@redhat.com>

To: Duane Voth <duanev@gmail.com>

Date: 2013-06-25 06:44:32

On 06/24/13 22:06, Duane Voth wrote:
> 
> On Mon, Jun 24, 2013 at 1:28 PM, Laszlo Ersek  > wrote:
> 
>     On 06/24/13 16:53, Duane Voth wrote:
>     > ... if the Shell is, for example, the payload for a PXE
>     > boot, the call to GetDevicePathsForImageAndFile() in Shell.c fails
>     > (because the shell.efi binary cannot be accessed locally) and the
>     Shell
>     > code ASSERTs.
> 
>     I just tested Shell2 as PXE payload (using the built-in edk2 PXE
>     implementation) and it starts fine. (SVN r14442.)
> 
>     Were you testing Shell2 as PXE payload for the iPXE implementation?
> 
> 
> In this case no, the shell.efi *is* my dhcp-named tftped-bootp payload.

It is strange then -- I don't get the assertion failure you describe.

>     After PXE-booting Shell2 I can't start "shim.efi":
> 
>       FS0:\EFI\fedora\> shim.efi
>       Fetching Netboot Image
>       Unable to fetch TFTP image
>       Fetching Netboot Image
>       Unable to fetch TFTP image
> 
> 
> This looks like some uefi device driver you have which provides a tftp
> (readonly) "file system"?
>  
> 
>     But I *can* start "grubx64.efi", surprisingly. Does that involve
>     Execute() too?
> 
> 
> If from a shell command line then yes.  But where does grubx64.efi
> reside?  On a local hard disk?  usb?  flash?

Both "shim.efi" and "grubx64.efi" are files in the "FS0:\EFI\fedora"
directory. FS0 is the UEFI system partition on a virtio-blk disk, with
GPT partition table:

  FS0: Alias(s):HD16b:;BLK3:

PciRoot(0x0)/Pci(0x4,0x0)/HD(1,GPT,7623C01C-A240-417A-8B21-0925DFD15142,0x800,0x64000)

I don't understand the different handling of "shim.efi" and
"grubx64.efi". Maybe Shell2 loads each just fine, and it's not their
"handling" but their "internals" that work differently.

... Hm, yes, those messages are printed by "shim" itself
. shim detects that the system was booted
with PXE (start_image() --> findNetboot()) and tries to download grub
from there too (FetchNetbootimage()), which fails (correctly).

So, in fact I can start both "shim.efi" and "grubx64.efi" from the
command line of the PXE-loaded Shell2. Isn't that (ie. Execute()) what
you said didn't work for you in a PXE-loaded Shell2?

Thanks,
Laszlo

------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
edk2-devel mailing list
edk2-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/edk2-devel