Thermal Plugin support missing from BE3600 collectd

I was wondering if someone could help guide me in the right direction.

I'm trying to add thermal plugin support for collectd on my Slate 7 however opkg says the package doesn't exists. My search began when I noticed thermal wasn't an option in Luci(Stats-->Setup--> General Plugins and when I tried to install it from CLI i get an error

root@GL-BE3600:~# opkg update
Downloading https://fw.gl-inet.com/releases/qsdk_v12.5/kmod-4.7/be3600-ipq53xx/Packages.gz
Updated list of available packages in /var/opkg-lists/glinet_core
Downloading https://fw.gl-inet.com/releases/qsdk_v12.5/packages-4.x/ipq53xx/be9300/glinet/Packages.gz
Updated list of available packages in /var/opkg-lists/glinet_gli_pub
Downloading https://fw.gl-inet.com/releases/qsdk_v12.5/packages-4.x/ipq53xx/be9300/packages/Packages.gz
Updated list of available packages in /var/opkg-lists/opnwrt_packages
Updating database.
Database update completed.
root@GL-BE3600:~# opkg install collectd-mod-thermal
Unknown package 'collectd-mod-thermal'.
Collected errors:

    • opkg_install_cmd: Cannot install package collectd-mod-thermal.*

device info:

  • Model GL.iNet GL-BE3600

  • Architecture ARMv8 Processor rev 4

  • OpenWrt Version OpenWrt 23.05-SNAPSHOT

  • Kernel Version 5.4.213

  • Current Firmware Version 4.8.1

  • Firmware Type beta4

Hi,

Will try to compile this kmod if it supports to run in BE3600.

1 Like

Thanks Bruce.

Hey Bruce, did it happen to support to run on the BE3600? Thanks again.,

maybe the BE9300 as well?

1 Like

Please check again, have been added to BE3600 and BE9300 repo.

3 Likes

Installed and the thermal plugin showed up in Luci. The stats are sending to Grafana as expected.

Thank again Bruce.

Update ( Now working): I copied the thermal.lua file from github into the /usr/lib/lua/prometheus-collectors, chmod +x the file, and then restarted the node-exporter service. After that the thermal zones, are not only populated by collectd-mod-thermal, the values are now exposed in the node-export metrics i.e. http://:9100/metrics

(Troubleshooting before I got it working)
Looks like I spoke too soon. even after it's installed and rebooted the Prometheus-node-exporter-lua doesn't see the thermal zones to expose.

Shot in the dark, but do you happen to know why /how to get the thermal zones exposed to the

node_thermal_zone_temp is the metric missing.

oot@GL-BE3600:/tmp# opkg list | grep prometheus-node
prometheus-node-exporter-lua - 2022.08.08-1 - Provides node metrics as Prometheus scraping endpoint. This service is a lightweight rewrite in LUA of the offical Prometheus node_exporter.
prometheus-node-exporter-lua-bmx7 - 2022.08.08-1 - Prometheus node exporter (bmx7 links collector)
prometheus-node-exporter-lua-dawn - 2022.08.08-1 - Prometheus node exporter (dawn collector)
prometheus-node-exporter-lua-hostapd_stations - 2022.08.08-1 - Prometheus node exporter (hostapd_stations collector) - Requires a full hostapd / wpad build
prometheus-node-exporter-lua-hostapd_ubus_stations - 2022.08.08-1 - Prometheus node exporter (hostapd_ubus_stations collector)
prometheus-node-exporter-lua-nat_traffic - 2022.08.08-1 - Prometheus node exporter (nat_traffic collector)
prometheus-node-exporter-lua-netstat - 2022.08.08-1 - Prometheus node exporter (netstat collector)
prometheus-node-exporter-lua-openwrt - 2022.08.08-1 - Prometheus node exporter (openwrt collector)
prometheus-node-exporter-lua-snmp6 - 2022.08.08-1 - Prometheus node exporter (snmp6 collector)
prometheus-node-exporter-lua-textfile - 2022.08.08-1 - Prometheus node exporter (textfile collector)
prometheus-node-exporter-lua-ubnt-manager - 2022.08.08-1 - Prometheus node exporter (ubnt-manager collector)
prometheus-node-exporter-lua-uci_dhcp_host - 2022.08.08-1 - Prometheus node exporter (uci_dhcp_host collector)
prometheus-node-exporter-lua-wifi - 2022.08.08-1 - Prometheus node exporter (wifi collector)
prometheus-node-exporter-lua-wifi_stations - 2022.08.08-1 - Prometheus node exporter (wifi_stations collector)
root@GL-BE3600:/tmp#

Perhaps there is a prometheus-node-exporter-lua-thermal package which I am missing?

I see it mentioned here - packages/utils/prometheus-node-exporter-lua/files/usr/lib/lua/prometheus-collectors/thermal.lua at master · openwrt/packages · GitHub

Is there any way Bruce a "prometheus-node-exporter-lua-thermal" could be complied as well?

I see the .lua files for each of the currently working collectors, however thermal is noticeable missing.

I've copied the missing .lua file into the collect directory

Then I restarted the node_exporter.....

Perhaps when Bruce has time he can wrap all these steps up into a new "prometheus-node-exporter-lua-thermal" package added to the repo.

Hi,

Is the currently compiled thermal missing prometheus-node-exporter-lua-thermal?

Hi Bruce,

Yes, it appears so. I noted that thermal.lua was absent from the /usr/lib/lua/prometheus/collectors dir and I copied it from github over to the location and that did the trick.

Also,
my log says that when I tried to install it...
root@GL-BE3600:~# opkg install Prometheus-node-exporter-lua-thermal
Unknown package 'Prometheus-node-exporter-lua-thermal'.
Collected errors:

  • opkg_install_cmd: Cannot install package prometheus-node-exporter-lua-thermal.
    root@GL-BE3600:~#

Works for my BE9300. Thank you again Bruce!

FYI for anyone else, if you have issues with luci setting up collectd, I do the following to manually configure it.

uci set collectd.globals.alt_config_file='/etc/collectd-custom.conf'

example of /etc/collectd-custom.conf

BaseDir "/var/run/collectd"
PIDFile "/var/run/collectd.pid"
PluginDir "/usr/lib/collectd"
TypesDB "/usr/share/collectd/types.db"
Interval 15
ReadThreads 2
WriteThreads 2
CollectInternalStats false
Hostname "my-openwrt-ap"
#Include "/etc/collectd/conf.d"

LoadPlugin thermal
<Plugin thermal>
    IgnoreSelected false
</Plugin>


run

/etc/init.d/collectd restart

and start cooking.

Bruce, If you want Hero status, could you build the following packages for the repo of the BE9300 or the BEXXXX series? We are just a bunch of homelab nerds and we love our hardware stats! :slight_smile:

also, Have you ever posted anything about the build env for the BE9300 to make the pkgs ourselves? I hate having to bother you with it when something is missing.

collectd-mod-sensors
collectd-mod-exec - to get fan stats
collectd-mod-disk
collectd-mod-df
collectd-mod-load

i doubt collectd-mod-wireless will work at the moment with the hardware.

1 Like

Hi Bruce,

Sorry for the delayed response.

I believe so yes. I updated to 4.8.1 latest and had to redo the setup I took the time to document the steps I took to get it up and running. I'm sure I don't need all the packages I used but I added them anyway.

After the update completed, I needed to get the thermal values exposed in the Prometheus node exporter again, I did the following;

[Install packages]

opkg update
opkg install collectd-mod-interface collectd-mod-iwinfo collectd-mod-load collectd-mod-memory collectd-mod-mqtt collectd-mod-network collectd-mod-ping collectd-mod-rrdtool collectd-mod-thermal collectd-mod-uptime
opkg install luci-app-statistics
opkg install prometheus-node-exporter-lua prometheus-node-exporter-lua-hostapd_ubus_stations prometheus-node-exporter-lua-nat_traffic prometheus-node-exporter-lua-netstat prometheus-node-exporter-lua-openwrt prometheus-node-exporter-lua-uci_dhcp_host prometheus-node-exporter-lua-wifi prometheus-node-exporter-lua-wifi_stations

[Copy over missing thermal.lua file]
[thermal zones are now seen in cli, and LuCi stats but not exposed to the node exporter hostname:9100/metrics at this point]

In my case I used winscp to copy over the thermal.lua file from, github-utils/prometheus-node-exporter-lua/files/usr/lib/lua/prometheus-collectors to

/usr/lib/lua/prometheus-collectors

dir on my be3600. no chmod +x nesssary it seems.

[restart node exporter service]

/etc/init.d/prometheus-node-exporter-lua restart

After that command the thermal zones start reporting and all is well. I hope that helps you idenify what package/file is missing or needs to be updated to include the thermal.lua file.

Thanks again for everything.

100% second this request if Bruce has the time. More stats for monitoring the better.

Speaking of more monitoring....adding the missing thermal.lua file to the collectors dir, and getting more metrics exposed, makes me wonder what else would be exposed if I copied all the .lua files from github and placed them into the collectors dir. Perhaps I will do a test and see the difference, if any.

Hi,

Thanks, let us check it

Unfortunately, we cannot public the build env of BE3600/BE9300 for the time being. Feel sorry.

If you have any needs, just create a thread/topic request to compile, please feel free to let us know.

The repository in MT3000/BE9300/BE3600 has been added.

Please check if they are available.

1 Like

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