[TriLUG] Multiboot CD Question
Roy Vestal
rvestal at trilug.org
Mon Mar 22 09:48:26 EDT 2010
Sorry for the duplicate. That first sentence should read:
So none of these suggestions did what I was looking, as I needed a CD
not a bootable USB.
On 3/22/10 9:46 AM, Roy Vestal wrote:
> So none of these suggesteions did what I was looking, as I needed a CD
> not an ISO. I was able to figure it out, with some more googling, and
> here are the simple steps. I am going to write this up a little more
> and submit it to CentOS as well as post it on my site too.
>
> The basic need: I have almost 50 servers in my lab that I need to test
> several variables and gather information on. Different manufacturers
> and such.
>
> I used the CentOS LiveCD howto and minimal kickstart for the LiveCD. I
> added 'dmidecode' and 'pciutils' to the kickstart packages. I also
> created a post install to add "prtdiag" script to the disk. I had to
> modify the prtdiag a little to get it to do what I wanted. Here are
> the links:
>
> https://projects.centos.org/trac/livecd/
> http://people.redhat.com/tcallawa/prtdiag/
>
> Hope this helps someone.
>
> ------------begin quick howto--------------
>
> Goal: Creating a Multiboot disk with 2 versions of CentOS based OS's.
>
> I had 2 versions of CentOS LiveCD's that I had created I wanted on one
> CD, one 32 bit, the other 64 bit. Here are the steps I went through to
> make this happen. I will only show the 64bit version here. You have to
> repeat for the 32bit version substituting the appropriate names.
>
> 1. Created a working folder: mkdir ~/bootdisk
>
> 2. Created a working folder structure: mkdir -p ~/bootdisk/64bit
> ~/bootdisk/32bit
>
> 3. copied the files from the CentOS LiveCD ./LiveOS folder to the
> appropriate ~/bootdisk folder: cp /media/CentOS-min-64/LiveOS*
> ~/bootdisk/64bit
>
> 4. Copied and renamed each kernel and ignited from each CentOS LiveCD
> ./isolinux folder to ~/bootdisk: cp
> /media/CentOS-min-64/isolinux/vmlinuz0 ~/bootdisk/vmlinuz64 and cp
> /media/CentOS-min-32/isolinuxinitrd0.img ~bootdisk/initrd64.img
>
> 5. Had to unpack the initrd files to edit the /sbin/init file in the
> to reflect the new path to the osmin.img and the squashfs.img
> 5a. created ~/bootdisk/temp mkdir ~/bootdisk/temp
> 5b. cd ~/bootdisk/temp
> 5c. renamed initrd64.img vm ../initrd64.img ../initrd64.gz
> 5d. unzipped it unzip ../initrd64.gz
> 5e. unpacked it cpio -id < ../initrd64
>
> 6. Edited the /sbin/init file. Changed all references to "LiveOS" to
> the appropriate folder name (64bit or32bit) with the EXCEPTION of
> "/squashfs/LiveOS/ext3fs.img".
>
> 7. repack the initrd image.
> 7a. cd ~/bootdisk/temp
> 7b. find . | cpio --create --format='new' > ../initrd64.img
> 7c. cd ..
> 7d. mv initrd64.img initrd64
> 7e. gzip initrd64
>
> 8. Copied isolinux.cfg file in root of ~/bootdisk cp.
> /media/CentOS-min-64/isolinux/isolinux.cfg ~/bootdisk
>
> 9. Edited isolinux.cfg file to reflect the changes to my new CD,
> specifically the label, kernel, and append lines for each iso added. I
> also added the default to be boot local disk.
> 9a. edited label 1 for 64bit
> i. set label to "menu label Boot 64bit" (without quotes)
> ii. set kernel line to "kernel vmlinuz64" (without quotes)
> iii. changed append line to reflect changes and the new label i
> was going to give to the CD: "append initrd=initrd64.img
> root=CDLABE=TestCD rootfstype=iso9660 ro liveimg" (without quotes)
> 9b. I also remarked out "menu hidden" so the menu would appear.
>
> 10. Copied needed files from CD so isolinux would boot the disk and
> the iso will build correctly:
> 10a. c.p. /media/CentOS-min-64/isolinux/isolinux.bin ~bootdisk
> 10b. c.p. /media/CentOS-min-64/isolinux/boot.cat ~bootdisk
> 10c. c.p. /media/CentOS-min-64/isolinux/splash.jpg ~bootdisk
> 10d. c.p. /media/CentOS-min-64/isolinux/vesamenu.c32 ~bootdisk
>
> 11. Removed ~/bootdisk/temp folder
>
> 12. cd ~
>
> 13. Created CD with mkisofs: mkisofs -V "TestCD" -o testcd.iso -b
> isolinux.bin -c boot.cat -no-emul-boot -boot-load-size 4
> -boot-info-table newboot
>
> ------------end quick howto--------------
>
> -Roy
>
> On 3/19/10 8:46 AM, Roy Vestal wrote:
>> I'll check into it.
>>
>> I am using VirtualBox to build the CDs as well as test them.
>>
>> As for the end result, I am testing physical systems so I need the
>> CD. Some do not boot USB.
>>
>> On 3/18/10 6:04 PM, Cristóbal Palmer wrote:
>>> On Thu, Mar 18, 2010 at 1:56 PM, Roy Vestal<rvestal at trilug.org> wrote:
>>>> I have built 2 different CentOS live CD's for testing in our lab.
>>>> As both
>>>> CD's are 150MB uncompressed, I can easily fit them on one CD. I'm
>>>> trying to
>>>> figure out how to make a single multiboot CD from 2 seperate CentOS
>>>> LiveCD's.
>>> Googling for "usb multiboot linux" without the quotes got me this:
>>>
>>> http://www.mepis.org/docs/en/index.php/Create_a_multiboot_CD_(or_USB_flash_drive)
>>>
>>>
>>> Which looks like it's most of what you need. Let us know if that
>>> works? Two suggestions from personal experience: (1) booting from USB
>>> may be marginally more effort, but is worth that effort to make the
>>> bootable USB image and learn to use it. (2) VirtualBox is a lovely
>>> thing for testing stuff like this, but use whatever flavor of
>>> virtualization that you find most tasty.
>>>
>>> Cheers,
>>
>> --
>> TriLUG mailing list : http://www.trilug.org/mailman/listinfo/trilug
>> TriLUG FAQ :
>> http://www.trilug.org/wiki/Frequently_Asked_Questions
>
More information about the TriLUG
mailing list