I am somewhat new to Raspberry Pi.
I would like to make the 5 TB WD My Book USB drive the boot drive with the
Raspberry Pi OS FULL (32-Bit) image. If I use the
Raspberry Pi Imager to configure the USB Drive, I encounter an error on the firstboot because of insufficient privileges to create partitions. I have also noticed that the
Raspberry Pi Imager converts the drive to MBR. This renders 3TB of the drive unusable.
I am going to be using some development tools that only work when installed to the boot drive.
Thus far, I have had no luck what-so-ever on using a 5 TB GPT drive as a boot drive. I can use it as a data drive.
Most of the problems are partition issues.
What I have tried
When the the `Imager` on the WD My_Book 5 TB drive (with no no partitions); an attempt is made during the firstboot to resize the /dev/sda2. This fails and leaves the drive in an error state. The error that appears in GParted is: Superblock checksum does not match the superblock while trying to open /dev/sda2. Couldn't find valid filesystem superblock.
- Issued the following command:
$sudo su - root
Removed all existing partitions from the USB drive in
Set the following options:
Operating System: RASPBERRY PI OS FULL (32-BiT) Storage: WD MY_BOOK
Imagersuccessfully writes and verifies to the USB Drive. The following message appears:
Write Successful Raspberry Pi OS Full (32-bit) has been written to WD My_Book_25EE. You can now remove the SD card from the reader
Removed the SD Card and Clicked OK.
Re-booted the Raspberry Pi.
The Raspberry Pi endlessly cycles between: Trying Boot Mode USB-MSD and Trying Boot Mode SD
Subsequent re-boot produces the following error: Failed running firstboot: Partition table resize of the root partition (/dev/sda2) failed
Manually define Partitions
I have worked through partitioning and formatting the partitions of the 5 TB USB drive. My steps are below.
- Unmounted the drive from the Raspberry Pi
- Opened a terminal and started a
$ sudo parted
- Selected the
/dev/sdadrive to partition.
(parted) select /dev/sda
- Created a GPT partition table.
(parted) mklabel gpt
- Created new partitions on the drive.
(parted) mkpart os fat32 0gb 750gb (parted) mkpart dev-ntfs 750gb 50% (parted) mkpart dev-ext4 50% 100%
- Formatted the new partitions.
$ sudo mkfs.ntfs -L dev-ntfs -Q /dev/sda2 $ sudo mkfs.ext4 -L dev-ext4 /dev/sda3
- Powered down the Raspberry Pi and restarted.
- Temporarily remounted the partitions under
$ cd /mnt $ sudo mkdir dev-ntfs $ sudo mkdir dev-ext4
- Temporarily mount the partitions.
$ sudo mount /dev/sda2 /mnt/dev-ntfs $ sudo mount /dev/sda3 /mnt/dev-ext4
- Obtain the
PARTUUIDfor the new partitions.
$ sudo blkid
- At a stand-still until I can find a way to install the OS on the USB.
Unmounted and deleted all partitions from the USB Drive in
rpi-cloneas per https://github.com/billw2/rpi-clone
Set the boot-order in
This clones the SD-Card to the USB but renders the majority of the USB drive unallocated and unusable.
The Raspberry Pi will not boot from the USB drive.
Test Case with 128 GB USB (This Works)
As a test case I setup a 128 GB USB stick by using the
Raspberry Pi Imager.
- Boot the Raspberry Pi 4B from an SD Card.
- Make sure the Raspberry Pi 4B is up-to-date.
$ sudo apt-get ugrade -y $ sudo rpt-eeprom-update
My Raspberry Pi 4B was already up-to-date from attempts with the GPT drive.
Plug the 128 GB stick into a USB3 port.
Raspberry Pi Imagerto burn the OS onto the 128 GB USB stick.
When the imager completes the verify of the write to the 128 GB USB, shut down the Raspberry Pi 4B.
Take the SD-Card out of the Raspberry Pi 4B.
Power the Raspberry Pi 4B on.
- I would like to setup a USB GPT drive with desired partitions.
I have setup partitions on the USB GPT that ensures all partitions are < 2 TB and fat32.
I would like to:
Setup the desired partitions manually on a USB GPT drive with a predefined
bootfrom a working SD-Card to the predefined USB GPT drive.
Boot from the GPT USB Drive and by-pass the automatic resize of the GPT USB Drive during firstboot (or any boot).