[syslinux] How to recognize an MBR suitable for isohybrid --mac ?
H. Peter Anvin
hpa at zytor.com
Sun Jun 24 08:00:18 PDT 2012
Hi Matt,
Do you have any input on this?
-hpa
On 06/22/2012 06:02 AM, Thomas Schmitt wrote:
> Hi,
>
> i have implemented in xorriso the equivalents of isohybrid.c options --mac
> and --uefi. There remains the question how to ensure that the submitted
> MBR is prepared for the 32 byte mock-up of an APM Block0.
>
> I see in git of may 2012 that all mbr/isohdp[fp]x*.bin begin by
> 33 ed 90 90 90 90 90 90 90 90 90 90 90 90 90 90
> 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90
>
> Can i safely refuse on MBR templates which do not bear that signature
> without inflicting injustice on future isohybrid MBRs ?
>
> (I will also accept the substituted bytes of isohybrid --mac:
> 45 52 08 00 00 00 90 90 00 00 00 00 00 00 00 00
> 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
> )
>
> ----------------------------------------------------------------------
>
> I tested my implementation by re-packing Fedora-LiveCD.iso and booting
> it by PC-BIOS from CD and USB stick.
>
> I do not have hardware that would boot via APM or GPT (i.e. Mac from
> CD and USB stick or hard disk). A test would be needed, because xorriso
> deviates from several suspicious address computations of isohybrid.c,
> and from its GPT partition names.
> For the reasons of deviation see
> http://www.syslinux.org/archives/2012-May/017518.html
>
>
> So just in case somebody is curious, here is a description how to prepare
> test media on Linux. It will need about 1.4 GB of disk space.
>
> - Download ISO (650 MB) and the most recent xorriso development snapshot
> (2.2 MB) into an elsewise disposable directory
> wget http://mjg59.fedorapeople.org/Fedora-LiveCD.iso
> wget http://www.gnu.org/software/xorriso/xorriso-1.2.3.tar.gz
>
> - Build xorriso
> tar xzf xorriso-1.2.3.tar.gz
> ( cd xorriso-1.2.3 && ./configure && make )
>
> - Copy the MBR out of Fedora-LiveCD.iso
> dd if=Fedora-LiveCD.iso bs=512 count=1 of=Fedora-LiveCD.mbr
>
> - Mount Fedora-LiveCD.iso
> mount -o loop Fedora-LiveCD.iso /mnt
>
> - Create new ISO image FedoraRepack.iso
>
> xorriso-1.2.3/xorriso/xorriso -as mkisofs \
> -o FedoraRepack.iso -no-pad \
> -isohybrid-mbr Fedora-LiveCD.mbr \
> -c /isolinux/boot.cat \
> -b /isolinux/isolinux.bin -no-emul-boot \
> -boot-load-size 4 -boot-info-table \
> -eltorito-alt-boot \
> -e /isolinux/efiboot.img -no-emul-boot \
> -isohybrid-gpt-basdat -isohybrid-apm-hfsplus \
> -eltorito-alt-boot \
> -e /isolinux/macboot.img -no-emul-boot \
> -isohybrid-gpt-hfsplus -isohybrid-apm-hfsplus \
> -V Fedora-LiveCD \
> /mnt
>
> (My apologies for using the unchanged Volume Id "Fedora-LiveCD".
> The booting system wants to see this in its /dev/disk/by-label/.)
>
> - Put on CD, DVD or BD:
> xorriso-1.2.3/xorriso/xorriso -as cdrecord \
> dev=/dev/sr0 -v blank=as_needed -eject FedoraRepack.iso
>
> - Put on USB stick (Caution: Make sure not to overwrite your hard disk !):
> dd if=FedoraRepack.iso bs=4M of=/dev/sdc ; sync
>
> ----------------------------------------------------------------------
>
> Have a nice day :)
>
> Thomas
>
> _______________________________________________
> Syslinux mailing list
> Submissions to Syslinux at zytor.com
> Unsubscribe or set options at:
> http://www.zytor.com/mailman/listinfo/syslinux
> Please do not send private replies to mailing list traffic.
>
--
H. Peter Anvin, Intel Open Source Technology Center
I work for Intel. I don't speak on their behalf.
More information about the Syslinux
mailing list