Supervisor Logs Extremely Slow to Open

So booting with a screen & keyboard attached, I could run hdparm on the Raspberry installation. It says it read 716MB in 3 Seconds, which is ~250 MB/s. This should be more than sufficient, but as @Veldkornet wrote, it still feels much slower and less snappy than it did earlier…

Disabling UAS as @MaxW mentioned solved the issue with the logs for me. Also restarting the core and loading of the history is much faster, now. :+1:

You’re right, the logs are fast again. Weird that my speeds didn’t seem to change though:

Timing buffered disk reads:  636 MB in 3.00 seconds = 217.004 MB/s

FYI, I have an Argon One M.2 with a Samsung M.2 SATA SSD and my cmdline.txt ended up looking like the below:

usb-storage.quirks=174c:55aa:u dwc_otg.lpm_enable=0 console=tty1

I might be wrong with the speed thing as proof, but I can recommend everyone with issues to try the UAS disabling thing.

I’m also running Home Assistant OS on a SSD. Reading the info on the raspberrypi forum mentions unplugging the SSD, but isn’t that impossible because the OS is running from that thing?
Could somebody write a little howto on disabling UAS on Home Assistant?
Thanks in advance!

I also run only an SSD, so I also did it in-place. This is what I did:

  • SSH into HassOS, that’s port 22222 (not the HA container on port 22), I used this to enable 22222
  • run dmesg | usb And examine the Vendor ID (vid), Product ID (pid) As per the RPi forum post. Just have a look carefully here, my ConBee and ZStick were clearly marked as such on the usb1-1, so the only one left for me was the one on usb-2-2 (if you’re really unsure, maybe unplug all other usb devices and reboot the host, then check dmesg again). Example of mine:
[    1.990062] usb 2-2: new SuperSpeed Gen 1 USB device number 2 using xhci_hcd
[    2.011145] usb 2-2: New USB device found, idVendor=174c, idProduct=55aa, bcdDevice= 1.00
[    2.011179] usb 2-2: New USB device strings: Mfr=2, Product=3, SerialNumber=1
[    2.011205] usb 2-2: Product: Forty
[    2.011228] usb 2-2: Manufacturer: Argon
[    2.011251] usb 2-2: SerialNumber: 0000000000XX
  • Edit the cmdline: vi /mnt/boot/cmdline.txt And add the storage quirk at the beginning of the line, mine looked like this: usb-storage.quirks=174c:55aa:u dwc_otg.lpm_enable=0 console=tty1
  • Save the file and reboot the host
  • finished, if you SSH to 22222 again and run dmesg | grep usb again, you should see something like the below
[    2.014012] usb 2-2: UAS is ignored for this device, using usb-storage instead
[    2.014137] usb 2-2: UAS is ignored for this device, using usb-storage instead
[    2.014169] usb-storage 2-2:1.0: USB Mass Storage device detected
[    2.014740] usb-storage 2-2:1.0: Quirks match for vid 174c pid 55aa: c00000
8 Likes

Thank you very much for this HowTo!

But what is not clear to me is the reason that activated UAS is slower than deactivated UAS! And the strange thing is that it was fast with activated UAS with the first betas of Home Assistant OS 5 and also with later versions.

1 Like

same question. it worked for a long time (at least the last half year). Could not read something in release notes to HA OS 6.6 but it seemed it was the starting point of problems

1 Like

Thanks for all the explanations in here. One thing I’m wondering about though: Why is my SSD now faster than before when people write it’s supposed to be the opposite?

UAS enabled:
Timing buffered disk reads: 437 MB in 3.08 seconds = 144960 kB/s

UAS disabled
Timing buffered disk reads: 618 MB in 3.00 seconds = 210829 kB/s

It’s a Kingston A400 240 GB

Did you try my mentioned UAS setting?

I might have been wrong with the relation between speed and uas.

1 Like

yes, I tried the UAS setting and it works. I am wondering why and when the problem started. It worked for a long time without any problems and now (assuming coming with 6.6 of HA OS) I need the setting to switch of the UAS mode.

For me it started pretty fast after moving to USB SSD, maybe a few days later.

I am not sure where the relation is. I just tell myself it is some ‘bottleneck’ and when a specifc amount of data is requested it just gets stuck.

Found this nice comment, mentioning the same issues like me:
https://www.jeffgeerling.com/comment/16699#comment-16699

Finally my logs are working as they should.
Should this be listed as a bug?

If, like me, you have a powered hub in the mix - make sure you boot into Raspian, update the install and reboot. That will make sure the EEPROMS are updated. My drive was running at 82mb - after the update it’s at 900mb+ :slight_smile:

Just for clearity, you deacitved UAS via the boot config?

Omg, my savior. It’s been months that this issues drivin’ me nuts too.
Since I don’t now, june release maybe ?

Logs are now fast as they should be. Because of this issue, my terminal commands was long to execute, now super fast.

Thanks !!!

Yes. I use Pi4 with SSD and Home Assistant Operating System or whatever it is nowadays called.

@pvizeli not sure if you are the right person to ping on this, but maybe you are, or can mention who could be?

I encouraged multiple issues on my journey about slow logs, supervisor not responding, Add-On images can’t be build…

After deactivation UAS as mentioned here me and a lot of others in this post are now happy to have their performance back.

Is this something that should be added to the documentation? I looked through GitHub - home-assistant/operating-system: Home Assistant Operating System to find something related but besides some comments on UAS no success.

Is this something worth to document/research?

So I’ve managed to ssh into hassio:22222 and find my VID + PID but I can’t find the folder or file I’m suppsoed to change ( /mnt/boot/cmdline.txt). When I run ls all i get is
addons backup config media share ssl

What am I doing wrong? :rofl:

That sounds like you SSH’d into the HomeAssistant Core container, rather that the OS.