If you have a Pi 3B+, then you shouldn't need to do anything as USB boot is already supported "out of the box".
Only for a "standard" Pi 3B should you need to configure
From USB-Mass Storage Boot - Raspberry Pi 2B, 3A+, 3B, CM3, CM3+, Zero 2 W
Enable USB host boot mode with this code:
echo program_usb_boot_mode=1 | sudo tee -a /boot/config.txt
The next step is to reboot the Raspberry Pi with sudo reboot and check that the OTP has been programmed with:
vcgencmd otp_dump | grep 17:
Check that the output
0x3020000a is shown. If it is not, then the OTP bit has not been successfully programmed. In this case, go through the programming procedure again. If the bit is still not set, this may indicate a fault in the Raspberry Pi hardware itself.
If you wish, you can remove the program_usb_boot_mode line from
config.txt, so that if you put the SD card into another Raspberry Pi, it won’t program USB host boot mode. Make sure there is no blank line at the end of
You can now boot from a USB mass storage device in the same way as booting from an SD card - see the following section for further information.
One important thing to check is that there is no blank line at the end of
Maybe remove the changes that you made to
config.txt and see if it works.
Further troubleshooting steps
If the USB SD card reader continues to fail to boot, run some other tests:
- Check if a standard USB drive works (rather than the SD card reader). As a sanity check, try to boot from a standard USB drive/stick
- Maybe the SD card reader is somehow incompatible - try a different card reader
- If the Pi can see the card reader as
sdb... then boot with one working SD card in the on board SD slot and then try to write to another second SD card in the USB SD card reader. Verify that it is actually possible to save and read a file on that second SD card in the USB SD reader
- Try a different USB port.
Basically, just try swapping things around...
Notes on defective (or incompatible) USB SD card reader
As has finally been shown - after the first troubleshooting step demonstrated that a USB stick or drive is bootable - it is the USB SD reader that fails to boot. This indicates that the USB SD card reader is at fault, or incompatible in some way... and thereby suggesting that all USB SD card readers are not bootable and should be avoided.
However, this isn't actually 100 % true...
The Pi 3B+ can indeed boot from a USB SD card reader, as shown by this question, 3B+ will boot from USB (microSD to USB adapter) and not from the microSD card itself. Therefore, I would posit that the USB SD card readers used by @Milliways and yourself have some weird quirk (either using old and slow USB 1.1 ICs or whatever), or that they are just different in some other way.
As a slightly distracting side note, there is an additional issue that could be at play, and that is USB port enumeration, where another USB device causes the first USB device to fail... as suggested in this comment on 3B+ will not boot from USB:
It may be enumerating by port number, you can try swapping them around. IIRC the port closest to board and Ethernet jack is 1. On running system you can tell port numbers with dmesg.
Admittedly, in that question the issue seemed to be a power issue, when an Apple USB device was also connected.
However, I have seen enumeration issues on a Pi 4, which caused a USB to Ethernet adapter fail, when a USB drive is also connected. The solution was to install
usb-modeswitch and create/run a service, to re-enumerate the ports correctly.
However, this probably doesn't apply in this particular case, as no addtional USB devices were (presumably) connected.