Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

USB Boot broken in 11.2 #2969

Closed
fencer opened this issue Dec 5, 2023 · 18 comments
Closed

USB Boot broken in 11.2 #2969

fencer opened this issue Dec 5, 2023 · 18 comments
Labels
board/raspberrypi Raspberry Pi Boards bug stale usb-ssd USB SSD related issue

Comments

@fencer
Copy link

fencer commented Dec 5, 2023

Describe the issue you are experiencing

Since upgrading to 11.2 USB boot on RPI Compute 4 no longer works. In the UBOOT screen I get an erorr

... XHCI timeout on event 33... cannot recover. 
Bug at driver/usb/host/hci-ring.c:481/xhci_wiat_for_evet()!
Bug!
resetting ...

PXL_20231205_230827562 TS_exported_8292_1701817783918

What operating system image do you use?

rpi4-64 (Raspberry Pi 4/400 64-bit OS)

What version of Home Assistant Operating System is installed?

11.2

Did you upgrade the Operating System.

Yes

Steps to reproduce the issue

  1. Update to version 11.2
  2. Reboot

Anything in the Supervisor logs that might be useful for us?

N/A

Anything in the Host logs that might be useful for us?

N/A

System information

RaspberryPI 4 Compute Module with USB Boot

Additional information

No response

@fencer fencer added the bug label Dec 5, 2023
@TravisWilder
Copy link

USB SSD on RPi4 (not CM) works for me

@agners agners added the board/raspberrypi Raspberry Pi Boards label Dec 6, 2023
@agners
Copy link
Member

agners commented Dec 6, 2023

@fencer what type of USB disk/adapter are you using?

@agners agners added the usb-ssd USB SSD related issue label Dec 6, 2023
@fencer
Copy link
Author

fencer commented Dec 6, 2023

It's a Manhattan 130103. This is the same enclosure I had been using on the RPI3 and then CM4 (after #1577)

In the meantime, what are my options to recover/downgrade? Do I need a fresh install?

@agners
Copy link
Member

agners commented Dec 6, 2023

It seems that the boot loader is not able to talk to the SSD, in such cases the A/B fallback doesn't even work 😢 Since USB is notoriously unreliable at early boot, we recommend using a SD card as boot media for HAOS and move only the data to the USB attached SSD disk.

You might be able to get it to boot by changing things around: Use a different USB port, use a powered hub in-between, or plug it in later (start the Pi and plug in the USB disk a bit later). In case you can make it boot, you can downgrade using ha os update --version 11.1).

@TravisWilder
Copy link

I can confirm that my SSD USB is booting only on the upper USB Port not on the lower :)

@fencer
Copy link
Author

fencer commented Dec 6, 2023

I can confirm that my SSD USB is booting only on the upper USB Port not on the lower :)

Keep in mind that the peripherals on the RPI4 are different from CM4.

@TekFan
Copy link

TekFan commented Dec 6, 2023

It seems that the boot loader is not able to talk to the SSD, in such cases the A/B fallback doesn't even work 😢 Since USB is notoriously unreliable at early boot, we recommend using a SD card as boot media for HAOS and move only the data to the USB attached SSD disk.

Reading this, I didn't dare upgrading to 11.2 yet...
So, what would be the best procedure to migrate from USB boot to SD boot ?

@teppic01
Copy link

teppic01 commented Dec 7, 2023

Hi,
sorry im confused. Is this a problem on raspberry pi 400 with ssd too?
i do not like to change back to sd, because of there life time limit...
T.

@imerr
Copy link

imerr commented Dec 11, 2023

Same issue here, using a different usb enclosure made it work again. The enclosure itself + ssd is working on a different system though. The problematic enclosure reports as:

usb 4-1: new SuperSpeed USB device number 4 using xhci_hcd
usb 4-1: New USB device found, idVendor=174c, idProduct=5106, bcdDevice= 0.01
usb 4-1: New USB device strings: Mfr=2, Product=3, SerialNumber=1
usb 4-1: Product: AS2105
usb 4-1: Manufacturer: ASMedia

@odis68
Copy link

odis68 commented Dec 14, 2023

I have RaspberryPI 3B+ . Preliminary load with SD , The whole system is on SSD. After the update at 11.2, he stopped loading. Solution - I copied the preliminary download files from SSD to SD.

@ohessel
Copy link

ohessel commented Dec 18, 2023

I have RaspberryPI 3B+
Took me some time, but keeping 2 USB RF sticks unplugged until the SSD started booting did the trick.

..USB seems to be little broken in this version - I experience this: #2995 in addition.

@GHGiampy
Copy link

Also related #2977

@criptych
Copy link

criptych commented Dec 30, 2023

Just experienced this after upgrading on a CM4IO and I'm not even using any USB devices; it boots and runs entirely from an SD card.

Update: I was able to boot after commenting otg_mode=1 in config.txt; n.b. as I understand that also disables USB host mode, but for anyone (like me) who isn't using external USB devices, it may be a viable workaround.

Update 2: Adding dtoverlay=dwc2,dr_mode=host seems to enable use of USB devices and allow the system to boot. (otg_mode is still disabled/commented).

@PavelKuzub
Copy link

WORKAROUND TO RECOVER AND BOOT

I have got the same error having the same setup as OP - Rpi Compute Module 4 with HASS OS on USB bootable flash disk (Samsung).
None of the fiddling with config.txt and cmdline.txt helped to boot off USB.
I had a spare hardware and USB stick to play around with and I eventually recovered with this method:

  • Downloaded previously stable 2023.11.1 HAOS image for my board haos_rpi4-64-11.1.img.xz from Releases page.
  • Flashed .img into a SPARE Test USB stick using "Raspberry Pi Imager" (it has erased the USB, so do NOT flash to your USB with data)
  • Reconnected Test USB flash - a drive "hassos-boot" has been mounted. It is FAT filesystem, so easy to work with in Windows.
  • Copied all the files from the partition with the label "hassos-boot" (u-boot.bin, config.txt, overlays, etc) to my PC.
  • Tested that I could boot from this Test USB flash on Rpi CM4 board.
  • Connected my Prod USB flash, took a backup of all files from its "hassos-boot" disk (that was running 2023.11.2)
  • Replaced all files on "hassos-boot" disk with the ones from Test USB flash that was running 2023.11.1
  • Connected Prod USB flash to Raspberry Pi CM4 and was able to boot from USB stick. No data was lost.
  • [Optionally] Formally Downgrade using command: "ha os update --version 11.1"

Uploading a ZIP with 2023.11.1 boot files that recovered by setup, if you don't have a spare USB to flash to get the files:
haos_rpi4-64-11.1_hassos-boot.zip

@teppic01
Copy link

Thanks a lot for the work around! It maybe helps in other situations in future too!
I can report, that i have no problems with PI400 an 11.2

Copy link

There hasn't been any activity on this issue recently. To keep our backlog manageable we have to clean old issues, as many of them have already been resolved with the latest updates.
Please make sure to update to the latest Home Assistant OS version and check if that solves the issue. Let us know if that works for you by adding a comment 👍
This issue has now been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.

@github-actions github-actions bot added the stale label Mar 31, 2024
@fencer
Copy link
Author

fencer commented Apr 1, 2024

did anyone try any of the newer versions on USB boot with CM4? I'm was scared to upgrade the os since then

@github-actions github-actions bot removed the stale label Apr 2, 2024
Copy link

github-actions bot commented Jul 1, 2024

There hasn't been any activity on this issue recently. To keep our backlog manageable we have to clean old issues, as many of them have already been resolved with the latest updates.
Please make sure to update to the latest Home Assistant OS version and check if that solves the issue. Let us know if that works for you by adding a comment 👍
This issue has now been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.

@github-actions github-actions bot added the stale label Jul 1, 2024
@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale Jul 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
board/raspberrypi Raspberry Pi Boards bug stale usb-ssd USB SSD related issue
Projects
None yet
Development

No branches or pull requests