2009-11-01

How-To: Make a Multiboot Live USB Stick

This is something that I wanted to do for a while to show those interested what Linux is like on the fly. However, I only finished this yesterday.
The USB stick in question is an 8 GB Sandisk Cruzer Micro.
The distributions used are PCLinuxOS 2009.2 (KDE), Fedora 11 (GNOME), Linux Mint 7 (Xfce), and the latest version of PartedMagic. These are the only distributions I've successfully put on a multiboot live USB stick, so I'll only talk about how to create this step.
In terms of setup before the actual live USB creation process, a few steps must be taken. As far as I know, due to Windows only recognizing FAT and NTFS partitions, the steps I used will only work on Linux. My preferred partition editor is GParted. Also, if you don't have UNetBootin, get it beforehand. Finally, make sure that your computer has a CD-RW drive and that you have spare empty CD-R/CD-RWs.
The first distribution to add is PCLinuxOS.
If there are any existing partitions, remove and replace them with a single FAT32 primary partition covering the entire disk.
Next, download the PCLinuxOS 2009.2 KDE ISO image from the Internet and burn the image to (not on) the CD-R/CD-RW. (If, after this step, the disk is ejected, reinsert it but close any autorun dialogs.)
Next restart the computer and (if necessary, reconfigure the BIOS to) boot from the live CD (that is, the CD with the PCLinuxOS image on it).
After that is all done, go to the PCLinuxOS main menu and click on "Make Live USB". Please make sure that the correct USB stick is being written to (you can check this as root in Terminal through the command "fdisk -l" and determining which USB stick with its free space correctly corresponds to your stick, if you know what I mean).
Restart the computer and, after modifying the BIOS to boot from the USB stick, make sure that the live USB works properly.
If it does, it is time to move on. (Revert the BIOS to boot from the hard disk drive.) If not, make sure that you followed all of the steps listed here in the given order.
To prepare for the remaining distributions, in GParted, trim the primary FAT32 partition with PCLinuxOS on it until there is about 100-150 MB of free space left on that partition. Fill the remaining unallocated space with an extended partition. Finally, fill this extended partition with 2 logical FAT32 partitions of size 850 MB (each), another logical FAT32 partition of size 400 MB, and a logical FAT32 partition that takes up the remainder of the extended partition.
The second, third, and fourth distributions are Fedora, Linux Mint, and PartedMagic. Download all of these respective ISO images from the Internet, and use UNetBootin and the "Disk Image" feature to write the images to the partitions. The Fedora and Linux Mint images should go separately in each of the 850 MB partitions, while the PartedMagic image should go in the 400 MB partition. UNetBootin recognizes partitions by disk drive name and number rather than by size, so to verify which partition is which, as root in Terminal type in "fdisk -l" to know which partition to write to in UNetBootin. After each write, verify that the live USB image works properly by booting from the USB. Each time a new image is written by UNetBootin to a partition, that partition is automatically flagged as bootable.
These steps will not allow you to select from all of the distributions which one to boot from (i.e. from a giant GRUB menu list upon booting). You much change which distribution to boot from manually in GParted by modifying the "boot" flag.
If you followed all of these steps and it all works, you should be good to go! If not, please leave a comment!