[Top][All Lists]

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

Re: GRUB doesn't recognize partitions on El-Torito image during EFI boot

From: Jacek Konieczny
Subject: Re: GRUB doesn't recognize partitions on El-Torito image during EFI boot from CD
Date: Tue, 12 Nov 2013 17:19:11 +0100

On Tue, 12 Nov 2013 12:40:44 +0400
Andrey Borzenkov <address@hidden> wrote:
> On Tue, Nov 12, 2013 at 11:50 AM, Jacek Konieczny <address@hidden>
> wrote:
> >> Could you give example how your image is seen in EFI shell?
> >
> > What EFI shell command should I use for that?
> >
> Using "map" would be a good start. You may use "map -b" to paginate.
> Could you dump it to a file (use e.g. USB stick for it) and attach?

Mapping table
      FS0: Alias(s):HD15a0b0b:;BLK1:
      FS1: Alias(s):HD20b0a1:;BLK3:
      FS2: Alias(s):CD20e0a1b:;BLK8:
     BLK0: Alias(s):
     BLK2: Alias(s):
     BLK5: Alias(s):
     BLK4: Alias(s):
     BLK6: Alias(s):
     BLK7: Alias(s):

FS0 is the pendrive I used to store this output.
FS1 is ESP of the disk in the system (not used here).
FS2 is the contents of a partition of the El-Torito image on the CD.

This was tested with the Lenovo B590 laptop's firmware.

> > The strange thing is – my previous 'prototype', with EFI shell and
> > ELILO, was bootable. And GRUB loads too, it just cannot see the
> > other files on the image.
> >
> Could you please describe step by step how you build your CD? Exact
> command line(s) would be helpful.

It was done by my scripts to hack PLD Rescue CD into an EFI-bootable
image. The relevant commands called by the script:

# Building the HDD image
# efiboot/ contains /EFI/BOOT/BOOTX64.EFI which is the EFI shell
# syslinux is installed for BIOS boot, not relevant here
dd if=/dev/zero of=efiboot.img bs=$cylinder count=${cyls}
lodev=$(losetup --partscan --find --show efiboot.img)
sfdisk "$lodev" <<EOF
dd if=/usr/share/syslinux/mbr.bin of="$lodev"
mkdosfs -F 16 -n "EFIBOOT" "${lodev}p1"
mount "${lodev}p1" "$mntdir"
cp -aL efiboot/* "$mntdir/"
cp efiboot/startup.nsh "$mntdir/EFI/BOOT"
umount $mntdir
losetup -d $lodev

# building of the ISO image
mkisofs -v -J -R -D -A "${VERSION}_H" -V "${VERSION}_H" -no-emul-boot 
-boot-info-table \
-boot-load-size 4 -b boot/isolinux/isolinux.bin -c boot/isolinux/boot.catalog \
-eltorito-alt-boot -hard-disk-boot -e boot/efiboot.img \
-A "PLD Linux RescueCD $VER (EFI+legacy)" \
-p ""; \
-log-file $LOG -o "image.iso" new

The 'new' directory containst the boot/isolinux/isolinux.bin and
boot/efiboot.img files. boot/efibootimage is the image created with the previous
set of commands.

> Not without special arrangements. grub-mkrescue is using xorriso which
> builds hybrid ISO image containing extra partition table(s) which
> results in GRUB being able to access El-Torito boot image as normal
> HDD partition.

I think I will need to take a look at this xorriso then… I hoped I can do with
the standard mkisofs.


reply via email to

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