svn commit: r253513 - head/release

Teske, Devin Devin.Teske at
Sun Jul 21 16:38:17 UTC 2013

On Jul 21, 2013, at 6:39 AM, Alexey Dokuchaev wrote:

> On Sun, Jul 21, 2013 at 05:23:34AM +0000, Glen Barber wrote:
>> New Revision: 253513
>> URL:
>> Log:
>>  Create memstick images with the '.img' filename extension.
>>  Requested by:	many
>>  [...]
> Is there any work being done to merge the .iso and .img into single,
> hybrid bootable image (c.g. Haiku)?

I wonder how Haiku does it.

I use ISOLINUX (part of the SYSLINUX family) as my boot loader.

The ISO9660 layer boots ISOLINUX and then chain-loads the mfsroot, displaying my beastie Forth menu.

Then from the mfsroot boot environment, sysinstall runs /install.cfg:

 which runs a small script:

Which looks for /dev/iso9660/VOL_ID

Where VOL_ID is set by the mkisofs(8) `-V VOL_ID'  flag when producing the boot media. See "BOOT_VOLID" in my GNUMakefile that calls mkisofs(8):

Now here's the trick...

It doesn't matter whether you burned the ISO to a CD/DVD or you imaged it to a USB Thumb...

... phk's GEOM layer picks up and creates /dev/iso9660/VOL_ID regardless of what medium you booted from (so-long as it was an ISO that was post-processed with the ISOLINUX utility "isohybrid").

So in my hybridized installer, I have a bootstrap script that runs before sysinstall that mounts /dev/iso9660/VOL_ID to /cdrom and I end up using /cdrom always.

That's the very basic *gist* of how I achieve hybrid booting for FreeBSD. Of course... that's only the *start*. Of course, to get sysinstall to install from /cdrom, I had to code a new media access module called "mediaSetNullFS":

Whose job is (when you configure your installation to use this access method) is to take the path given and do a mount_nullfs from point-A to point-B *prior* to doing the chroot into the formatted disk (here, like all media access methods, the point-B is "/dist" within the chroot environment).

Of course... moving forward... we would need to re-apply logistics to bsdinstall to work with ISOLINUX and isohybrid images -- though I gather it would be even easier than making sysinstall work.

>  I've asked this question before,
> but I cannot recall now what was the outcome if it...

Did I answer you last time? Just curious. I've been doing this for a while.

The information contained in this message is proprietary and/or confidential. If you are not the intended recipient, please: (i) delete the message and all copies; (ii) do not disclose, distribute or use the message in any manner; and (iii) notify the sender immediately. In addition, please be aware that any message addressed to our domain is subject to archiving and review by persons other than the intended recipient. Thank you.

More information about the svn-src-head mailing list