CM4 OpenWrt - NetData Temperatures?

Is there a way to get temperature sensors for the CPU working in NetData installed on OpenWrt 21?

You will need to install the Python plugin for cpu temperature, if it exists.
If you can use a cli command to read the temperature then you should be able to write your own plugin quite easily.

I think there is a plugin for it, I just don't know how to install it on OpenWrt.

I tired editing the config and adding:

sensors=force

But that didn't seem to do anything

I think this is the plugin I need:

How do I install this to OpenWrt?

i dont know if this was solve, but here what i did:

  • install folowing packages on openwrt (you can use lucy software to install them):
    -- lm-sensors
    -- python3
    --python3-yaml

enter to openwrt console and execute the following:

sensors

for me the response is something like this:

gpu_thermal-virtual-0
Adapter: Virtual device
temp1:        +46.1°C  

test_battery-virtual-0
Adapter: Virtual device
in0:           4.00 mV 
temp:         +26.0°C  
curr1:        -2.00 mA (avg =  -0.00 A)

soc_thermal-virtual-0
Adapter: Virtual device
temp1:        +45.6°C  (crit = +115.0°C)

test_battery-virtual-0
Adapter: Virtual device
ERROR: Can't get value of subfeature in0_input: Kernel interface error
in0:              N/A  
temp1:        +26.0°C  
ERROR: Can't get value of subfeature curr1_input: Kernel interface error
ERROR: Can't get value of subfeature curr1_average: Kernel interface error
curr1:            N/A  (avg =  +0.00 A)

so my chip has kernel issues to map some temps, but im going to enable on netdata the gpu and soc temperatures.

run:

/usr/lib64/netdata/plugins.d/python.d.plugin sensors debug trace

if you are on lucky day, it will show the sensors data, if dont, you need to enable the sensors on /usr/lib/netdata/conf.d/python.d/sensors.conf

enable this, removing the comment tag '#' the last 2 were added by me, cuz are the starting part of the sensors showed before:

chips:
  - i8k
  - coretemp
  - gpu
  - soc
  - test

Edit /usr/lib/netdata/conf.d/python.d.conf and enable:

# Enable / disable the whole python.d.plugin (all its modules)
enabled: yes
.
.
.
sensors: yes

with this you will get the sensors with the command: "/usr/lib64/netdata/plugins.d/python.d.plugin sensors debug trace"

then go to /etc/netdata and use the netdata command to edit the config files here.
"./edit-config netdata.conf" and modify the plugins:

[plugins]
        cgroups = no
        apps = no
        charts.d = no
        fping = no
        node.d = no
        python.d = yes

and replicate the sensors.yml changes with "./edit-config python.d/sensors.conf"

and restart the service netdata: "service netdata restart", go to UI and Sensors was enabled: