#RPi 4 & OS 16 issues

1 messages · Page 1 of 1 (latest)

velvet eagle
#

After updating to HA OS v16.0 on a Raspberry Pi 4 with a POE hat the following behaviour has changed:

CPU Speed has dropped from 1800MHz to 700MHz, occasionally 800MHz, only peaking to 1300MHz when I performed a manual backup which significantly increased the CPU usage.

Average CPU usage increased by ~1-2% on average with more spikes of higher usage than on OS 15.2.

I feel like the POE+ Hat Fan doesn't speed up as much when the CPU temperature goes above 52°C (there is no heatsink on the CPU, just relying on the Fan blowing down on it and using the basic POE case from The PiHut https://thepihut.com/products/poe-hat-case-for-raspberry-pi-4?variant=30310171279422). Although it's possible I am just imagining this one, as the fan did actually speed up when I was performing a backup, but then slowed down again despite the temperature being almost 53°C.
As a result of the increased CPU usage from the lower clock speed, the average temperature of the CPU is a little higher than on OS 15.2.

Is there a configuration change in OS v16 that has modified the core speed values to take them down to near the minimum speeds?

A manual downgrade to OS 15.2 resolves the issues I was having, so evidently whatever changes were performed in OS 16.0 don't really suit Raspberry Pi 4's.

barren crescent
#

I don't see which part of it would be an issue you'd be describing

velvet eagle
#

The CPU clock speed drops from 1800MHz to 700MHz on OS 16.0, this is not a "normal" change.

#

It's a Pi4 so it's hardly saving a lot of power by dropping the core speed. And it just increases the CPU usage since you then need more CPU cycles to get the same job done.

barren crescent
#

Did you restart the pi (as in unplug) manually after doing the upgrade?

#

I don't see that many reporting such issue here as this would signal an active issue with anything

velvet eagle
#

I didn't physically unplug it, but I did perform a full system reboot afterwards from within HA which should perform the same thing.

barren crescent
#

that may not necessarily be the same

velvet eagle
#

So I thought I would try OS 16.2 to see if anything changed, and it clearly has not as the CPU is still stuck at 700MHz.

sudden nacelle
#

How do you check?

velvet eagle
#

This time around I unplugged the Pi and stripped it down to clean it.

#

I use this in configuration.yaml

command_line:
  - sensor:
      name: Processor Speed
      command: "cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq"
      # If errors occur, make sure configuration file is encoded as UTF-8
      unit_of_measurement: "MHz"
      value_template: "{{ value | multiply(0.001) | round(0) }}"
      scan_interval: 60
sudden nacelle
#

Have you checked the governor and other cores?

velvet eagle
#

I have no idea how to check the Governor

sudden nacelle
#

I can give you some commands later.

velvet eagle
#

It also doesn't seem to spin the fan on the POE Hat as fast as it did before the update, and the CPU is the same temperature even with the lower frequency.

sudden nacelle
#

Try if running this for a few minutes changes anything

apk add stress-ng
stress-ng -c 4
velvet eagle
sudden nacelle
#

Needs to be done in a SSH addon. The OS has no package manager.

velvet eagle
sudden nacelle
#

That's good. So either it doesn't need the power during normal use or the governor acts different now.

velvet eagle
#

So how do I stop it

sudden nacelle
#

CTRL+C.

velvet eagle
#

🤦

#

I'm currently on mobile.

sudden nacelle
#

Same. You can also use pkill stress-ng I guess. Or restart the addon.

velvet eagle
#

Had a PC on anyway so used Ctrl c to stop

#

Instantly back down to 700MHz and ~6-8% CPU

#

On 15.2 the mean usage % was always under 6% unless it was doing something stressful like a backup.

#

Now it's always over 6%

sudden nacelle
#

Have you checked with glances what uses the CPU?

#

top -o%CPU and docker stats on the OS CLI works too.

#

Also check

apk add cpupower
cpupower frequency-info
velvet eagle
sudden nacelle
#

Yeah it was top and the casing is important.

velvet eagle
#
apk add cpupower
cpupower frequency-info

Throws this:

cpupower frequency -info analyzing CPU 0 :
driver: cpufreq-dt CPUS which run at the same hardware frequency: 0 1 2 3
CPUS which need to have their frequency coordinated by software: 0 1 2 3
maximum transition latency : Cannot determine or is not supported
hardware limits: 600 MHz
available frequency steps: 600 MHz, 700 MHz, 800 MHz, 900 MHz, 1.00 GHZ, 1.10 GHz, 1.20 GHz, 1.30 GHz, 1.40 GHz, 1.50 GHz, 1.60 GHz, 1.70 GHZ, 1.80 GHZ
available cpufreg governors: conservative ondemand userspace powersave performamce schedutil
current policy: frequency should be within 600 MHz and 1.80 GHz
The governor "ondemand" may decide which speed to use within this range.
current CPU frequency: 700 MHz (asserted by call to hardware )

velvet eagle
sudden nacelle
#

Seems fine to me. Apparently it can't read the hardware limits though.
On the OS CLI you can do something like this

grep -sRH . /sys/devices/system/cpu/cpu0/cpufreq/ | grep -E "freq|gov"
velvet eagle
#

Works in an SSH client now for some reason:

sudden nacelle
#

on the OS CLI
SSH via 22222 works too.

#

Best to debug this on a real PC though.

velvet eagle
sudden nacelle
velvet eagle
#

I already updated to 16.2 from 15.2 and it didn't change from when I first went to 16.0, didn't like the changes and rolled back to 15.2.