How to Boot a Raspberry Pi From SSD and Use It for Permanent Storage

Trending 2 months ago

Using an SSD for your Raspberry Pi offers galore advantages complete a modular microSD card. To alteration it, conscionable travel our step-by-step instructions.

A Raspberry Pi Zero leaning connected a Raspberry Pi 3 successful a case

Both SSDs (solid-state drives) and SD cards usage fundamentally akin flash retention exertion to shop data. However, SSDs connection faster controllers and much responsibility tolerance, making them overmuch much reliable than SD cards. While astir Raspberry Pis are still moving connected microSD cards, you whitethorn besides usage an outer SSD to footwear your Raspberry Pi.

Below, you'll study nan steps to alteration USB footwear connected Raspberry Pi, past usage an outer SSD arsenic bootable media to footwear Raspberry Pi OS and usage nan leftover abstraction arsenic imperishable retention for your data.

Things You Will Need

You will request nan pursuing items to alteration SSD footwear connected Raspberry Pi:

  • Raspberry Pi (4, 400, 3B+, Zero W, aliases Zero 2 W)
  • microSD paper (1GB minimum, 64GB maximum)
  • microSD paper scholar
  • Keyboard and a rodent (both wireless aliases wired will work)—not required if you want to alteration SSD footwear connected a Raspberry Pi 4 aliases Pi 400
  • Any type of outer SSD (such arsenic M.2, SATA, aliases NVMe/PCIe)
  • USB enclosure for nan SSD (if utilizing an soul SSD)

Boot Raspberry Pi 4 aliases 400 from SSD

Booting a Raspberry Pi from an SSD and utilizing it for imperishable retention tin supply important capacity improvements and reliability complete utilizing a microSD card. To footwear a Raspberry Pi 4 aliases Raspberry Pi 400 from SSD, you must alteration USB footwear by pursuing these steps:

  1. Connect nan microSD paper to different machine utilizing a paper reader.
  2. Download, install, and motorboat nan Raspberry Pi Imager instrumentality connected your Windows, Linux, aliases Mac system.
  3. Click nan Choose OS fastener and past take Misc Utility Images > Bootloader > USB Boot.
    choose usb bootloader nether mic utility
  4. Click nan Choose Storage fastener and prime nan microSD paper connected to your system.
  5. Click Write and hold for nan flash process to complete. It will return a fewer seconds only.
  6. After nan flash process, nan microSD paper is auto-ejected. Disconnect nan microSD paper from nan strategy and insert it into nan microSD slot of your Raspberry Pi 4 aliases 400.
  7. Connect nan powerfulness proviso to nan Raspberry Pi to move it on. The Pi will automatically publication and flash nan USB bootloader from nan connected microSD card. This takes a fewer seconds.
  8. When nan flash is successful, nan greenish LED ray connected nan Raspberry Pi starts blinking steadily. To corroborate further, link nan HDMI larboard to a display. If nan show shows a greenish screen, it indicates that nan flash process is complete.
  9. Turn disconnected nan Raspberry Pi and disconnect aliases region nan microSD card.

Boot Raspberry Pi 3 aliases Zero from SSD

To alteration SSD footwear connected Raspberry Pi 3, Zero W, aliases Zero 2 W, you request to flash nan modular Raspberry Pi OS connected nan microSD card, footwear nan Raspberry Pi, and make a fewer changes to nan configuration files to alteration USB (SSD) boot. The steps are arsenic follows:

  1. Insert a microSD paper into nan strategy and motorboat nan Raspberry Pi Imager tool.
  2. Click connected Choose OS and past prime Raspberry Pi OS (32-bit).
    write raspberry pi os connected sd paper ssd
  3. Click Choose Storage and prime nan microSD paper from nan disposable retention devices.
  4. Optionally, you tin click connected nan gear icon to bring up nan precocious options, past participate your network’s Wi-Fi specifications and alteration SSH.
  5. Click nan Write button.
  6. After nan flash process is complete, eject nan representation paper from nan system, insert it into nan Raspberry Pi 3, Zero, aliases Zero 2 W, and move it on.
  7. Connect a keyboard and a rodent to nan Raspberry Pi.
  8. After it boots up, log successful utilizing nan default username pi and password raspberry (unless you changed these successful nan Raspberry Pi Imager precocious options).
  9. Open nan Terminal window and tally nan pursuing commands. sudo apt update -y
    sudo apt full-upgrade -y
  10. After updating and upgrading nan packages, tally nan pursuing bid successful nan Terminal window. vcgencmd otp_dump | grep 17
  11. The output will show a code, 17:1020000a, showing that USB footwear is disabled. To alteration USB boot, we request to edit nan config.txt record by moving nan pursuing command. sudo nano config.txt
  12. Scroll to nan bottommost of nan file. For nan very past line, adhd nan pursuing code. program_usb_boot_mode=1 Press Ctrl + X, type Y and deed nan Enter cardinal to prevention nan changes. Alternatively, you whitethorn tally nan pursuing bid to adhd nan required codification to nan config.txt file and alteration USB footwear connected Raspberry Pi 3, Zero, aliases Zero 2 W. echo program_usb_boot_mode=1 | sudo tee -a /boot/config.txt
    enable usb footwear connected raspberry pi 3 zero w
  13. Restart nan Raspberry Pi and past tally nan pursuing bid to corroborate if USB footwear is enabled. vcgencmd otp_dump | grep 17
  14. If nan output shown is 17:3020000a, USB footwear is enabled. You tin now region nan microSD paper from nan Raspberry Pi 3, Zero, aliases Zero 2 W.
    usb footwear enabled connected raspberry pi 3
  15. Once USB footwear is enabled, you tin region nan codification from nan config.txt record utilizing nan nano editor aliases nan pursuing command. sudo sed -i 's/program_usb_boot_mode=1//g' /boot/config.txt

Learn much astir ways to edit nan boot/config.txt record connected Raspberry Pi.

Prepare Bootable Raspberry Pi SSD

To footwear nan Raspberry Pi Zero, Raspberry Pi 3, Raspberry Pi 4, aliases Raspberry Pi 400 via SSD, you must instal an operating strategy specified arsenic Raspberry Pi OS connected nan SSD by utilizing Raspberry Pi Imager (or nan Balena Etcher tool).

In lawsuit you are already moving an OS and services via microSD card, you tin clone nan SD paper to nan USB difficult thrust utilizing Balena Etcher.

After penning aliases cloning nan OS, you tin link nan SSD to nan Raspberry Pi via a USB larboard and tally connected nan Raspberry Pi. The Pi will automatically observe a USB thrust and footwear nan OS from nan SSD. If USB retention is not detected, nan Raspberry Pi will proceed to footwear from nan microSD paper (if connected).

To hole nan SSD for boot, travel these steps:

  1. Launch nan Raspberry Pi Imager instrumentality and link your outer SSD to your Windows, macOS, aliases Linux strategy via a USB port.
  2. Click Choose OS to prime nan desired OS from nan list. If you want to flash a downloaded OS image, you tin usage nan OS record by clicking connected nan Use Custom action and past selecting nan OS record from your system.
  3. Click Choose Storage to prime nan connected SSD retention media.
  4. Click nan Write button.
    flashing raspberry pi os connected outer ssd for usb footwear successful raspberry pi
  5. After nan OS is flashed connected nan SSD, dismount nan SSD thrust from nan strategy safely and past link nan USB SSD thrust to 1 of nan USB 3.0 aliases 2.0 ports connected your Raspberry Pi 4/400, Raspberry Pi 3 (or to Zero W aliases 2 W’s micro-USB larboard via a USB OTG adapter).
  6. Connect nan powerfulness proviso to move connected nan Raspberry Pi.
  7. The Raspberry Pi will cheque for a bootable SSD connected to nan USB larboard and footwear nan operating system.

Using an SSD arsenic Permanent Storage for Raspberry Pi

After booting nan operating strategy from nan outer SSD drive, you tin usage nan leftover abstraction successful nan SSD arsenic imperishable retention to shop different data.

To cheque nan disposable retention space, tally nan pursuing bid successful nan Terminal app.

df -h

If you are utilizing nan Desktop version of Raspberry Pi OS, unfastened File Manager and click connected Filesystem Root astatine nan apical of nan screen. You tin spot nan disposable retention successful nan bottom-right corner.

check nan disposable retention successful raspberry pi

Expand nan Filesystem

If you don't spot nan afloat capacity of your SSD drive, you tin travel these steps to grow nan record strategy connected Raspberry Pi.

  1. Open Terminal, and tally nan pursuing bid to update and upgrade packages and repositories. sudo apt update -y
    sudo apt upgrade -y
  2. Then type sudo raspi-config and property nan Enter key.
  3. Use nan down arrow keys to move nan action to Advanced Options and deed nan Enter key.
  4. Move nan action to Expand Filesystem and property nan Enter key.
  5. On nan adjacent screen, prime OK and property nan Enter key.
  6. After that, prime Finish and property nan Enter key.
  7. You will beryllium asked to reboot nan Raspberry Pi; prime Yes, and property nan Enter key to reboot.
  8. After rebooting, participate nan df -h bid to cheque nan disposable retention again. You should spot nan complete disposable SSD retention for usage connected your Raspberry Pi 3, 4, Zero W, aliases Zero 2 W.

Finally, usage nan rsync aliases cp command to move nan information (migrate data) from nan microSD paper to your SSD. Make judge to link nan microSD paper to nan Raspberry Pi.

Now that you person faster SSD storage, you tin usage it to build a individual unreality retention accessible from anywhere aliases to host a unafraid website connected Raspberry Pi.

You whitethorn besides build a Raspberry Pi NAS by installing Samba and usage nan SSD retention arsenic web retention successful your location aliases agency network.

More Storage With Faster Performance

Booting your Raspberry Pi pinch an SSD is highly recommended arsenic it is overmuch faster and much reliable than a microSD card. You tin usage immoderate outer SSD disposable connected nan market. This includes M.2, SATA, and NVMe/PCIe SSDs.

While nan process to alteration footwear is simply a spot analyzable connected Raspberry Pi 3 and Raspberry Pi Zero W / 2 W, it’s overmuch easier connected Raspberry Pi 4 and Raspberry Pi 400.

Source Tutorials