Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I read about the Evil Maid attack, and thought of partitioning a flash drive, putting a bootloader on one partition and storing data on the other. Is this possible, or is there some alternative that only requires one flash drive for both booting a machine and storing data?

share|improve this question
you can try ultraiso tool fro windows which helps you to create booted partition and free space partition on same flashdrive – BlueBerry - Vignesh4303 Aug 13 '12 at 5:51
I like how you assumed I have a Windows system. – Blacklight Shining Aug 13 '12 at 5:57

There's no requirement to have more than one partition on the drive provided you use a bootloader such as SYSLINUX that is capable of handling it. Simply make sure that you boot into an operating system that has USB drive support and you'll be able to access it like normal.

share|improve this answer
What about grub or yaboot? And I'd like to partition it anyway so the bootloader's files aren't in the way of mine… – Blacklight Shining Aug 13 '12 at 4:30
grub you can get away with but yaboot will require another partition, and I haven't heard one way or the other about its USB boot capabilities. – Ignacio Vazquez-Abrams Aug 13 '12 at 4:36

Use GParted to format the unpartioned space then use it for making a bootable USB.

share|improve this answer
So I can just partition a flash drive, make one partition bootable, and store data on the other? – Blacklight Shining Aug 13 '12 at 3:52

If you're trying to actually "install" a Linux distro on a USB device that's one thing - which I don't recommend.

But to boot a live Linux disro from a USB thumb drive really doesn't require much. Just prepare the USB thumb drive with the FAT32 file system Or FATx (assuming it isn't already and that you don't need files any larger than 4Gig). Then use something like Yumi or UNetBootN to make it bootable with your choice of Linux. Done! Afterwards, you can also use the USB storage device to store files on too (assuming there's room).

Now, if you want to save any settings or other things within your Linux environment then you will want to create a "persistence" area (file) on the USB drive too. Persistence acts sort of like a virtual hard drive for any settings or other changes you make when you're in your live Linux environment. Then, when you shut down you won't loose anything. Puppy Linux does this almost by default too. But Puppy does it slightly differently and can even do it completely from a re-writable CD. (Very cool stuff.)

So don't break your brain trying to install Linux to a USB device - just use a live version prepared with UNetBootN, Yumi or something. Just about every major Linux distro out there is already a "live" version. About the only fancy thing you may want to do is enable persistence. You don't even have to format the USB device since it's likely already prepared with the FAT32 file system. And everything works with FAT32.

Then again, if your USB device is an actual hard drive (HDD) then you will want to install Linux while the HDD is actually on a HDD controller - not on a USB port (even though you can do it that way). You might even disconnect any other HDD's when you do this too. Afterwards, just re-house the HDD back in your USB enclosure. Done! About the only thing you probably don't want to do afterwords is enable any special hardware like certain 3D video settings since it might not always work on other different systems (that's about the one disadvantage of not going with a live version).

Hope it helps.

share|improve this answer
No, this isn't about installing an entire distro to a flash drive, just running the bootloader from it to prevent an Evil Maid attack. – Blacklight Shining Aug 13 '12 at 6:36
Whoops, I misread that. I'm not trying to run a system from a flash drive, just install the bare minimum needed to get something running that can decrypt the main system stored on the hard disk and continue the boot from there. Once the computer is up and running, I should be able to eject the flash drive. – Blacklight Shining Aug 14 '12 at 12:08

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.