While I agree RonR's script might be the simplest solution, it's actually not too difficult to DIY.
See here for RonR's script. Running Raspbian from USB Devices : Made Easy
For a DIY solution, try this.
* Notes and instructions
- Stop your data recording and database services, so that nothing is lost or left open during the OS transfer.
- Use the Raspbian SD Card Copier to clone the working card to the USB drive, and be sure to check the New Partition UUIDs box.
- Remove and reconnect the USB drive so the OS will recognize it.
- Plug in a card reader with an empty FAT32 formatted micro SD card.
- Copy the files from the USB "boot" partition to the empty FAT32 card. *
- Edit /etc/fstab on the USB drive to mount the SD card as /boot. *
I've made a few assumptions here, that you are using Raspbian with the desktop GUI and the default pi user. For the instructions below we're also assuming the empty FAT32 micro SD card is named "SDcard" so adjust as needed.
Code: Select all
sudo cp -rv * /media/pi/SDcard
sudo nano /media/pi/rootfs/etc/fstab
Change the /boot mount from whatever PARTUUID it is, to /dev/mmcblk0p1 (replace PARTUUID=xxxxxxxx-01
Save the file and exit (^x y enter).
Shut down the system, replace the micro SD card in the system with the one from the card reader, make sure the USB drive is connected and fire it up. It should load the kernel and overlays from the SD card, then run the main OS from the USB drive.
Restart your data services and you're good to go!
My mind is like a browser. 27 tabs are open, 9 aren't responding,
lots of pop-ups...and where is that annoying music coming from?