Prometheus Adapter for HWiNFO (+ Grafana Dashboard)

n3farious

New Member
I've been running prometheus with node_exporter for all of my linux boxes for a while, and just found your exporter for hwInfo64. Thank you so much @Kallex ... you rock!

As a tiny contribution, I added my UPS info to the yaml:

YAML:
    # UPS
    - '(?<Entity_UPS>)(?<MetricName>UPS Load|Input Voltage|Output Voltage|Charge Level|Estimated Runtime|AC Power|Charging|Discharging)'

That results in:

# HELP hwi_ups_ac_power_yesno UPS AC Power Yes/No - UPS
# HELP hwi_ups_charge_level UPS Charge Level % - UPS
# HELP hwi_ups_charging_yesno UPS Charging Yes/No - UPS
# HELP hwi_ups_discharging_yesno UPS Discharging Yes/No - UPS
# HELP hwi_ups_estimated_runtime_min UPS Estimated Runtime min - UPS
# HELP hwi_ups_input_voltage_v UPS Input Voltage V - UPS
# HELP hwi_ups_output_voltage_v UPS Output Voltage V - UPS
# HELP hwi_ups_ups_load UPS UPS Load % - UPS
# HELP hwi_ups_ups_load_w UPS UPS Load W - UPS

And some actual metrics:

# HELP hwi_ups_ac_power_yesno UPS AC Power Yes/No - UPS
hwi_ups_ac_power_yesno{unit="Yes/No",sensor_type="SENSOR_TYPE_OTHER",sensor="AC Power",source="UPS",host="N3FARIOUS"} 1
# HELP hwi_ups_charge_level UPS Charge Level % - UPS
hwi_ups_charge_level{unit="%",sensor_type="SENSOR_TYPE_USAGE",sensor="Charge Level",source="UPS",host="N3FARIOUS"} 100
# HELP hwi_ups_charging_yesno UPS Charging Yes/No - UPS
hwi_ups_charging_yesno{unit="Yes/No",sensor_type="SENSOR_TYPE_OTHER",sensor="Charging",source="UPS",host="N3FARIOUS"} 0
# HELP hwi_ups_discharging_yesno UPS Discharging Yes/No - UPS
hwi_ups_discharging_yesno{unit="Yes/No",sensor_type="SENSOR_TYPE_OTHER",sensor="Discharging",source="UPS",host="N3FARIOUS"} 0
# HELP hwi_ups_estimated_runtime_min UPS Estimated Runtime min - UPS
hwi_ups_estimated_runtime_min{unit="min",sensor_type="SENSOR_TYPE_OTHER",sensor="Estimated Runtime",source="UPS",host="N3FARIOUS"} 35
# HELP hwi_ups_input_voltage_v UPS Input Voltage V - UPS
hwi_ups_input_voltage_v{unit="V",sensor_type="SENSOR_TYPE_VOLT",sensor="Input Voltage",source="UPS",host="N3FARIOUS"} 118
# HELP hwi_ups_output_voltage_v UPS Output Voltage V - UPS
hwi_ups_output_voltage_v{unit="V",sensor_type="SENSOR_TYPE_VOLT",sensor="Output Voltage",source="UPS",host="N3FARIOUS"} 118
# HELP hwi_ups_ups_load UPS UPS Load % - UPS
hwi_ups_ups_load{unit="%",sensor_type="SENSOR_TYPE_USAGE",sensor="UPS Load",source="UPS",host="N3FARIOUS"} 22
# HELP hwi_ups_ups_load_w UPS UPS Load W - UPS
hwi_ups_ups_load_w{unit="W",sensor_type="SENSOR_TYPE_POWER",sensor="UPS Load",source="UPS",host="N3FARIOUS"} 153.9

I have a CyberPower UPS and am running the PowerPanel Personal. These are the same stats it shows in it's "Current Status" panel.
 

Kallex

Well-Known Member
I've been running prometheus with node_exporter for all of my linux boxes for a while, and just found your exporter for hwInfo64. Thank you so much @Kallex ... you rock!

As a tiny contribution, I added my UPS info to the yaml:

YAML:
    # UPS
    - '(?<Entity_UPS>)(?<MetricName>UPS Load|Input Voltage|Output Voltage|Charge Level|Estimated Runtime|AC Power|Charging|Discharging)'

Very cool addition, thanks a lot!

Hey, I started to make support for Linux (already while ago), unifying the adapter output. The thing is of course there is no HWiNFO for Linux, but that's not the whole big picture. Same as WMI support (also quite far, just been busy elsewhere) the idea was to be able to scrape from various sources to provide "common interface" to prometheus.

But if there is already existing what you mention "node_exporter" in Linux - is there any need to bring "unifying experience to Linux"?

I'm thinking the ability to name metrics and their categorization in one common way, so that the Prometheus + Grafana woudln't need to behave any different regardless of the Linux/Windows/Mac/??? behind the scenes.
 
Top