Page 1 of 1

RPi3 boot from usb

Posted: Fri Sep 18, 2020 2:05 am
by Lxw2015
according to this link
https://www.raspberrypi.org/documentati ... des/msd.md
once I set RPi3 boot from USB, then it won't boot from SD card any more. is my understanding wrong or it is designed that way?
I can't believe this. Why not like other system if USB boot failed then try SD card?

thanks
LXW

Re: RPi3 boot from usb

Posted: Fri Sep 18, 2020 2:55 am
by fruitoftheloom
Lxw2015 wrote:
Fri Sep 18, 2020 2:05 am
according to this link
https://www.raspberrypi.org/documentati ... des/msd.md
once I set RPi3 boot from USB, then it won't boot from SD card any more. is my understanding wrong or it is designed that way?
I can't believe this. Why not like other system if USB boot failed then try SD card?

thanks
LXW

https://www.raspberrypi.org/documentati ... ootflow.md

Re: RPi3 boot from usb

Posted: Fri Sep 18, 2020 2:58 am
by W. H. Heydt
Lxw2015 wrote:
Fri Sep 18, 2020 2:05 am
according to this link
https://www.raspberrypi.org/documentati ... des/msd.md
once I set RPi3 boot from USB, then it won't boot from SD card any more. is my understanding wrong or it is designed that way?
I can't believe this. Why not like other system if USB boot failed then try SD card?
Your understanding is incorrect. Once you enable boot from USB, it will try to boot from an SD card, and if that isn't present or doesn't contain the files to boot, *then* it will look for an attached, bootable, USB device.

On the Pi4B you can set the boot order, but that's because the Pi4B has additional EEPROM storage to hold the extended boot code.

Re: RPi3 boot from usb

Posted: Fri Sep 18, 2020 3:03 am
by kerry_s
Lxw2015 wrote:
Fri Sep 18, 2020 2:05 am
according to this link
https://www.raspberrypi.org/documentati ... des/msd.md
once I set RPi3 boot from USB, then it won't boot from SD card any more. is my understanding wrong or it is designed that way?
I can't believe this. Why not like other system if USB boot failed then try SD card?

thanks
LXW
if you remove the usb & insert a sd card it will boot from the sd card.

Re: RPi3 boot from usb

Posted: Fri Sep 18, 2020 3:50 am
by DirkS
kerry_s wrote:
Fri Sep 18, 2020 3:03 am
if you remove the usb & insert a sd card it will boot from the sd card.
As said by @W.H.Heydt it will try to boot from SD first

Re: RPi3 boot from usb

Posted: Fri Sep 18, 2020 5:35 pm
by Lxw2015
thank you all. read the link again. I did found it's my miss understanding. it says OPT can't undo. that's why I doubt my self.

Re: RPi3 boot from usb

Posted: Fri Sep 18, 2020 6:46 pm
by W. H. Heydt
Lxw2015 wrote:
Fri Sep 18, 2020 5:35 pm
thank you all. read the link again. I did found it's my miss understanding. it says OPT can't undo. that's why I doubt my self.
Correct. Once a "One Time Programmable" (OTP) bit is set, you can't unset it. Hence, it's a good idea that it doesn't prevent booting from an SD card. The Pi4B is more complex. The code that governs boot order is in an EEPROM and can--therefore--be changed. The preferred setting of boot order is still SD card first, though.

Re: RPi3 boot from usb

Posted: Sat Sep 19, 2020 1:24 am
by RonR
@Lxw2015,

If you don't want to set the OTP bit or find you still cannot boot from USB after doing so: Running Raspbian from USB Devices : Made Easy

Re: RPi3 boot from usb

Posted: Sat Sep 26, 2020 7:25 pm
by Lxw2015
thanks for you all.
I think boot from USB OTP should be set by default. it's no harm. and made life easier.
if there is SD card inserted, then boot from DS card. if no SD card present then boot from USB. I did not see any disadvantage about this.
any opinion about this?
thanks
LXW

Re: RPi3 boot from usb

Posted: Sat Sep 26, 2020 7:35 pm
by RonR
Lxw2015 wrote:
Sat Sep 26, 2020 7:25 pm
I think boot from USB OTP should be set by default. it's no harm. and made life easier.
if there is SD card inserted, then boot from DS card. if no SD card present then boot from USB. I did not see any disadvantage about this.

That's the case on the Raspberry Pi 3B+.

Re: RPi3 boot from usb

Posted: Sat Sep 26, 2020 7:36 pm
by W. H. Heydt
Lxw2015 wrote:
Sat Sep 26, 2020 7:25 pm
thanks for you all.
I think boot from USB OTP should be set by default. it's no harm. and made life easier.
It is...on the Pi3B+.

Bear in mind that the Pi2Bv1.2 uses the same SoC as the Pi3B/Pi3B+ (I believe that both the Pi3B and Pi2Bv1.2 have migrated to the BCM2837B0, which started out on just the Pi3B+) so the bit can be set on those boards, as well. It's just that nobody seems to expect to boot any version of Pi2B directly from a USB MSD.

Re: RPi3 boot from usb

Posted: Sun Sep 27, 2020 6:32 pm
by Lxw2015
W. H. Heydt wrote:
Sat Sep 26, 2020 7:36 pm
Lxw2015 wrote:
Sat Sep 26, 2020 7:25 pm
thanks for you all.
I think boot from USB OTP should be set by default. it's no harm. and made life easier.
It is...on the Pi3B+.

Bear in mind that the Pi2Bv1.2 uses the same SoC as the Pi3B/Pi3B+ (I believe that both the Pi3B and Pi2Bv1.2 have migrated to the BCM2837B0, which started out on just the Pi3B+) so the bit can be set on those boards, as well. It's just that nobody seems to expect to boot any version of Pi2B directly from a USB MSD.
I'm not quite understand what you mean. for Pi2B, if you don't expect boot from USB MSD, then just insert SD card into Pi2B. then it boot from SD card.

Re: RPi3 boot from usb

Posted: Sun Sep 27, 2020 9:49 pm
by W. H. Heydt
Lxw2015 wrote:
Sun Sep 27, 2020 6:32 pm
W. H. Heydt wrote:
Sat Sep 26, 2020 7:36 pm
Lxw2015 wrote:
Sat Sep 26, 2020 7:25 pm
thanks for you all.
I think boot from USB OTP should be set by default. it's no harm. and made life easier.
It is...on the Pi3B+.

Bear in mind that the Pi2Bv1.2 uses the same SoC as the Pi3B/Pi3B+ (I believe that both the Pi3B and Pi2Bv1.2 have migrated to the BCM2837B0, which started out on just the Pi3B+) so the bit can be set on those boards, as well. It's just that nobody seems to expect to boot any version of Pi2B directly from a USB MSD.
I'm not quite understand what you mean. for Pi2B, if you don't expect boot from USB MSD, then just insert SD card into Pi2B. then it boot from SD card.
When the Pi2B was released--now known as the Pi2Bv1.1--it used the BCM2836 SoC. That SoC does not contain boot from USB MSD code at all. It can do "hybrid" booting, where part of what is need is on an SD card and the rest on on a USB MSD. As a cost saving issue, the Pi2B was updated to use the BCM2837 SoC--the one used on the Pi3B--and the newer version is the Pi2Bv1.2. Because the Pi2Bv1.2 uses the same SoC as the Pi3B, it contains the ROM code to boot from a USB attached MSD and once you set the OTP bit, it will do so. This is a part of why knowing *which* Pi2B you're looking at matters.

What it amounts to is that the Pi2Bv1.2 is a slower (900MHz, default) version of the Pi3B, without on-board WiFi. This is not something that appeals to everybody, but there are some good uses for it. At least, I think there are some good uses for it.

I've never heard of anyone actually do USB MSD booting on a Pi2Bv1.2, but I feel that it is important to remember that it *can* be done.

Perhaps some day, I'll do it...just so I can say that it's been done....