Install Linux onto a USB Thumb Drive

Install Linux onto a USB Thumb Drive

I anticipation of Mythtv 0.22 coming out someday, I have been working on how I will leverage the new features. It has been a few years since I build my last Mythtv system and I am researching new equipment that is small, quiet, and will play 1080p videos. In addition to this I would like my new systems to not have a hard drive in them. This led me to experimenting with installing CentOS on a USB thumb drive.

The reason I am running CentOS is because I am a Redhat Linux fan. I did fun Fedora on all my systems, but got tired of the upgrade treadmill every 6 months to a year. I needed something stable that would have a long shelf life, and CentOS fit those requirements.

Also I have a few spare USB thumb drives sitting around not doing much. I thought that these would be perfect for a system like Mythtv. It is true that USB thumb drives do not have the read / write speeds of normal hard drives; however I figured that once the system is booted up and running the speed deference would not be a show stopper.

So to start you will need the following items:
A computer that will boot to CD/DVD and USB
I am using a Dell Latitude Laptop. I removed the hard drive to make sure the install does not see it and try to over write my boot loader. Any newer motherboard or machine should have the options to boot to USB Device or CD/DVD. If you don’t have them you might check the manufactures website for an update.

CentOS Release
So to start I downloaded the newest release of CentOS DVD ISO (Currently 5.3) and burned it. I think you might be able to do this with only Disk 1 of the CentOS CD release, however I cannot confirm this. (Please let me know if you try it and can).

USB Thumb Drive
I have a 2GB thumb drive I have managed to get CentOS installed on. I do not thing I can get it on a 1GB, but I might try in the future. I would however recommend a 4GB+ so you don’t have to ‘yum clean all’ all the time, or update your packages a few at a time.

Time to Install
To do the actual install was quite easy. Insert the CD/DVD in to the computer drive and boot to it. At the first Linux install screen (where you usually wait or just press enter to start the install) type “linux expert“. Once you have done this the USB drivers will load and the USB Thumb Drive will show up in Disk Druid. If you did not remove your hard drive (for saftey reasons) be sure you select the correct drive in format and install Linux. Also be sure you install GRUB on the correct partition. The first time I tried this I had to repair my Windows 7 installation because I overwrote my MBR.

Also if you are trying to install on a smaller USB thumb drive you will want to chose a custom install and uncheck all packages. This will insure you have the smallest possible install and all unnecessary files will be removed from the core installation. You can always install these later by using yum or any other method supported.

There you have it. If you find this useful, have a tip you would like me to add, or have feedback; please leave a comment.

Like it? Share it!:
  • Digg
  • del.icio.us
  • Facebook
  • Google Bookmarks
  • Twitter
  • Yahoo! Buzz
  • LinkedIn

About the Author

MattsShack MattsShack: Follow Us on Twitter at: MattsShack