I am using the following configuration:
- Raspberry Pi 4 (RPi4) with bootable SD (SD1) card, configured with raspi-config to use boot priority 1) USB drives, 2) SD card
- SSD M.2 disk (SSD1) connected through a USB connected SATA interface, where SSD1 is bootable
- HDD disk connected through USB (HDD1), that is non bootable (only for data)
- Arduino board (ARD1), connected through USB.
I have done the following tests, trying to boot up from full power down:
- Without any USB stuff connected, the RPi4 boots fine from SD1
- With only the SSD1 connected through USB, the RPi4 boots fine from SSD1
- With the SSD1 and HDD1 plugged simultaneously, the RPi4 does not boot from SSD1, but falls back to SD for booting. However, booting does happen, and HDD1 and SSD1 are visible once boot has taken place. So I do not think that this is a power issue.
- With SSD1 and ARD1 plugged in simultaneously, booting from the SSD1 fails, but booting from SD1 works (similarly to the previous case), and ARD1 is visible after boot, so same thing, I do not think that this is a power issue.
So to me it looks like RPi4 is confused about which USB device it should attempt to boot from when attempting to boot from USB first, SD second, and it seems that, if it cannot boot from "the first" USB device it finds (and unluckily it seems that SSD1 is not "the first" in any of my several USB devices cases), RPi4 falls back to booting from the SD card.
Any idea how to solve this? Is there a way I can set in the boot setup the UUID of the disk / partition that it should boot from? I do not see such option in raspi-config.
I have been looking for quite a while on the internet and on SE for an answer to this, and it seems like an option may be to "start booting" from the SD1 boot partition, but have it point to the filesystem on SSD1; at least, this is how I understand the solution described in: How to Boot from one usb drive but have multiple drives connected to hub , ie setting the UUID of the bootable USB device in the SD1 boot configuration. However, in this case, the RPi still "starts booting" from the SD card, before moving to the SSD1 disk if I understand right, which is a situation I would like to avoid (I would like the RPi4 to avoid SD1 altogether and do the full boot from SSD1 without ever touching SD1).
Any idea how I can solve this?