Date: Tue, 26 Jun 2001 01:39:42 -0400 (EDT) From: "Lawrence S. Lansing" <lansil@rpi.edu> To: freebsd-hackers@freebsd.org Subject: custom bootable CD & /usr/src/sys/i386/boot/cdboot Message-ID: <Pine.A41.3.96.1010626002910.64824A-100000@vcmr-19.rcs.rpi.edu>
next in thread | raw e-mail | index | archive | help
Hello. I am trying to create a custom bootable FreeBSD CD with a "live" filesystem. I have read all the mailing-list messages I could find pertaining to this process, and I am still short of information. I will sum up the situation, and hope someone can fill in the details I'm missing. Here's what I have so far: There are several ways of making a bootable FreeBSD CD. All of these methods seem to involve "El Torito", and a boot floppy image of some kind. The contents of the boot floppy can image vary somewhat, but there appear to be two primary approaches: 1 -- The boot image contains a gzipped kernel, MFS, loader, and other relevant /boot stuff. The Kernel and MFS in the boot image are used to mount the CD filesystem, and possibly chroot to the CD filesystem. The FreeBSD install CD uses this method. 2 -- The boot image is created by running 'make' in /usr/src/sys/i386/boot/cdboot. This image contains a smarter 'loader', which is able to read an ISO9660 filesystem for the kernel and root filesystem. I believe this boot image contains boot0/1 and /boot/cdboot. /boot/cdboot appears to be created from /usr/src/sys/boot/i386/cdldr, a 'loader' wrapper which replaces boot2, and allows 'loader' to understand ISO9660. I am interested in using method 2, since it would eliminated several complications. I would not need to worry about mounting/chrooting the CD filesystem, nor would I have to worry about fitting a kernel, loader, and /boot stuff onto a 2.88 meg image. If I understand this method correctly, the 'cdboot' loader would find the kernel and root filesystem on my CD, and everything would "just work". Well, theory is great, but I've run into a problem. I used /usr/src/sys/i386/boot/cdboot/ to create a boot image. I used mkisofs with the '-b' option to put this image into the boot portion of my ISO filesystem. I burned a CD, and attempted to boot from it. I was greeted with this message, generated by 'cdboot': --- Your BIOS int 0x13 extensions seem to be disabled. It's impossible to boot a CD-ROM without them. (BIOS int 0x13 fn 0x4b01 yielded error 75 --- The same message appears when the CD is booted in three different machines, all with fairly recent hardware and BIOSes. I have the distinct suspicion that the error message is bogus. I'm working with a recent -STABLE source tree (within the last week), but it doesn't appear that any of the boot-related files have been changed in almost a year. My only lead, so far, is that I might need to specify the '-no-emul-boot' option to mkisofs. I'll try this out tomorrow, when I have time to make another burn. If anyone can flesh out the boot procedure a bit more for me, I would appreciate it. Specifically, I would like to know what /usr/src/sys/i386/boot/cdboot/ does, and whether I am trying to use it correctly. I found very little documentation on this directory, even when I resorted to checking CVS commit messages. Thanks for any help you can offer. I apologize for being so long-winded. -Larry Lansing To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.A41.3.96.1010626002910.64824A-100000>