0

I have a Raspberry Pi 3 model B with no microSD card (the OTP bit is set). It can boot from an SSD connected via a USB2 SATA adapter. However, when a 3½-inch USB3 HDD is connected, the Pi doesn't boot. The HDD has it's own power supply. I also tried plugging both the SSD and HDD into a powered USB2 hub (this one). In all cases, if the HDD is disconnected, the Pi boots fine and I can connect the HDD later and access files. However, if the HDD is connected at boot time, it fails to boot. There is no HDMI output either way--only ssh (not sure why, but I plan to use it headless anyhow). The SSD is Ubuntu 20.04.2 (link).

Here are the disk details. The boot SSD is /dev/sda and the HDD is /dev/sdb.

$ sudo sfdisk -l /dev/sd?
Disk /dev/sda: 119.25 GiB, 128035676160 bytes, 250069680 sectors
Disk model: Name            
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0x4ec8ea53

Device     Boot  Start       End   Sectors  Size Id Type
/dev/sda1  *      2048    526335    524288  256M  c W95 FAT32 (LBA)
/dev/sda2       526336 250069646 249543311  119G 83 Linux


Disk /dev/sdb: 10.94 TiB, 12000105070592 bytes, 23437705216 sectors
Disk model: Elements 25A3   
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: gpt
Disk identifier: 81FED0C1-66DF-A446-9696-6F8AF95E27DF

Device        Start         End     Sectors  Size Type
/dev/sdb1      2048        4095        2048    1M Linux filesystem
/dev/sdb2      4096     1054719     1050624  513M Linux filesystem
/dev/sdb3   1054720    84940799    83886080   40G Linux filesystem
/dev/sdb4  84940800 23437705182 23352764383 10.9T Linux filesystem

The last HDD partition is LUKS-encrypted (begins 4c 55 4b 53 ba be 00 02 00 00 00 00 00 00 40 00) and the other 3 all begin with 8MB of zeros.

In summary, I don't think USB power is an issue because the HDD and the USB hub are both powered, and none of the HDD partitions should appear bootable.

User RabidTunes describes a very similar problem (Raspberry pi with HDD and SSD not booting on reboot) but the solution proposed there involves additional hardware, which I would like to avoid.

How can have both drives connected at boot/reboot?

1 Answer 1

1

Maybe this is due to the enumeration order, and the Pi is trying to boot from the first disk it finds.

i.e. when both are connected it's finding the HDD first, and trying to boot from that.

Try switching the USB ports the two disks are connected to?

3
  • Great idea, but unfortunately, swapping the drives' USB plugs didn't help. I also tried the SSD directly on the Pi and the HDD through the USB hub, but it still won't boot.
    – bitinerant
    Jun 16, 2021 at 16:27
  • Well, I was wrong. I found a USB plug combination that works consistently! When the two USB plugs are swapped, it never boots. I didn't realize it was so finicky. I have labeled the USB sockets "boot SSD" and "non-boot HDD". Thank you, Douglas!
    – bitinerant
    Jun 16, 2021 at 21:13
  • Glad I was able to help! I thought the boot routine might be dumb enough to just try the first usb mass storage it found. Jun 16, 2021 at 21:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.