How to start Raspberry Pi 4 from USB

By default, your Raspberry Pi boots from the SD card containing the operating system. Here we are going to show how you can ditch the microSD card and boot your Raspberry Pi 4 from USB directly from an external SSD drive.

Why you should ditch microSD storage

While the microSD storage solution is adequate for most small projects and simple IoT applications, it is not optimal when the Raspberry Pi 4 is used as a full-fledged computer. Besides the obvious speed difference between an SSD and a microSD card, the latter quickly emerges as the weakest link in applications that require frequent writes to the file system.

Although SD card and SSD use NAND flash memory, they are not the same. NAND flash cells on a microSD card can only be overwritten a finite number of times, and frequent writes to the file system will exhaust microSD storage very quickly.

A modern SSD, on the other hand, uses a sophisticated on-board processor to perform automatic wear-leveling routines. This prevents uneven wear of the NAND flash modules. SSDs also have a greater range of these flash modules to distribute writes sparingly. This allows them to better withstand the wear and tear of frequent writes to disk compared to microSD storage.

Booting from an SSD is not easy

Since the Pi 4 does not have a built-in SATA or m.2 connector, the USB 3.0 port is the only way to connect a 2.5-inch or m.2 SSD. Booting the Pi 4 off USB also requires a firmware update. Playing with the device’s EEPROM is risky business, so make sure your Pi 4 doesn’t suddenly lose power during the process.

READ:   How to turn your Raspberry Pi into a Wi-Fi bridge

Additionally, not all USB 3.0 to SATA / m.2 adapters will work well with the Pi 4 at this point. The Raspberry Pi Foundation is working to ensure that USB booting works reliably with all USB to SATA SSD boxes, but it is not clear when the functionality will be included in a future official version of the Raspberry Pi operating system. Until then, booting reliably via SSD is all about finding the right external USB enclosure. But even if your SSD or USB box combination doesn’t work, booting via a fast and compact USB 3.0 dongle, like the Samsung Fit, is always better than the slower microSD card.

To start

Before purchasing a new 2.5 inch SSD enclosure, make sure it supports UASP (USB Attached SCSI Protocol). This new protocol uses a faster SCSI command set and exploits the wonders of parallel communication through Native Command Queuing to dramatically improve transfer speeds.

Raspberry Pi 4 Usb Ssd Boot 04

Here’s what you need for this business:

  1. Raspberry Pi 4
  2. Existing microSD card with Raspberry Pi operating system installed
  3. SSD with a USB 3.0 enclosure. You also need a 2.5 inch USB drive enclosure.
  4. Internet connectivity for firmware and system updates

How to start Raspberry Pi 4 from USB

1. Boot your Pi from the microSD card.

2. Once on the desktop, open the terminal and enter the following commands to update the distribution.

3. After updating the operating system, the system should be prepared to receive the latest stable firmware update. This requires modification of a specific system configuration file.

Raspberry Pi 4 Usb Ssd Boot 05

4. The default value of FIRMWARE_RELEASE_STATUS The setting is “critical”, which must be changed to “stable” in order to install the latest firmware. hurry Ctrl + O to validate the modifications of the file, then Ctrl + X to leave.

READ:   How to choose between iPad Pro and MacBook Air

5. Update the firmware with the following command to activate the new bootloader.

Raspberry Pi 4 Usb Ssd Boot 06

6. Once the update is complete, restart your Raspberry Pi 4.

7. Check if the update was successful by typing the following command in the terminal.

The latest firmware update is displayed. This should be the June 15, 2020 or later version for the USB boot function to work properly. The last version of the stable bootloader at the time of writing this was July 16, 2020.

Raspberry Pi 4 Usb Ssd Boot 07

8. Next, clone your microSD card to the SSD you plan to use as the new boot device. This is best done with the “SD Card Copier” application which can be found in the Accessories section of the Raspberry Pi operating system GUI.

9. Shut down the Raspberry Pi 4, remove the microSD card and connect the USB boot drive.

10. Turn the Pi 4 back on and wait patiently for the operating system to boot from the USB drive. If you see the screen below, congratulations because you have successfully booted your Raspberry Pi 4 from fast storage media connected via the USB port.

Raspberry Pi 4 Usb Ssd Boot 03

Conclusion

The Raspberry Pi 4 can be a powerful device if you can unleash its potential. By switching to SSD, you can easily get a performance boost and use it for more intensive operations like running a web server or Minecraft server.

Leave a Reply