Creating a custom bootable 1GB Flash Drive

Ted Landau

December 15, 2006


How would you like to have a 1GB keychain drive that can boot from your Mac, running the utilities of your choice? I'm talking about those flash drives that are small enough to easily slip into your pocket. Yes, it can be done. Even better, the software for this setup is completely free! All you need is the flash drive itself and a Mac OS X Install disc that works with your Mac (such as the one that came with your Mac). As you can get a 1GB USB 2.0 drive for as little as $20 (such as this Kingston Data Traveler), the whole deal is quite a bargain. Of course, you'll also need to pay for whatever non-free utilities you choose to add to the drive.


Why bother to do this at all? The primary reason is for troubleshooting. In the most obvious example, if your Mac won't start up, you can use the flash drive to boot your Mac and run repairs. You can already do this with your Mac OS X Install DVD, using it to run Disk Utility. You may also have other bootable discs containing other repair software. But with this flash drive setup, you can combine your own preferred collection of troubleshooting utilities onto one bootable device. Further, if you do troubleshooting for friends or as a business, traveling to various locations, the drive becomes even more handy.


What about creating a custom bootable DVD instead? Yes, it can be done, via procedures quite similar to what I describe below (and documented in detail in my recent MacFixIt column). And yes, a DVD is certainly a lot cheaper than a flash drive. Plus, if you have a PowerPC Mac (instead of an Intel Mac), you can't boot from a USB flash drive, making a DVD even more attractive (you could get a FireWire flash drive instead, but they are significantly more expensive than their USB siblings). On the other side of the ledger, a flash drive gives you a speed advantage over a DVD. Plus, you can write to as well as read from the drive, while DVDs are read-only. This gives you a big boost in flexibility, such as the ability to create and save files while booted from the flash drive.


The other alternative is to use a full-size USB or FireWire portable external drive (they typically start at about 60GB). With this approach, you can just install Mac OS X on the drive, directly from an OS X Install DVD, in the same way you would for any standard hard drive. But these drives are more expensive and larger (and thus less portable) than a keychain drive.


Bottom line: At least if you have an Intel Mac, the flash drive is the optimal solution for a bootable emergency disc/drive.


Setting up the drive requires a bit of work (although it will seem more complicated, as your read through the procedure here, than it actually is). The good news is that you only need to do it once. So let's get started:


  1. Get the bootable Mac OS X Install Disc that came with your Mac, or any other Mac OS X Install disc that you know successfully boots on your Mac.
  2. Using Disk Utility, make a read-write image of the disc. To do this:
  3. Mount the image on your Desktop, by double-clicking the image (.dmg) file.
  4. Delete non-essential contents from the disk image. In particular, delete all the unwanted items in the /Applications folder and all the items in the /System/Installation/Packages folders. The goal is to get the total size remaining to be well under 1GB, so that you can add your desired software and still be under the 1GB limit. You should be able to get down to close to 700MB.
  5. Add the desired applications to the /Applications folder of the image. Useful utilities to consider adding include Disk Utility, Terminal, Console and TextEdit (all from the Mac OS X disk), as well as utilities such as DriveGenius, DiskWarrior, FileXaminer, Plist Edit Pro, and whatever else you commonly use when troubleshooting.
  6. Make sure that one of the utilities you add is the freeware utility QuickerPicker. This is the key utility that will serve as your launcher for the other utilities on your drive (which is critical as there is no Finder on the drive!).
  7. Open the etc folder on the mounted disk image (an icon for the folder is at the root level of the image). Locate a file called rc.cdrom. Drag the file to the TextEdit icon to open it in TextEdit. Locate a line that reads: <mount -u -o ro /> and change it to <mount -u />. Save the modified file.
  8. Now you need to create two text files, modified to be executable shell scripts. Here's what to do to create the first file:
  9. For the second file, repeat the exact same procedure as in Step 8, except name the file rc.cdrom.postWS and enter the following three lines:
  10. Place these two files in the etc folder of the mounted disk image. The function of these two files is to have QuickerPicker launch at startup, rather than the Mac OS X Installer utility (which is what typically launches when you boot from a Mac OS X Install disc).
  11. Use Disk Utility's Restore command to copy the modified disk image to the flash drive. To do this:
  12. With the flash drive mounted in a USB port, restart your Intel Mac. Hold down the Option key at startup. From the screen that appears, click to select the flash drive as the startup device. QuickerPicker should soon appear. Success!


The Path Finder alternative. If you are willing to spend the money to get the excellent Finder substitute, Path Finder, you can use it as an alternative to QuickerPicker. Even better (and cheaper) would be to use the actual Finder, but getting it to work on a 1GB flash drive would be significantly more difficult; I did not attempt this. The advantage of a utility such as Path Finder, as opposed to a simple application launcher such as QuickerPicker, is that you have a much wider range of features available, including the ability to navigate the contents of your internal drive and open, rename, copy, move or delete files. To use Path Finder, instead of QuickerPicker:


  1. If you haven't already done so, install Path Finder to the /Applications folder of your bootable flash drive (presumably currently booting QuickerPicker on launch, as described above).
  2. If you want Path Finder to launch immediately upon booting, you must use the path for Path Finder in the rc.launchapp file instead of the path for QuickerPicker. The Path Finder path is:
    /Applications/Path\ Finder.app/Contents/MacOS/Path\ Finder. Alternatively, you could instead skip this step and simply launch Path Finder from QuickerPicker's application list.
  3. Path Finder requires a number of Mac OS X frameworks in order to run. These frameworks are present in a standard install of Mac OS X, such as on your internal hard drive, but not on a bootable DVD (which was the basis for the OS X version on the flash drive). So you will need to add the required frameworks. To do so, just copy them from your hard drive to the same location on the flash drive (ideally the two drives should be using the same or similar version of Mac OS X). Here is a list of the frameworks to copy:


Back to macosxhelpline.com


Back to tedlandau.com