All of lore.kernel.org
 help / color / mirror / Atom feed
* Re: Grub2 on UEFI
       [not found] <e18fdcb5-b179-44b7-ada5-1b72c4d3a429@edge1.acronis.com>
@ 2010-01-29 14:39 ` Georgy Buranov
  2010-01-29 17:02   ` Michal Suchanek
  0 siblings, 1 reply; 4+ messages in thread
From: Georgy Buranov @ 2010-01-29 14:39 UTC (permalink / raw)
  To: grub-devel@gnu.org

> ?????????????????? What about chainloading in grub2? Does it support loading another
> EFI loader? Particularly, I want to load Windows Boot Manager (in term of
> EFI that's EFI file) from GRUB?

> On Apple EFI I can chainload just fine, this should be no different on UEFI.

What do you mean by chainloading in case of UEFI? For example, I got EFI System Partition and 3 OS Loaders there (eLilo, GRUB2 and Windows Boot Manager). 

/EFI/Boot/GRUB/bootx64.efi
/EFI/Boot/eLilo/bootx64.efi
/EFI/Boot/Microsoft/bootx64.efi

I need a way to load both Boot Manager and eLilo for grub. Can you please show me the example of config file?

>
>
>
> ?????????????????? If it possible to exit grub with EFI ERROR to process loading the
> next loader?
>

> Exiting grub is in itself an error, an OS loader should never end.
> So look for some quit command.

Why? I think it was in old BIOS times. EFI was a boot order concept, in one loader is failed, another one is trying to boot.



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Grub2 on UEFI
  2010-01-29 14:39 ` Grub2 on UEFI Georgy Buranov
@ 2010-01-29 17:02   ` Michal Suchanek
  2010-01-29 18:45     ` gburanov
  0 siblings, 1 reply; 4+ messages in thread
From: Michal Suchanek @ 2010-01-29 17:02 UTC (permalink / raw)
  To: The development of GNU GRUB

On 29/01/2010, Georgy Buranov <Georgy.Buranov@acronis.com> wrote:
> > ?????????????????? What about chainloading in grub2? Does it support loading another
>
> > EFI loader? Particularly, I want to load Windows Boot Manager (in term of
>  > EFI that's EFI file) from GRUB?
>
>
> > On Apple EFI I can chainload just fine, this should be no different on UEFI.
>
>
> What do you mean by chainloading in case of UEFI? For example, I got EFI System Partition and 3 OS Loaders there (eLilo, GRUB2 and Windows Boot Manager).
>
>  /EFI/Boot/GRUB/bootx64.efi
>  /EFI/Boot/eLilo/bootx64.efi
>  /EFI/Boot/Microsoft/bootx64.efi
>
>  I need a way to load both Boot Manager and eLilo for grub. Can you please show me the example of config file?

The command to use is chainloader or similar (as opposed to the
'linux' command used to load a Linux kernel) and it takes the name of
other .efi image as the parameter. You can try it in the grub
commandline.

If you want to put that in a menu look at the existing config and the
scripts in your distro that generate it. Editing the config file is
generally useless as it is usually generated by a script.

>
>  >
>  >
>  >
>  > ?????????????????? If it possible to exit grub with EFI ERROR to process loading the
>  > next loader?
>  >
>
>
>  > Exiting grub is in itself an error, an OS loader should never end.
>  > So look for some quit command.
>
>
> Why? I think it was in old BIOS times. EFI was a boot order concept, in one loader is failed, another one is trying to boot.

If the boot loader exited it has obviously not loaded any OS hence it
has failed.

Thanks

Michal



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Re: Grub2 on UEFI
  2010-01-29 17:02   ` Michal Suchanek
@ 2010-01-29 18:45     ` gburanov
  2010-01-29 20:51       ` Michal Suchanek
  0 siblings, 1 reply; 4+ messages in thread
From: gburanov @ 2010-01-29 18:45 UTC (permalink / raw)
  To: grub-devel

>  /EFI/Boot/GRUB/bootx64.efi
>  /EFI/Boot/eLilo/bootx64.efi
>  /EFI/Boot/Microsoft/bootx64.efi
>
>  I need a way to load both Boot Manager and eLilo for grub. Can you please show me the example of > config file?
> 
> The command to use is chainloader or similar (as opposed to the
> 'linux' command used to load a Linux kernel) and it takes the name of
> other .efi image as the parameter. You can try it in the grub
> commandline.
> 
> If you want to put that in a menu look at the existing config and the
> scripts in your distro that generate it. Editing the config file is
> generally useless as it is usually generated by a script.

Thanks I will try chainloader and write about results later! About the script that generates menu - actually speaking I don't have a distro =) I need grub to load small kernel with ramdisk - that do specific actions and quit, they don't have functionality to edit config file, so I need to do it by myself.

>
>  >
>  >
>  >
>  > ?????????????????? If it possible to exit grub with EFI ERROR to process loading the
>  > next loader?
>  >
>
>
>  > Exiting grub is in itself an error, an OS loader should never end.
>  > So look for some quit command.
>
>
> Why? I think it was in old BIOS times. EFI was a boot order concept, in one loader is failed, another 
> one is trying to boot.
> 
> If the boot loader exited it has obviously not loaded any OS hence it
> has failed.

Here I disagree. In old BIOS times we got only one try to load OS - the MBR got the jump to the loader (lilo, grub, ntldr, whatever), and if the loader fail - the whole booting it failed (however loader can "pass" execution to another loader)

Now, EFI has the concept or order  of loaders. The EFI firmware loader has a list of loaders, if the first one (say grub) is failed, it will try next one (say Windows Boot Manager). So, Windows Boot Manager is executed by EFI Firmware loader, not by the grub>
>
>
> ·         What about  device names in grub2 for EFI? The problem  is that
> old device names were based on BIOS device names, and it seems that in EFI
> it's not the same. For example, what disk is hd0?
> 
> Unfortunately, the disk order is firmware specific and nothing can be
> done about that. You should look at disk content or use UUIDs.

Please, I need more info on it =)
How can I identify the disk using disk content or UUID.

For example, I got my kernel on NTFS partition and now smth like

(hd2,1)/Loader/Kernel/vmlinux

is written in grub config. Imagine that new disk is inserted oor new partition is created, the booting will fail. For example I need to examine all partitions and if one has a dir structure /Loader/Kernel/vmlinux and/or UUID ... - load the kernel. How can I do that? I can't find mych information on the topic

Thanks in advance,
Georgy!!

--
This message was sent on behalf of gburanov@gmail.com at openSubscriber.com
http://www.opensubscriber.com/message/grub-devel@gnu.org/13347318.html



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Re: Grub2 on UEFI
  2010-01-29 18:45     ` gburanov
@ 2010-01-29 20:51       ` Michal Suchanek
  0 siblings, 0 replies; 4+ messages in thread
From: Michal Suchanek @ 2010-01-29 20:51 UTC (permalink / raw)
  To: The development of GNU GRUB

On 29 January 2010 19:45,  <gburanov@gmail.com> wrote:

>
>>
>>  >
>>  >
>>  >
>>  > ?????????????????? If it possible to exit grub with EFI ERROR to process loading the
>>  > next loader?
>>  >
>>
>>
>>  > Exiting grub is in itself an error, an OS loader should never end.
>>  > So look for some quit command.
>>
>>
>> Why? I think it was in old BIOS times. EFI was a boot order concept, in one loader is failed, another
>> one is trying to boot.
>>
>> If the boot loader exited it has obviously not loaded any OS hence it
>> has failed.
>
> Here I disagree. In old BIOS times we got only one try to load OS - the MBR got the jump to the loader (lilo, grub, ntldr, whatever), and if the loader fail - the whole booting it failed (however loader can "pass" execution to another loader)
>
> Now, EFI has the concept or order  of loaders. The EFI firmware loader has a list of loaders, if the first one (say grub) is failed, it will try next one (say Windows Boot Manager). So, Windows Boot Manager is executed by EFI Firmware loader, not by the grub>

Yes, you said it yourself - if it has failed. So any time the loader
exits it is a failure.

>>
>>
>> ·         What about  device names in grub2 for EFI? The problem  is that
>> old device names were based on BIOS device names, and it seems that in EFI
>> it's not the same. For example, what disk is hd0?
>>
>> Unfortunately, the disk order is firmware specific and nothing can be
>> done about that. You should look at disk content or use UUIDs.
>
> Please, I need more info on it =)
> How can I identify the disk using disk content or UUID.
>
> For example, I got my kernel on NTFS partition and now smth like
>
> (hd2,1)/Loader/Kernel/vmlinux
>
> is written in grub config. Imagine that new disk is inserted oor new partition is created, the booting will fail. For example I need to examine all partitions and if one has a dir structure /Loader/Kernel/vmlinux and/or UUID ... - load the kernel. How can I do that? I can't find mych information on the topic

You probably want the search command.

The Debian scripts produce something like this:

search --no-floppy --fs-uuid --set <some long string of
numbers,letters and dashes here>

In GNU/Linux (with modern udev) you get can see the UUID mapping in
/dev/disk/by-uuid.

Disk check tools also typically report it.

If you use MS tools it might be named and formatted slightly
differently, though.

Thanks

Michal



^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2010-01-29 20:52 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <e18fdcb5-b179-44b7-ada5-1b72c4d3a429@edge1.acronis.com>
2010-01-29 14:39 ` Grub2 on UEFI Georgy Buranov
2010-01-29 17:02   ` Michal Suchanek
2010-01-29 18:45     ` gburanov
2010-01-29 20:51       ` Michal Suchanek

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.