cutedrummerboy
Posts: 6
Joined: Sun Aug 19, 2018 10:38 am

Raspberry pi 3 not rebooting from usb

Sun Aug 19, 2018 1:13 pm

hello, i am facing a strange problem. i am on latest raspbian lite, recently i burned one time programmable register via program_usb_boot_mode=1 in /boot/config.txt now it is working fine. i can boot from any usb ssd or flash drive without micro sd card inserted but if i want to reboot via command then it is not rebooting just showing me black screen. i have to power cycle the pi to boot again.

at first i thought that i have to set more boot wait for this. so i again apply program_usb_boot_timeout=1 but now boot time increased but same issue persist. after engaging reboot command it is not booting i have to power cycle it.

can anyone help me to resolve this issue.

cutedrummerboy
Posts: 6
Joined: Sun Aug 19, 2018 10:38 am

Re: Raspberry pi 3 not rebooting from usb

Mon Aug 20, 2018 7:15 am

So, not any other persons who are facing same issue??

User avatar
DougieLawson
Posts: 41898
Joined: Sun Jun 16, 2013 11:19 pm
Location: A small cave in deepest darkest Basingstoke, UK
Contact: Website Twitter

Re: Raspberry pi 3 not rebooting from usb

Mon Aug 20, 2018 7:28 am

Run sudo apt update && sudo apt -y dist-upgrade

That will get you new bootcode and a new kernel that will fix your problem.
Languages using left-hand whitespace for syntax are ridiculous

DMs sent on Twitter/LinkedIn will be answered next month.
Fake doctors - are all on my foes list.

The use of crystal balls and mind reading is prohibited.

cutedrummerboy
Posts: 6
Joined: Sun Aug 19, 2018 10:38 am

Re: Raspberry pi 3 not rebooting from usb

Mon Aug 20, 2018 7:49 am

Thank you DougieLawson, but i am already updated. There are no more update remain.

User avatar
DougieLawson
Posts: 41898
Joined: Sun Jun 16, 2013 11:19 pm
Location: A small cave in deepest darkest Basingstoke, UK
Contact: Website Twitter

Re: Raspberry pi 3 not rebooting from usb

Mon Aug 20, 2018 7:57 am

What kernel version do you have? What bootcode version?

uname -a
vcgencmd version


will tell us.
Languages using left-hand whitespace for syntax are ridiculous

DMs sent on Twitter/LinkedIn will be answered next month.
Fake doctors - are all on my foes list.

The use of crystal balls and mind reading is prohibited.

User avatar
B.Goode
Posts: 13217
Joined: Mon Sep 01, 2014 4:03 pm
Location: UK

Re: Raspberry pi 3 not rebooting from usb

Mon Aug 20, 2018 8:05 am

i want to reboot via command then it is not rebooting just showing me black screen. i have to power cycle the pi to boot again.
Although it isn't explicit in https://www.raspberrypi.org/documentati ... ootflow.md, perhaps this is expected behaviour?

Maybe that route through booting from mass storage is only invoked when the hardware is rebooted when power is applied? Maybe that route is not followed when simply restarting the running OS?

If this isn't the case I would welcome reference to explicit documentation explaining otherwise.

cutedrummerboy
Posts: 6
Joined: Sun Aug 19, 2018 10:38 am

Re: Raspberry pi 3 not rebooting from usb

Mon Aug 20, 2018 8:11 am

here is my kernel and bootcode version

Code: Select all

pi@Test-Server:~ $ uname -a
Linux Test-Server 4.14.62-v7+ #1134 SMP Tue Aug 14 17:10:10 BST 2018 armv7l GNU/Linux
pi@Test-Server:~ $ vcgencmd version
Aug 16 2018 17:31:30
Copyright (c) 2012 Broadcom
version 31e0613622dc2f2463bf3dd74e6c897d91201a4d (clean) (release)

User avatar
DougieLawson
Posts: 41898
Joined: Sun Jun 16, 2013 11:19 pm
Location: A small cave in deepest darkest Basingstoke, UK
Contact: Website Twitter

Re: Raspberry pi 3 not rebooting from usb

Mon Aug 20, 2018 8:13 am

B.Goode wrote:
Mon Aug 20, 2018 8:05 am
Although it isn't explicit in https://www.raspberrypi.org/documentati ... ootflow.md, perhaps this is expected behaviour?
No, it's a bug in kernel/bootcode. I thought it had been resolved with a recent update, perhaps not.
Languages using left-hand whitespace for syntax are ridiculous

DMs sent on Twitter/LinkedIn will be answered next month.
Fake doctors - are all on my foes list.

The use of crystal balls and mind reading is prohibited.

cutedrummerboy
Posts: 6
Joined: Sun Aug 19, 2018 10:38 am

Re: Raspberry pi 3 not rebooting from usb

Mon Aug 20, 2018 8:36 am

DougieLawson wrote:
Mon Aug 20, 2018 8:13 am
B.Goode wrote:
Mon Aug 20, 2018 8:05 am
Although it isn't explicit in https://www.raspberrypi.org/documentati ... ootflow.md, perhaps this is expected behaviour?
No, it's a bug in kernel/bootcode. I thought it had been resolved with a recent update, perhaps not.
hmmm. i thought i have done some mistake. let us hope it will be fixed in some recent update.

LTolledo
Posts: 6237
Joined: Sat Mar 17, 2018 7:29 am
Location: Anime Heartland

Re: Raspberry pi 3 not rebooting from usb

Mon Aug 20, 2018 9:27 am

Ahhh.... the "not rebooting" type.... I think one of my setup suffered from that before.

Just to confirm, after you issued reboot command (either by GUI or command line), does the red LED turn off?

normally it wouldn't turn off during reboot, or even after issuing shutdown command..
"Don't come to me with 'issues' for I don't know how to deal with those
Come to me with 'problems' and I'll help you find solutions"

Some people be like:
"Help me! Am drowning! But dont you dare touch me nor come near me!"

cutedrummerboy
Posts: 6
Joined: Sun Aug 19, 2018 10:38 am

Re: Raspberry pi 3 not rebooting from usb

Mon Aug 20, 2018 12:01 pm

LTolledo wrote:
Mon Aug 20, 2018 9:27 am
Ahhh.... the "not rebooting" type.... I think one of my setup suffered from that before.

Just to confirm, after you issued reboot command (either by GUI or command line), does the red LED turn off?

normally it wouldn't turn off during reboot, or even after issuing shutdown command..
No it is remain on only green light and ethernet port lights are turnd off

User avatar
HawaiianPi
Posts: 6675
Joined: Mon Apr 08, 2013 4:53 am
Location: Aloha, Oregon USA

Re: Raspberry pi 3 not rebooting from usb

Mon Aug 20, 2018 7:19 pm

DougieLawson wrote:
Mon Aug 20, 2018 8:13 am
... it's a bug in kernel/bootcode. I thought it had been resolved with a recent update, perhaps not.
Actually, it's a compatibility problem with the USB drive the OP is using.

Boot, but no reboot is a common issue with USB mass storage devices that are not fully compatible with the Pi's boot-loader. Some incompatible devices will not boot at all, while others will cold boot fine but will not reboot.

I've had no trouble with reboots from any of my Pi3B(+) computers that boot from USB SSD drives (with the adapter linked below).
cutedrummerboy wrote:
Mon Aug 20, 2018 8:36 am
hmmm. i thought i have done some mistake. let us hope it will be fixed in some recent update.
There is no software fix for this, as the boot-loader is hard coded into the SoC when it's manufactured. The only way to update the boot-loader is to use a FAT32 formatted micro-SD card with the latest bootcode.bin file on it (just that one file, with nothing else on the card). The boot-loader on the SoC itself can't be updated without re-masking and manufacturing a new chip, which is an expensive process (note that the boot-loader in the newer 3B+ model has been improved, although it's still not 100% compatible with all USB mass storage devices).

The bootcode.bin only SD card makes no permanent change to the system, so if it works for you, you'll need to leave that card in the system. I know that many here are obsessed with no-SD-card-boot, but having an SD card in the system is actually better, because it eliminates the 5 second boot delay, and the additional OS overhead of constantly polling the empty SD card slot. With only bootcode.bin on the card the OS is still booting and running entirely from the USB drive, so the SD card can be mounted as read-only, or even unmounted after boot, which means the micro-SD card should never wear out or fail. Even though I can boot with no SD card, I leave an empty (FAT32) micro-SD card in the system to resolve the delay and polling issues.

I have tested USB boot of the 2018-06-27 Raspbian release on both Pi3B and 3B+ models using a Silicon Power model A55 SATA III SSD with an ELUTENG USB3 to SATA III adapter cable, and both the full Desktop and Lite versions boot and reboot fine on my systems (before and after updates). I have had the same reboot trouble in the past with a different USB3-SATA3 adapter, so the problem is not with Raspbian, it's with the boot-loader and certain USB mass storage devices.

The current Master branch bootcode.bin can be downloaded from: https://github.com/raspberrypi/firmware/raw/master/boot/bootcode.bin
Grab that and place it on an otherwise empty FAT32 formatted micro-SD card, put that card in your Pi3B, and see if it resolves your reboot issue.
My mind is like a browser. 27 tabs are open, 9 aren't responding,
lots of pop-ups, and where is that annoying music coming from?

User avatar
HawaiianPi
Posts: 6675
Joined: Mon Apr 08, 2013 4:53 am
Location: Aloha, Oregon USA

Re: Raspberry pi 3 not rebooting from usb

Mon Sep 03, 2018 9:58 am

I have done some further testing with various SSD models and USB adapters I have at my disposal, and I found that the newer firmware does fix reboot issues with one particular adapter+SSD combo I have on my Pi 3B+ model. So it appears that there is, in fact, a firmware fix, at least for some devices.

Symptoms were, cold boot fine, reboot would fail with no power or activity LED (note that the red power LED was off, but it was not a power problem). Raspbian Stretch Lite 2018-06-27. Again, this was with one particular combination of drive + USB external enclosure, and only on the newer Pi3B+ model (older Pi3B had no reboot trouble). Not sure if the problem is with the enclosure or SSD, but after a Raspbian full-upgrade the problem went away.

It is especially curious it only happened on the 3B+ model, since that supposedly has an improved boot-loader.

Since this only happened on the newer 3B+ model, it doesn't apply to the OP which involved the original 3B model, but I thought I'd post about it because my assertation above that there is no software fix for USB reboot issues was not entirely correct. A full upgrade *might* help if you have a Pi3B+ model with the symptoms I had.
My mind is like a browser. 27 tabs are open, 9 aren't responding,
lots of pop-ups, and where is that annoying music coming from?

bobg
Posts: 11
Joined: Mon Dec 26, 2011 8:56 am
Location: London, UK

Re: Raspberry pi 3 not rebooting from usb

Thu Jun 11, 2020 8:39 pm

Thank you HawaiianPi, I have today had this issue with the latest Raspbian, and your solution resolved it.

bobg
Posts: 11
Joined: Mon Dec 26, 2011 8:56 am
Location: London, UK

Re: Raspberry pi 3 not rebooting from usb

Sat Jun 13, 2020 3:00 pm

As I now need an SD card in the RPi I have put in a "standard" SD card and edited /boot/cmdline.txt to point at /dev/sda2 and modified the /etc/fstab file on the hard disk to point at /dev/mmcblk0p1 and /dev/sda2
Works nicely and reboots nicely

User avatar
HawaiianPi
Posts: 6675
Joined: Mon Apr 08, 2013 4:53 am
Location: Aloha, Oregon USA

Re: Raspberry pi 3 not rebooting from usb

Sun Jun 14, 2020 1:56 am

bobg wrote:
Sat Jun 13, 2020 3:00 pm
As I now need an SD card in the RPi I have put in a "standard" SD card and edited /boot/cmdline.txt to point at /dev/sda2 and modified the /etc/fstab file on the hard disk to point at /dev/mmcblk0p1 and /dev/sda2
Works nicely and reboots nicely
Why?

Didn't the bootcode.bin only SD card work?

Are you using a Raspberry Pi 3B or 3B+ model?

Also, you should not use device nodes (/dev/sda2) in cmdline.txt or fstab, because those could change if you ever connect another USB drive. Raspbian defaults to PARTUUID now, which is a better way to identify individual drives and partitions.
My mind is like a browser. 27 tabs are open, 9 aren't responding,
lots of pop-ups, and where is that annoying music coming from?

bobg
Posts: 11
Joined: Mon Dec 26, 2011 8:56 am
Location: London, UK

Re: Raspberry pi 3 not rebooting from usb

Sun Jun 14, 2020 10:53 am

The bootcode.bin worked and RPi 3B fully rebooted, however the 5 second delay still occurred. Hence the move forward to the "standard SD card".
The RPi build of 2020-05-27 has issues with PARTUUID (see my thread viewtopic.php?f=66&t=276634) hence my fall back to /dev/...

I am aware of the reasons for PARTUUID but for a while the UUID has not been unique on sd clones. I suspect the UUID is now unique and passed the issue onto PARTUUID. Fortunately I remember /dev/... (and its perils ;) ).

Return to “Troubleshooting”