Star InactiveStar InactiveStar InactiveStar InactiveStar Inactive
 

Recently I had to build a Linux kernel on my Raspberry Pi5 and detected the system became quite hot even with an original active cooler. That's the way I monitored the CPU usage and fan speed.

 

 

I just wrote a small script which monitors CPU temperature, fan speed and CPU frequency short term:

while true; do
printf "%s --- %s rpm --- %.4s GHz\n" $(vcgencmd measure_temp | cut -d "=" -f 2) $(cat /sys/devices/platform/cooling_fan/hwmon/*/fan1_input) $(vcgencmd measure_clock arm | cut -d "=" -f 2)
sleep 5
done

Then I also wrote a script which monitors additional values and writes them in parallel into a log file for long term monitoring. In addition I used this script to check whether any throtteling happened.

stressberry also helped to understand the cooling capabilities better.

sudo apt install stress
mkdir myenv
python -m venv myenv
cd myenv
source ./bin/active
pip3 install stressberry stressberry-run -d 600 -c 4 out.dat stressberry-plot out.dat -f -d 600 -f -l 1400 2500 -t 30 90 -o out.jpg