Conky temperature gone

The conky code

Temp: ${hwmon 0 temp 1}C

Has worked for years, but after updating to the 5.10 kernel this morning it works no more, it is just blank.

Is there some replacement for it?

NB Booted an older kernel and it works again, but not with 5.10, so it certainly looks kernel related.
Two answers below both correct but moson’s idea about using names instead of numbers should render any further tweaks unnecessary.

Occasionally, the monitor listings at /sys/class/hwmon/* will change (just like /dev/sda will automagically be re-assigned to /dev/sdb.

You’ll have to look at /sys/class/hwmon/* and determine what was changed, and make your changes in your conf file accordingly.

Most likely, after a few boots, it will settle down and the listing will become stable. I haven’t had to make any hwmon changes for almost a year, now.

1 Like

As @merlock explained, the numbering can change.

Use device names in conky rather then a number.

${hwmon k10temp temp 1}

Here is how to list the names:

for dir in /sys/class/hwmon/*; do echo -n "$dir: "; cat $dir/name; done


Thank you both I needed to change from Temp: ${hwmon 0 temp 1}C

to - Temp: ${hwmon 5 temp 1}C

I have never seen that happen before, still we are here to learn!

And then with the next update it will happen again :wink:
Use name instead, then you don’t need to care anymore…

Ah Ha! I get you, so for me that would be:

Temp: ${hwmon coretemp temp 1}C

A bit like using ‘by-label’ in fstab which I have been doing for at least a decade.

Thanks for persevering, even better solution!

I’ll switch “solution” back to @merlock’s post if you don’t mind. He was first and gave the explanation.

Maybe you can edit your first post to suggest using name instead…

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.