How to Make Raspberry Pi 3 Boot From USB

Christian Cawley 08-09-2016

The Raspberry Pi is a great, versatile piece of kit, capable of projects as diverse as running a media center to use as a broadcast radio. But it has one glaring flaw: the inability to boot from USB.


Well, until now, that is.

Raspberry Pi 3 Shot by MakeUseOf

If you’re using a Raspberry Pi 3 The Raspberry Pi 3: Faster, Better, with Wi-Fi and Bluetooth Today, the Raspberry Pi foundation announced the release of the Raspberry Pi 3. It's the most significant update to the popular line of low-cost computers yet. Read More , it is now possible to forego booting from microSD and instead boot the computer from a USB device. This might be a flash stick, an SSD with a USB adaptor, or even a full sized USB hard disk drive. This is a significant development, so let’s take a look at how you can setup your Raspberry Pi 3 to boot from USB.

Get Started: Install Raspbian and Add New Files

It’s best to start this project with a fresh copy of Raspbian, so download the latest version (we’re using Raspbian Jessie 5 Ways New Raspbian Jessie Makes Raspberry Pi Even Easier to Use Following the release of Debian Jessie in July, the Raspberry Pi community has been blessed with a new release of the Raspbian variant, based on the "parent" distro. Read More ) and install it in the usual way How to Install an Operating System on a Raspberry Pi Here's how to install an OS on your Raspberry Pi and how to clone your perfect setup for quick disaster recovery. Read More . As soon as this is done, safely remove the card from your PC, insert it into the powered-down Raspberry Pi and boot, remote connecting over SSH Setting Up Your Raspberry Pi For Headless Use With SSH The Raspberry Pi can accept SSH commands when connected to a local network (either by Ethernet or Wi-Fi), enabling you to easily set it up. The benefits of SSH go beyond upsetting the daily screening... Read More as soon as it loads up.

Sign in (unless you’ve changed your default credentials Securing Your Raspberry Pi: From Passwords to Firewalls Anyone can use Google to find the default username and password of your Raspberry Pi. Don’t give intruders that chance! Read More ) then run the following commands, which will replace the default start.elf and bootcode.bin files with freshly downloaded alternatives:

sudo apt-get update

sudo BRANCH=next rpi-update

This update delivers the two files into the /boot directory. With the files downloaded, proceed to enable the USB boot mode with:

echo program_usb_boot_mode=1 | sudo tee -a /boot/config.txt

This command adds the program_usb_boot_mode=1 instruction to the end of the config.txt file.

Linux Terminal Boot Raspberry Pi 3 With USB

You’ll need to reboot the Pi once this is done.


Next step is to check that the OTP — one-time programmable memory — has been changed. Check this with:

vcgencmd otp_dump | grep 17:

If the result is representative of the address 0x3020000a (such as 17:3020000a) then all is good so far. At this stage, should you wish to remove the program_usb_boot_mode=1 line from the config.txt file, you can. The Pi is now USB boot-enabled, and you might wish to use the same microSD card in another Raspberry Pi 3, with the same image, so removing the line is a good idea.

Linux Terminal Boot Raspberry Pi 3 With USB Nano Edit

This is easily done by editing config.txt in nano:

sudo nano /boot/config.txt

Delete or comment out the corresponding line (with a preceeding #).

Prepare Your USB Boot Device

Next, connect a formatted (or ready-to-be-deleted) USB stick into a spare port on your Raspberry Pi 3. With this inserted, we’ll proceed to copy the OS across.

Begin by identifying your USB stick, with the lsblk command.

Linux Terminal Boot Raspberry Pi 3 With USB LSBLK Command


In this example, the SD card is mmcblk0 while the USB stick is sda (it’s formatted partition is sda1). If you have other USB storage devices connected the USB stick might be sdb, sdc, etc. With the name of your USB stick established, unmount the disk and use the parted tool to create a 100 MB partition (FAT32) and a Linux partition:

sudo umount /dev/sda

sudo parted /dev/sda

At the (parted) prompt, enter:

mktable msdos

You might be informed that the disk is otherwise engaged. If so, select Ignore, then note the warning instructing you that the data on the disk will be destroyed. As explained earlier, this should be a disk that you’re happy to delete or format, so agree to this.

If you run into any problems here, you might need to switch to the desktop (either manually, or over VNC How to Run a Remote Desktop on Raspberry Pi with VNC What if you need access to the Raspberry Pi desktop from your PC or laptop, without having to plug in a keyboard, mouse and monitor? This is where VNC comes in. Read More ) and confirm the disk is unmounted, before entering the mktable msdos command in a windowed command line.

Proceed in parted with the following:

mkpart primary fat32 0% 100M

mkpart primary ext4 100M 100%


This will output some information concerning disk and the new partitions. Proceed to exit parted with Ctrl + C, before creating the boot filesystem, and the root filesystem:

sudo mkfs.vfat -n BOOT -F 32 /dev/sda1
sudo mkfs.ext4 /dev/sda2

You then need to mount the target filesystems, before copying your current Raspbian OS to the USB device.

sudo mkdir /mnt/target
sudo mount /dev/sda2 /mnt/target/
sudo mkdir /mnt/target/boot
sudo mount /dev/sda1 /mnt/target/boot/
sudo apt-get update; sudo apt-get install rsync
sudo rsync -ax --progress / /boot /mnt/target

That last one is the final command that copies everything over, and so will take a while to complete. Time to make a coffee!

Linux Terminal Boot Raspberry Pi 3 With USB Copying

Next, you need to refresh the SSH host keys, to maintain the connection with the reconfigured Raspberry Pi after an imminent reboot:

cd /mnt/target
sudo mount --bind /dev dev
sudo mount --bind /sys sys
sudo mount --bind /proc proc
sudo chroot /mnt/target
rm /etc/ssh/ssh_host*
dpkg-reconfigure openssh-server
sudo umount dev
sudo umount sys
sudo umount proc

Linux Terminal Boot Raspberry Pi 3 With USB SSH

Note that after sudo chroot (the fifth command above) you’re switching to root, so the user will change from pi@raspberrypi to root@raspberrypi until you enter exit on line 8.

Prepare for Rebooting From USB!

Just a few more things to sort out before your Raspberry Pi is ready to boot from USB. We need to edit cmdline.txt again from the command line with:

sudo sed -i "s,root=/dev/mmcblk0p2,root=/dev/sda2," /mnt/target/boot/cmdline.txt

Similarly, the following change needs to be made to fstab:

sudo sed -i "s,/dev/mmcblk0p,/dev/sda," /mnt/target/etc/fstab

You’re then ready to unmount the filesystems before shutting down the Pi:

cd ~
sudo umount /mnt/target/boot
sudo umount /mnt/target
sudo poweroff

Note that this uses the new poweroff command as an alternative to shutdown.

When the Pi has shutdown, disconnect the power supply before removing the SD card. Next, reconnect the power supply — your Raspberry Pi should now be booting from the USB device! And for more help with your Pi, check out how to set up Wi-Fi and Bluetooth on Raspberry Pi 3 How to Set Up Wi-Fi and Bluetooth on Raspberry Pi Unlike older models, the Raspberry Pi 3 and 4 have Wi-Fi and Bluetooth capabilities. Here's how to set them up properly. Read More .

Ready to give Raspberry Pi 4 a try Why Everyone Should Try the Raspberry Pi 4: New Features and Impressive Specs Interested in buying the Raspberry Pi 4? Here's what's new, as well as why three versions of the Raspberry Pi 4 are available. Read More ? Check out its features and specs.

Related topics: Raspberry Pi, USB.

Affiliate Disclosure: By buying the products we recommend, you help keep the site alive. Read more.

Whatsapp Pinterest

Leave a Reply

Your email address will not be published. Required fields are marked *

  1. Ian Emmons
    April 7, 2020 at 11:45 pm

    vcgencmd otp_dump | grep 17:

    needs to be run as root so should prepend sudo to it...

  2. martin
    November 25, 2018 at 9:27 pm

    hello - great article - i love it. outstanding

    one question though: can this be done with

    orange pi - pc too?!

    love to hear from you

    • Nicholas Valery
      February 25, 2020 at 2:14 am

      Hi Christian,

      It would be great if the article could be updated for the RPi4, with its finicky EEPROM!


  3. S. Mudd
    October 19, 2018 at 10:24 pm

    Hello, Christian, I have ordered a relatively fast USB 3.1 128GB boot stick (300MB/s) to do this procedure. Since most microSD drives run at about 95MB/s or slower, I'm expecting a bit of an improvement in the performance of my Raspberry Pi 3.

    My question is, what have you noticed concerning performance on an RPi3 after booting from USB stick? Would it be worth it to buy a fast SSD drive (500-600 MB/s)?

  4. John Rose
    September 1, 2018 at 7:16 am

    The display on this article on "How to make the Raspberry Pi 3 boot from usb" is now showing the text as very faint and therefore unreadable. Please correct.

  5. Marcus
    March 21, 2018 at 9:05 pm

    Same as other readers, I had to edit the cmdline and fstab manually to get it to work. Once I did that it worked like a charm. This was a very good article, very in depth and accurate. This is how my fstab file looks:

    proc /proc proc defaults 0 0
    /dev/sda1 /boot vfat defaults 0 2
    /dev/sda2 / ext4 defaults,noatime 0 1
    # a swapfile is not a swap partition, no line here
    # use dphys-swapfile swap[on|off] for that

    instead of this:

    Hope this helps someone who is stuck on a root shell locked at boot issue. That's where I was getting hung up until I corrected this.

    • Ayrat
      April 5, 2018 at 4:14 pm

      Could you please elaborate a bit more, at which step you do what you've done, and what exactly should be done? I'm trying to boot from USB drive for a second day now, following this guide without any luck.
      Thanks =)

    • Ayrat
      April 5, 2018 at 5:05 pm

      Apparently my cmdline.txt file on USB drive BOOT partition is empty and not editable. Any changes won't be saved.

  6. Rien Heins
    March 4, 2018 at 2:32 pm

    Worked for me!!
    The pi now boots from an extarnal usb ssd disk.
    I had to change the /mnt/target/boot/cmdline.txt and /mnt/target/etc/fstab manual because sd card partions are different from yours.

    However I still have one thing that isnt working and havent found out why. After doing a sudo shutdown -r now the pi3 is not restarting. it has shutdown and ethernet lights still blinking but usbdisk is not actif. a manual remove of the powersupply and reattaching it is needed. It seems the usb has no power via the pi’s usb port after the reboot but the usb disk has no extarnal psu option so I cant test it

    thx for putting the info online!!

  7. Alan Robinson
    February 19, 2018 at 2:43 pm

    I run Minimserver on my PI3, I have a large music library on a connected USB disc.
    Can I use this same USB disc to boot from by following your very detailed instructions?
    Will I need to format the USB disc?
    If I use raspi-config to expand file system
    And then I suppose just recopy the music files from a backup to /home/pi/Music

  8. Brandon
    February 18, 2018 at 2:59 am

    RPi 3b I am trying to boot a 320 Gb SATA hard drive in a Sabrent case but it won't boot up. I have a powered hub but it won't boot from USB that way because the drivers would need to be loaded in the beginning of the boot process for the powered hub to work. I tried to boot it with the USB directly inserted into the pi but no joy. I am guessing that I have to boot from microsd and pass root to the usb drive. But I don't know if it is possible with a powered USB hub. It formatted and the partions copied over just fine. I can mount it from my pi as an external drive just fine. But I have no idea how to pass root to it.

  9. Daniel
    January 18, 2018 at 7:48 pm

    Awesome tutorial! I was afraid I had to completely install my Raspian from scratch when moving from SD to SDD, but I copied my install (including several services, which I temporarily stopped) without any problems.

    I accidentally skipped the part regarding the SSH changes, but that did not cause any issues.
    Changing cmdline.txt and fstab in the final section did not work using those commands, my files contained differend values, so I changed them manually

  10. David Tordahl
    December 4, 2017 at 7:44 am

    my error upon rebooting was:

    You are in Emergency Mode.
    Cannot open access to console, the root account is locked.
    See sulogin(8) man page for details.

    PLease help!!!!!

    Best regards, Dave

  11. Nick
    October 31, 2017 at 9:44 pm

    Very nice step by step tutorial! Fitst time it did not boot since the fstab and cmdline file are using the UUID. Use the lsbk -O command to find the UUID for the SDA 1 and 2. Then edit the files manually with “sudo nano” and save with ctrl-x.

  12. Siamak
    October 17, 2017 at 11:20 am

    Hi All,

    Followed the instructions on a 64GB USB 3 and worked fine for a while.
    My RasPi was set-up as aVPN-Server and stopped working since there was a conflict between USB and the Ethernet connections, if you are using WiFi it may work fine.
    So I had to reinstall and reconfigure my VPN-Server uisng 64GB fast Micro SD card and of course my Router recognised the Pi again.


  13. David Bell
    September 18, 2017 at 2:53 pm

    I'll order a 64 class 10 card and go from there.
    Anybody successfully EXPANDED to a Hard Drive ??
    I like the PI 2 with stretch, I just need to expand to hard drive, add an internet enable PI3 WebServer to replace the one I lost on the Pi2 And then I will be a happy bunny!


    • djb
      February 2, 2018 at 5:37 pm

      UPDATE !!

      was trying on a "stretch"version.
      Will download jessie and try again.

  14. David Bell
    September 18, 2017 at 2:37 pm

    Followed it to the letter, Seagate HD this time
    failed to execute.
    Last line in the console reads .........
    179.0651481 sd 0:0:0:0: [sda] Attached SCSI disk

    then it hangs.
    so I have to give up uneless ......????

    • djb
      February 2, 2018 at 5:39 pm

      Will try again with Jessie
      not stretch

    • djb
      February 2, 2018 at 5:40 pm

      Will try with jessie,
      not stretch

  15. David Bell
    September 16, 2017 at 2:14 pm

    Tried it and it failed
    Last line on the console reads ....
    "20.0412761 random:crmsg init done"
    Will try again latter using the UUID references above.

    Also ... My systems defaulted to ext2 during the step .........
    "sudo mkfs.ext4 /dev/sda2"

    Is that significant.?


    • David
      February 6, 2018 at 11:02 am


      I will have to stay with stretch and wait for a tutorial on how to boot from a hard drive with stretch on a pi 3

      shame, I was hoping for the best to expand my web site to accomodate photo album

  16. Peter Rich
    August 29, 2017 at 7:29 am

    Hi Christian,
    Back again.
    I have just tried one of the USB sticks (which did not work on a RPi 3 last night) in one of the RPis that was working from USB - in that machine the stick DID WORK so there is clearly some difference between the two RPis at the hardware level.

    On the 'old' RPi with the new stick and running raspi-config (at CLI), 'Raspberry Pi 3 Model B Rev 1.2' is displayed at the top left corner of the display. This would indicate that the info can be retrieved via software - how is that done? I cannot find any info about getting that info via some command at the prompt.

  17. Peter Rich
    August 28, 2017 at 1:29 pm

    Hi Christian,
    I have just attempted my third conversion to USB boot. The first two worked perfectly. On the third the raspberry pi, it attempts to boot from usb - it lights up the led but goes no further. I am using 'identical' usb sticks (Lexar S45 small like logitech mouse receiver) and nominally identical Pi's. Have not yet had a chance to try previous usb sticks in current Pi but have tried multiple sticks in this third Pi. All files on the 'new' sticks appear to be correct including cmdline.txt and fstab. I have tried with Jessie and Stretch with same results. At this point in time it appears that there may be differences in the Pi's - is this possible - the third Pi was purchased about 2 months prior to the first two. (It was nice to see that Stretch is using PARTUUID to identify partitions in fstab)

    Maybe it's just that things are upside down in Australia.

  18. Steve
    August 16, 2017 at 10:09 am

    Pete, from an earlier post, thanks for pointing this out.

    The last step's that use the "sed" command to find "mmcblk0p" in the cmdline.txt and fstab files may not work, in my case the /mnt/target/etc/fstab file used "PARTUUID=" instead of "/dev/mmcblk0p", consider the following when performing this step:

    ## examine the fstab file

    cat /mnt/target/etc/fstab

    ## in the next command, if you don't see "/dev/mmcblk0p" in fstab but instead see "PARTUUID=xxxxxxxx-01" and "PARTUUID=xxxxxxxx-02"
    ## then change "/dev/mmcblk0p" to "PARTUUID=xxxxxxxx-0" substitue the actual values for "xxxxxxxx"

    sudo sed -i "s,/dev/mmcblk0p,/dev/sda," /mnt/target/etc/fstab

  19. Mike Thornbury
    August 9, 2017 at 6:27 am

    Great article, Christian.


    I followed it to the letter, replacing the appropriate dev identifier as appropriate, but can't get it to boot.

    I've tried a 64G USB flash drive, a 128GB USB flash drive and a USB SSD drive - all the steps work fine, looking at the partitions created they are bootable, with the latest Jessie version, but all I get is a red light and no boot action.

    I tried the 'boot from SD, run from USB' method and it worked fine, but getting to the stage where I can boot solely from the USB is proving difficult.

    I'm not sure where else to look. I suspected the USB3 disk adaptor, but can't get the flash drives working either.

    I'm sure I've overlooked something, but have been through this process step-by-step half a dozen times and still no joy.

    Any ideas of where to look?

    • Dick C
      August 13, 2017 at 12:59 am

      Hi Mike,
      Look at my comment below. The device ids or paths need to be correct in the cmdline.txt and fstab files. The edit in he article to these files fails but does not tell you it did.
      Look at the fstab file on the SD card and then do blkid (blkid /dev/sd??) on the usd devices to put the proper ids into the files on the USB partitons. You can use PARTUUID or UUID but remove the double quotes. Boot device id for the cmdline.txt and both boot and linux partitions for fstab.
      This is my hard drive fstab:
      proc /proc proc defaults 0 0
      PARTUUID=95f825ae-01 /boot vfat defaults 0 2
      PARTUUID=95f825ae-03 / ext4 defaults,noatime 0 1
      UUID=5f58374f-093c-406f-83f2-f0b22b9131a9 swap swap 0 0
      Hard drive partial cmdline.txt line:
      dwc_otg.lpm_enable=0 console=serial0,115200 console=tty1 root=PARTUUID=95f825ae-03 ..........
      Hope this helps,

      • Mike
        August 21, 2017 at 11:11 am

        Thanks Dick, I'll give it a try.

    • Joshua LaLonde
      August 20, 2017 at 4:15 pm

      I'm in the same boat. Everything went smoothly, zero errors, etc... but when I remove my micro SD, it will not boot from USB alone. Did you ever figure this out?


  20. Dick C
    August 4, 2017 at 9:15 pm

    The edits to /mnt/target/fstab and /mnt/target/boot/cmdline.txt did not work. The original files had partition ids . Once they were properly edited worked perfect.

    Questions - why did we not do an apt-get upgrade after the apt-get update? rip-upgrade only does a firmware update.


  21. Dick C
    July 31, 2017 at 12:14 am

    Great article. Minor error - the umount command before parted should be:
    sudo umount /dev/sda1
    Need to unmount the partition not the device.

  22. Francis Gan
    July 19, 2017 at 1:17 pm

    Thanks a lot for your sharing

    Very good

  23. Leonid
    June 25, 2017 at 3:26 pm

    If boot from USB error "Unable to mount root fs on unknown-block(8,2)"
    in /boot/cmdline.txt

    must correct "rootfstype" to
    dwc_otg.lpm_enable=0 console=serial0,115200 console=tty1 root=/dev/sda2 rootfstype=ext4 elevator=deadline rootwait

    • Christian Cawley
      June 27, 2017 at 1:19 pm

      That sounds like a fault either with writing the data to USB< or with the device itself. Best option is to retry from the beginning.

  24. Carles
    June 17, 2017 at 3:09 pm

    Hi, thanks for the guide!
    Is this still valid if I want to multiboot from my usb external hard drive?
    I would like to have the option to choose Rasbian lite + openelec
    Thanks in advance for any help

  25. xbianOEosmc-allstupid
    June 3, 2017 at 5:23 am

    wow i wish i found this guide 4 days ago. Thank you so much you god of all pi-related things

    I bow my head in respect to your uber L337 skillz

    for real, thank u.

    • Christian Cawley
      June 4, 2017 at 7:45 am

      Happy to help!

  26. Other Paul
    April 18, 2017 at 3:28 pm

    Pretty good, but I snagged myself on a gotcha. After adding that program_usb_boot_mode=1 line to the end of config.txt. The problem may be that your following instruction is "You’ll need to reboot the Pi once this is done.". Of course I had no plans to reboot at that stage but decided I'd better comment that line out for the moment and remember to uncomment it later.

    Naturally I forgot, and the rsync duly copied over the commented out version, the non usb_mode config.txt, over onto the ssd. So when I removed the ssd card after the poweroff and reapplied power, the usb boot didn't happen. Why would it?! I'd commented that last line out!

    So, put the card back in, decomment the line in /boot/config.txt, utterly forget that this is no longer the right config file, poweroff, card-out, re-power. Nothing. D'oh!

    Light dawns. Card back in, re-power, mount the sda1 and sda2 this time, edit the _right_ config.txt file (in /mnt/target/boot), unmount them [actually I forgot that but it didn't seem to matter - presumably the ordinary sync had kicked off in time], poweroff, card-out, re-power.

    Success, finally. [Sheesh!].

    Also, slight bother with parted, above and beyond the messages you warned about, given that it had previously been used with gdisk after a triple partitioning layout in an old laptop. Exiting parted and explicitly umounting everything showing up as /dev/sda* seemed to fix it though.

    Good show!

  27. Nghia
    March 13, 2017 at 2:29 am

    I did follow the instruction and no error occur, but last after "sudo poweroff" command and
    1. removed power ,
    2. SDcard
    3. power ON
    then Raspberry Pi does not boot from USB, red LED stay ON.
    What did I do wrong?


    • Christian Cawley
      April 8, 2017 at 7:11 am

      Difficult to say, I'm afraid. All I can suggest is that you restart the process. Reinsert the microSD card, reboot, and see how you get on from there.

  28. Hatex
    February 21, 2017 at 1:21 pm

    Perfect :-) thx

  29. Fernando
    February 15, 2017 at 12:23 am

    Yes all step done.. I did all updates and upgrades .. I think I did it all..

  30. Paul V Matei
    February 13, 2017 at 8:29 pm


    I have Raspberry Pi 3 and after I type : sudo apt-get update
    and after typing at second line : sudo BRANCH=next rpi-update
    I have my San Disk, Class 10, SDHC 32 GB not booting at all Raspberry Pi 3.
    I use an USB is 32 GB , PNY.
    I did try second San Disk, 32GB, Class 10, SDHC with the same negative result.
    My Pi 3 DOES NOT WORK ANY LONGER. I had to erase the SDHC card using
    SDFormatter, and reload RPi.img using Win32DiskImager.
    I did check SD Card for compatibility and it is listed as good to use.
    This is second email addressed to Mr. Christian Cawley without any response.
    Please help me to solve the frozen screen after typing the first two coomands
    and reboot- with no activity on Pi 3.
    Thank you

    • Christian Cawley
      February 14, 2017 at 1:02 pm

      Hi Paul

      I've received no email from you, but if you're experiencing problems, I suggest you address the official Raspberry Pi website forums.

      Please note that these instructions are a worked-through guide, focused at basic users, and yours appears to be the only one that did not work. However, as sudo BRANCH=next rpi-update is unlikely to damage your Pi, I would suggest investigating just what is wrong with your Pi. Do the LEDs work? See here for help:

  31. Fernando
    February 11, 2017 at 7:12 pm

    Hi, my OTP is 0x1020000a and i dont know how to fix it and change it to 0x3020000a


    • Christian Cawley
      February 14, 2017 at 1:03 pm

      What model Pi are you using?

      • Fernando
        February 14, 2017 at 5:21 pm

        Pi3 B

        • Christian Cawley
          February 14, 2017 at 8:59 pm

          And you've done the steps leading up to checking the OTP?

        • Lefteros @SomniusX
          March 11, 2017 at 5:18 pm

          Well i've had the same address printed out for OTP as @Fernando

          I'm using one Intel SS series ssd 128gb connected to sata3 to usb interface, went thru the whole process but not the pi (rpi3) pings back on the network but doesn't let me log in, not by flashing clean system on the sd, not by connected the ssd disk at even the same usb port..

          So.. i'm a bit frustrated that the my pi had something done to it by me wrongfully using this guide..

          Any ideas?

        • Christian Cawley
          March 11, 2017 at 10:12 pm

          All I can suggest, Lefteros, is checking the lights ( to establish what your Pi is telling you at boot, and consulting the discussion on the official Pi forum

          As you can see from the comments, the vast majority of readers have had success with this, but if you've omitted any steps (updates, for instance) then that can cause problems.

  32. Kalle
    February 2, 2017 at 12:49 pm

    Next step should be to but two USB sticks in raid 1. its for secure if one dies then data dont be lost and system work without crashing.

    • Christian Cawley
      February 2, 2017 at 1:58 pm

      Genius idea, Kalle. Let's wait and see what happens!

  33. Oliver
    January 18, 2017 at 9:13 pm

    How ever has done this - Many Thanks - It works great - The first script which worked perfectly. Booting from a 32 GB USB Stick

    • Christian Cawley
      January 22, 2017 at 8:45 am

      Excellent, have fun with it!

  34. Senor CMasMas
    January 13, 2017 at 10:20 pm

    Great instructions!
    First USB boot worked like a charm!

    I am running this on a SanDisk Extreme 3.0! Even though I am only getting 2.0 speeds, the performance is astounding.

    • Christian Cawley
      January 22, 2017 at 8:44 am

      Great to hear!

  35. Ram Sambamurthy
    January 13, 2017 at 9:58 am

    Hi. By setting the OTP to boot from USB, does this mean that booting from the MicroSD will not be an option after that?

    • Christian Cawley
      January 13, 2017 at 11:00 am

      You would think so from the term OTP, BUT I've successfully booted from microSD since.

      • Ram Sambamurthy
        January 14, 2017 at 1:32 am

        christian, thanks for confirming.
        yes you're right, it's easy to assume that it won't be able to, especially from the point of view of why would the Pi guys not enable it by default. the One Time Programming thingy about some capacitor that has to be blown to enable USB boot made me think that it may be an irreversible process that changes the boot process to only USB bootup.
        this article did mention in the boot sequence involving the SD first and then USB, but was not conclusive for me.
        once again, thanks for confirming.

  36. Roy Sieliakus
    January 6, 2017 at 10:15 pm

    Did exactly like you wrote, never got an error, so i thought, no problems piece of cake..
    But it does not boot from usb, and also not from sd card anymore.. :(
    Using a sandisk cruzer 16Gb. added the file 'timeout' to the usb, but nothing..

    How do i get my raspberry up and running again??

    • Roy Sieliakus
      January 7, 2017 at 12:05 am

      Got it,
      apparently it needs a wired lan connection, in stead of just wifi.
      I do not know why, but that is the only thing that has changed.
      For now i have it running on the USB.
      Thank you for the tut..

    • Roy Sieliakus
      January 7, 2017 at 12:08 am

      Got it,
      Apparently it needs a wired lan connection because with wired lan it boots up from usb.
      Why?? i have no idea because wifi is stil working.

      Anyway thanks for the tut!!

  37. geof
    January 4, 2017 at 7:25 pm


    Really nice article.

    I have followed the instructions exactly as stated. Everything is fine until I exit from the chroot command and enter

    sudo umount dev

    and get the following response:

    Umount: /mnt/target/dev: target is busy

    How do I solve this?

    Any help would be appreciated.

  38. Jan Paulussen
    January 1, 2017 at 3:14 pm

    The command to mount the new partitions from the USB start with:
    "sudo mkdir /mnt/target"
    But it should be:
    sudo mkdir -p /mnt/target (the parameter -p is the difference!)
    This is because the parent directory /mnt does not exist at that time yet, and I got an error because of that saying it cannot create the subdirectory.
    By adding the parameter it did work. It then is not necessairy to add it the second time, bacause there the /mnt directory does already exist.
    I hope this helps...
    PS: Thanks for the great instructions!

  39. Pete
    December 29, 2016 at 12:35 pm

    The procedure worked fine for me except the two "sed" steps at the end.

    /mnt/target/boot/cmndline.txt - Instead of "mmcblk0p2", mine was "mmcblk0p7"

    /mnt/target/etc/config - /boot and / had different "mmcblk0p6" & "mmcblk0p7" which I changed to /dev/sda1 & 2

    Hope this helps someone else.

  40. Nidde Nedelius
    December 28, 2016 at 8:01 pm

    I managed to get it working once.
    Excited I started setting up my webserver and such, using this script:
    But afterwards, the Pi won't boot from USB. I can put the SD-card back in and boot from that fine.
    So I tried to run the install-script before setting up the USB-boot, so that everything would already be installed and I wouldn't have to do any apt-get upgrade or similar after duplicating the system, but to no success.
    I even tried switching the firmware back to master, then back to next again, to see if that would overwrite something that got messed up by the script, but still no luck.

    Any advice?

  41. Paul Smith
    December 19, 2016 at 2:37 am

    I have been getting stuck at this point every time.

    pi@Pi-3:/mnt/target $ sudo chroot /mnt/target
    chroot: failed to run command ‘/bin/bash’: No such file or directory
    pi@Pi-3:/mnt/target $

    I have tried many times. Used 2 new USB drives. And same problem every time.
    Everything runs smoothly up until this point.
    Raspian Jessie (Pixel) latest updates. New install on sd card with Alexa installed.Nothing else.

  42. Rolf
    October 26, 2016 at 7:04 am

    I just updated and upgraded the Raspberry PI 3 with USB Boot and the Update reinstalls the original Kernel. The Raspberry will not boot anymore from USB...
    Is there a workaround eventually completing your famous tutorial? Or just avoid any Upgrade!

    • kikret
      December 9, 2016 at 12:36 pm

      very good questions, i will also want to know

  43. Rol
    October 25, 2016 at 1:09 pm

    PI 3 with a 120 GB Stick
    Simply great. Works like a charm.
    Many thanks for this, I guess, the only really working tutorial

    • Christian Cawley
      October 26, 2016 at 6:46 am

      Delighted it worked for you, Rol!

  44. William
    October 16, 2016 at 1:27 pm

    This worked like a charm! At first, I thought things were awry, because it stays on the RaspPi rainbow boot screen. But, after what seemed like forever to us antsy types, it booted without a hitch the first time I tried it! GREAT TUTORIAL!!!

    • Christian Cawley
      October 26, 2016 at 6:46 am

      Thanks for sticking with it, William!

  45. John Douglas
    October 6, 2016 at 11:56 pm

    Great article. I followed the instructions implicitly (I think :) ). When I rebooted the RP1 3 I go these messages:
    [3.437232] USB 1-1.4.4: Unable to get BOS descriptor.
    [4.439885] SD 0:0:0:0: [SDA] Asking for cache data failed
    [4.440070] SD 0:0:0:0: [SDA] Assuming drive cache: write trough

    Can any body help with this please?

    • Christian Cawley
      October 7, 2016 at 9:20 am

      This seems like a problem with the USB device. Have you tried a different flash device?

      I used this:

      • John Douglas
        October 7, 2016 at 9:54 am

        I am using a WD 500 Gb sata drive mounted in an external hdd usb case with it's own power supply. Maybe I'll have to replace the drive?

        Thanks for your reply, kind regards John

        • Christian Cawley
          October 7, 2016 at 11:25 am

          I suspect it's how the drive is being recognized.

          If you can get this to work with a standard USB flash drive, then you know the new feature works. After that, it's a case of finding a USB adaptor for your HDD that offers the right compatibility

  46. Jeff Johnson
    September 21, 2016 at 2:13 am

    Thanks so much much this worked brilliantly. Great work, I had a pi3 and a 1 tb pidrive working on raspbian jessie. Ran flawlessly I had issues installing a touch screen and will have to redo at some point. Can I do this on Openelec Kodi 15.2? I'm trying to make a large capacity stand alone portable music player I would like to boot into Openelec on a the piDrive and use a small lcd to control the who;e thing. I'm piecing the portable power supply after the software and hardware are done. Willing to try anything once all ideas welcome can always format and start over.

    • Christian Cawley
      October 7, 2016 at 9:17 am

      I don't believe it will work beyond Raspbian at this stage, but would expect support for it to be included in future distro updates.

  47. Pierre
    September 17, 2016 at 8:25 pm

    Puneet: Did you remove the SD-card as mentioned above?

  48. john
    September 17, 2016 at 2:36 pm

    works well. but pi 3 is very picky on the USB memory you use.
    does not work with all USB sticks.

  49. Puneet
    September 11, 2016 at 7:39 am


    I tried your step by step process, it's still booting from SD card and not from USB.
    I think Raspberry is programmed to boot from SD card and unless we change the BIOS of raspberry and program it to boot from SD card as well as USB, it's not going to work.


    • Christian Cawley
      September 18, 2016 at 7:10 pm

      That's the whole point of the tutorial, which is based on instructions from the official Pi website. It's not like we've made this up, it actually works, on a Pi 3.

      Please make sure you double check your steps, and remember to run vcgencmd otp_dump | grep 17: - if this gives the correct result, the necessary switch has been made.

      • Bert Shure
        October 11, 2016 at 9:09 am

        Very cool!

        How about mirroring two USB Flash drives?