firmware icon indicating copy to clipboard operation
firmware copied to clipboard

Boot from USB-SSD only works once

Open lflare opened this issue 9 years ago • 8 comments

Hello,

Recently, I've made the switch from using SD cards to a SSD drive through USB for various reasons and the first thing I noticed that upon data migration from the SD card to the SSD drive, my Raspberry Pi 3 Model B server only manages to boot up once. Any subsequent reboots, shutdowns-and-boot, power-off-and-on fails to bring up the OS after the initial boot.

I tried to find out what was causing the issue and I think I narrowed it down to possibly the unmounting sequence during poweroff using shutdown or reboot. Basically, in order for me to reboot the server, I have to manually connect the SSD drive to my Macbook, mount the two partitions, unmount the two partitions, eject the drive, reconnect the drive to the Pi 3B and plug the power cable back in.

lflare avatar Oct 17 '17 16:10 lflare

What about if you put in an SD card with just bootcode.bin on it? Also try adding a file TIMEOUT to the SD card as well...

Gordon

ghollingworth avatar Oct 18 '17 10:10 ghollingworth

I tried that before, it still doesn't work on subsequent reboots. If it helps, I'm using the Samsung T5 Portable SSD without any encryption or whatnot. For now, my temporary workaround this issue is to simply separate the boot partition onto a SD card that points the root to my SSD drive.

lflare avatar Oct 19 '17 02:10 lflare

It sounds like the drive is being left in some strange state... Does plugging it into a Raspberry Pi running Raspbian also 'fix' the problem or is it only the Mac that can do it?

On Thu, Oct 19, 2017 at 3:23 AM Amos Ng [email protected] wrote:

I tried that before, it still doesn't work on subsequent reboots. If it helps, I'm using the Samsung T5 Portable SSD without any encryption or whatnot. For now, my temporary workaround this issue is to simply separate the boot partition onto a SD card that points the root to my SSD drive.

— You are receiving this because you commented.

Reply to this email directly, view it on GitHub https://github.com/raspberrypi/firmware/issues/891#issuecomment-337781002, or mute the thread https://github.com/notifications/unsubscribe-auth/AB9CHL5bws3uwplVmin7x1Khy6DkY0rnks5strK3gaJpZM4P8d68 .

--

Director of Software Engineering, Raspberry Pi (Trading) Limited t: +44 (0) 1223 322633 m: +44 (0) 7450 946289 e: [email protected] w: www.raspberrypi.org

ghollingworth avatar Oct 19 '17 12:10 ghollingworth

No clue, I've mitigated this by having the boot partition stay on a SD card.

lflare avatar Oct 19 '17 12:10 lflare

I tried these steps and it worked. I was using a small HDD. https://www.maketecheasier.com/boot-up-raspberry-pi-3-external-hard-disk/ The MICRO SD card must remain in the Pi.

smokingwheels avatar Oct 23 '17 11:10 smokingwheels

I experience the same problem. Mounting the SSD to a MAC, Linux or Windows system and unmounting it fixes the problem for just one boot. Any following subsequent boot shows up with the same error again. Putting an SD card into the device will not solve the problem for me. This whole SSD thing was meant to be a replacement for the SD cards!

Draganis avatar Mar 19 '18 16:03 Draganis

And it seems i have found something. I was using an USB3 to SATA adapter with only one USB plug to connect my SSD to the pi when i encountered the error. Now i was trying to plug this adapter into a seperately powered USB hub that is connected to my pi. Finally my pi reboots without having this issue. Seems like the SSD gets shut off cold without being properly unmounted during the shutdown sequence when it is not seperately powered. I also bought a new double plugged USB2 to SATA adapter to plug in one plug (data) to the pi and one plug (power) to a charger and the problem didn't show up either. So i guess this whole issue is a powering problem.

I am trying a cable like this one to bridge it: http://amzn.to/2IAO6rV

Draganis avatar Mar 19 '18 16:03 Draganis

@LFlare

I tried that before, it still doesn't work on subsequent reboots. If it helps, I'm using the Samsung T5 Portable SSD without any encryption or whatnot. For now, my temporary workaround this issue is to simply separate the boot partition onto a SD card that points the root to my SSD drive.

I succeeded booting from Samsung T5 SSD (I have the 512GB version) without sdcard after setting

program_usb_boot_timeout=1

This increases the USB boot timeout which is per default only 2 seconds - not enough for the T5.

After this step I was able to reliable boot and reboot (and restart) the Raspi 3 from SSD without sdcard. (with Raspbian Stretch 2018-06-27)

BUT: Since the raspi is looking all the time for an sdcard you will end up with a higher cpu load due to a lot of IRQs coming in (kworker process consumes about 8% CPU in idle!). So: Just put an empty sdcard into the slot to avoid this issue! See https://www.raspberrypi.org/forums/viewtopic.php?t=211912

caiacoa avatar Jul 04 '18 07:07 caiacoa