[syslinux] isohybrid boot from logical partition
Duncan Elliot
dmelliot at gmail.com
Thu Dec 29 01:04:16 PST 2016
Thanks for the clarification Thomas.
Thomas Schmitt wrote:
> (Did you already tell which partitions exist and in which one do you want
> to put your ISO ?)
I've tried a number of different structures, but the results are
consistent (boots fine from primary partitions, not from logical
partitions).
For example for a disk partitioned like below:
Disk /dev/sdc: 3.8 GiB, 4007657472 bytes, 7827456 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0xfc25117c
Device Boot Start End Sectors Size Id Type
/dev/sdc1 2048 616447 614400 300M 83 Linux
/dev/sdc2 616448 1230847 614400 300M 83 Linux
/dev/sdc3 1230848 1845247 614400 300M 83 Linux
/dev/sdc4 1845248 7827455 5982208 2.9G 5 Extended
/dev/sdc5 1847296 2461695 614400 300M 83 Linux
/dev/sdc6 2463744 3078143 614400 300M 83 Linux
I 'dd' the ISO to partitions 2, 3, 5 and 6.
The ISO will boot successfully (when chainloaded from grub) on 2 and
3, but not on 5 and 6.
Thanks,
Duncan
On 29 December 2016 at 19:35, Thomas Schmitt <scdbackup at gmx.net> wrote:
> Hi,
>
> Duncan Elliot wrote:
>> As far as I can see, this essentially trims off the first 3 bytes of the
>> custom isohybrid MBR image before applying it to the ISO.
>
> You probably mean this line:
>
> memcpy(mbr, &isohdpfx[hd0 + 3 * partok], MBRSIZE);
>
> The indize do not apply to bytes but to byte arrays of size MBRSIZE.
>
> extern unsigned char isohdpfx[][MBRSIZE];
>
> (hd0 + 3 * partok) selects a particular MBR template from an array of
> six MBRs. See also
> http://www.syslinux.org/wiki/index.php?title=Isohybrid#MBR_selection
>
> It tells which isohd*.bin file is selected by which combination of options.
>
>
>> does anyone have suggestions for what modification I'd need to look at
>> to support this on a logical parttion?
>
> Sorry, not me. One will probably have to analyze the code of MBR and/or
> isolinux.bin to find out why it is not working with your situation.
>
> (Did you already tell which partitions exist and in which one do you want
> to put your ISO ?)
>
>
> Have a nice day :)
>
> Thomas
>
More information about the Syslinux
mailing list