help-grub
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Cannot boot from dual bios/uefi boot CD


From: Andrei Borzenkov
Subject: Re: Cannot boot from dual bios/uefi boot CD
Date: Wed, 28 Jan 2015 15:36:23 +0300

On Wed, Jan 28, 2015 at 2:15 PM, John Frankish
<address@hidden> wrote:
>> >> > On Wed, Jan 28, 2015 at 10:30 AM, John Frankish
> <address@hidden> wrote:
>> >> > Hi,
>> >> >
>> >> > I'm trying the create a dual bios/uefi boot iso to burn to CD/DVD
>> >> > and boot both bios and uefi.
>> >> >
>> >> And your grub version is?
>> >>
>> > 2.00
>> >
>> Current is 2.02~beta2.
>>
>> >> > The bios boot works fine
>> >> > On two different machines, the uefi boot gets to the grub menu list:
>> >> >
>> >> > On a dell laptop choosing the grub menu item boots to the linux
>> >> > console prompt, but will not accept any keyboard input On a mac
>> >> > mini the boot hangs without error message after choosing the grub
> menu
>> >> > item.
>> >> >
>> >> > Note that in both cases, I can enter grub commands from the prompt
>> >> > and can also edit the grub menu entries.
>> >>
>> >> And it boots after that?
>> >
>> > No, on the laptop it boots to the console prompt, but does not accept
>> > keyboard input
>> >
>> >> >  In addition, both the bios and uefi boot are using the same
>> >> > vmlinuz and initrd files.
>> >> > Finally a more standard uefi installation to usb stick boots on
>> >> > both machines without problems.
>> >> >
>> >>
>> >> I'm afraid I do not quite understand that. Could you be more verbose
>> >>
>> >> - what "standard uefi installation to usb stick" means?
>> > The grub modules are in /EFI/BOOT/grub/X86_64 rather than embedded in
>> > BOOTX64.EFI
>> >
>>
>> Any reason you need to build your own image in the first place? And if
> yes, what is the reason to include ata, ahci and all USB drivers?
>> Please build image without them (i.e. ahci ata ehci ohci uhci usb_keyboard
> - hopefully I did not miss something).
>
> The reason is that I thought from google that was how things had to be done
> for a dual bios/uefi CD/DVD boot. I included the USB drivers because on both
> the dell laptop and the mac mini the CD/DVD drive is an external USB one.
>

Your EFI firmware should provide access to it.

> Are you saying I should create an efiboot.img containing a minimal
> BOOTX64.EFI (if so, what counts as minimal?) and the usual grub modules
> under /EFI/BOOT/grub/X86_64 instead of embedding them in BOOTX64.EFI?
>

I say that you should be using grub-mkrescue command. This is
supported tool to build bootable standalone hybrid ISO image that can
be used to boot both from CD as well as USB (although to boot from USB
in case of EFI you probably need recent fix). This command builds
correct image and allows you to add arbitrary files to it, including
grub.cfg, kernels and such. It needs xorrisofs and in case of EFI -
mtools (mformat/mcopy).

grub-mkimage is low level tool which is almost never correct way
unless you have very specific requirements not covered by standard
utilities.

Drivers that I listed work directly with hardware and so mess its
state. It means it is undefined what happens when both EFI and drivers
try to access hardware. When you use what you call "standard USB"
those drivers are not loaded, nor are they loaded when you use
grub-mkrescue (unless you load them manually in grub.cfg).

>> >> >
>> >> > $ x86_64-grub-mkimage --format=x86_64-efi --output=BOOTX64.EFI
>> >> > --prefix=/EFI/BOOT/grub --config=/tmp/grub.cfg acpi ahci all_video
>> >> > appleldr at_keyboard bitmap_scale ata boot cat chain configfile
>> >> > cs5536 echo efi_gop efi_uga ehci ext2 fat font gfxmenu gfxterm gzio
>> >> > halt help hfs hfsplus iso9660 jpeg keylayouts linux loadbios
>> >> > loadenv ls minicmd normal ohci
>> >> > part_gpt part_msdos png probe regexp reboot search search_fs_file
>> >> > search_fs_uuid search_label test tga true udf ufs1 ufs2 uhci
>> >> > usb_keyboard zfs.
>> >> >
>



reply via email to

[Prev in Thread] Current Thread [Next in Thread]