CPU Temp not showing Topic is solved

Have some feedback, questions, suggestions, or just fancy a chat? Pop it in here.
shrike
Posts: 7
Joined: Thu Jan 14, 2021 4:42 pm

CPU Temp not showing

Post by shrike »

I did a fresh install of DietPi 6.34.3 on a RPi3b and noticed the CPU temp shows "N/A" when I run the cpu command.

Code: Select all

 ─────────────────────────────────────────────────────
 DietPi v6.34.3 : 09:40 - Thu 01/14/21
 ─────────────────────────────────────────────────────
 - Device model : RPi 3 Model B (aarch64)
 - Uptime : up 15 hours, 12 minutes
 - CPU temp : N/A
 - LAN IP : 10.2.2.3 (wlan0)
 - MOTD : Happy New Year of the Ox 2021, may things be looking up for you!
 ─────────────────────────────────────────────────────

 DietPi Team     : MichaIng (lead), Daniel Knight (founder), Joulinar (support)
 Image           : DietPi Core Team (pre-image: Raspberry Pi OS 64-bit)
 Web             : https://dietpi.com | https://twitter.com/DietPi_
 Donate          : https://dietpi.com/#donate
 DietPi Hosting  : Powered by https://myvirtualserver.com

 dietpi-launcher : All the DietPi programs in one place.
 dietpi-config   : Feature rich configuration tool for your device.
 dietpi-software : Select optimized software for installation.
 htop            : Resource monitor.
 cpu             : Shows CPU information and stats.
I did a cat of the sys thermal but got this:

Code: Select all

 
 $ cat /sys/class/thermal/thermal_zone*/temp
cat: /sys/class/thermal/thermal_zone0/temp: Invalid argument
I also did:

Code: Select all

$ sudo vcgencmd measure_temp
temp=55.3'C
Is there something I missed on the install? It was working fine when running v6.33 on the same RPi3b but I had to do a clean reinstall due to a corrupt sdcard. I don't recall doing anything before on the previous version. It just worked. Now it's not.
User avatar
Joulinar
Posts: 3238
Joined: Sat Nov 16, 2019 12:49 am

Re: CPU Temp not showing

Post by Joulinar »

Hi,

Do you use any beta kernel 5.10? Can you check uname -a pls
Pls let us know if a solution is working. This could help others if they hit by similar situation. Your DietPi Team
shrike
Posts: 7
Joined: Thu Jan 14, 2021 4:42 pm

Re: CPU Temp not showing

Post by shrike »

No, just the latest available kernel.

Code: Select all

$ uname -a
Linux PwMon 5.10.5-v8+ #1392 SMP PREEMPT Sat Jan 9 18:56:30 GMT 2021 aarch64 GNU/Linux
User avatar
Joulinar
Posts: 3238
Joined: Sat Nov 16, 2019 12:49 am

Re: CPU Temp not showing

Post by Joulinar »

Best to my knowledge 5.10 is a Beta kernel and not yet released.
Pls let us know if a solution is working. This could help others if they hit by similar situation. Your DietPi Team
shrike
Posts: 7
Joined: Thu Jan 14, 2021 4:42 pm

Re: CPU Temp not showing

Post by shrike »

It's odd then it would be installed on a fresh DietPi OS install.
User avatar
Joulinar
Posts: 3238
Joined: Sat Nov 16, 2019 12:49 am

Re: CPU Temp not showing

Post by Joulinar »

Let me verify it later the evening. Currently I'm away for home
Pls let us know if a solution is working. This could help others if they hit by similar situation. Your DietPi Team
bails
Posts: 1
Joined: Thu Jan 14, 2021 8:21 pm

Re: CPU Temp not showing

Post by bails »

I have the exact same issue. I reinstalled DietPi on my Raspberry Pi 3B and no longer have cpu temp information on the dashboard screen. It says N/A. It was working on version 6.33.3 but fresh install of 6.34.3 does not work.

Here's my kernel information.

Linux gretapi 5.10.5-v8+ #1392 SMP PREEMPT Sat Jan 9 18:56:30 GMT 2021 aarch64 GNU/Linux

Also tried a fresh install with version 6.34.3 on my Raspberry Pi 4 and the temp info works without issue.
User avatar
Joulinar
Posts: 3238
Joined: Sat Nov 16, 2019 12:49 am

Re: CPU Temp not showing

Post by Joulinar »

It's most probably related to Raspberry OS 64bit Beta. I guess the Foundation changed something and our script did detect it correctly now. That's why it's still in Beta as the Foundation could change things on the way ;)
Pls let us know if a solution is working. This could help others if they hit by similar situation. Your DietPi Team
shrike
Posts: 7
Joined: Thu Jan 14, 2021 4:42 pm

Re: CPU Temp not showing

Post by shrike »

Ok, interesting. Well, we were warned that not all things work on 64 bit yet. I didn't expect cpu temp to break going from previous version to the latest.

Also, why are beta kernels used for the base install? Has this always been the case?
User avatar
Joulinar
Posts: 3238
Joined: Sat Nov 16, 2019 12:49 am

Re: CPU Temp not showing

Post by Joulinar »

This has nothing to do with DietPi, this is fully related to Raspberry OS 64bit Beta. The image contains the Beta flag still, because RPi OS 64bit has not been released as stable by the Foundation.

Indeed a bug of the Raspberry OS 64bit BETA in combination with BETA kernel 5.10.5 and RPi3
Looks like Foundation is now shipping 5.10 kernel version on RPi OS 64bit.
Means you are running BETA OS + BETA Kernel and it seems on RPi3 it is not working to detect temperature.

Usually, CPU temp is written to a file and can be simple read cat /sys/class/thermal/thermal_zone0/temp. On RPi3 the file is not readable and you will get Invalid argument while on RPi4 this is working well. I switched SD card between RP3 and 4 back and force. Always on RP3 it was not working, even if it has been working a minute before running RPi4

btw vcgencmd measure_temp is giving GPU temp and not CPU temp ;)

EDIT
I verified it running plain Raspberry OS 64bit BETA. There the kernel was switched to 5.10 LTS Beta as well

right after download and install

Code: Select all

Linux raspberrypi 5.4.51-v8+ #1333 SMP PREEMPT Mon Aug 10 16:58:35 BST 2020 aarch64 GNU/Linux
after apt upgrade

Code: Select all

Linux raspberrypi 5.10.5-v8+ #1392 SMP PREEMPT Sat Jan 9 18:56:30 GMT 2021 aarch64 GNU/Linux
The plain RPi OS is having same issue on RPi3. Definitely not related to DietPi
Pls let us know if a solution is working. This could help others if they hit by similar situation. Your DietPi Team
Post Reply