Rewrite ups-nut discovery to SnmpQuery:: (#15850)

* modernize and move ups-nut to unix

* fix test data (group and invalid runtime)

* add Battery Temperature to test data

* lnms dev:check style
This commit is contained in:
Peca Nesovanovic
2024-02-26 17:48:40 +01:00
committed by GitHub
parent 851f682155
commit eb6006248f
15 changed files with 385 additions and 907 deletions

View File

@@ -31,7 +31,7 @@
"sensor_index": "1",
"sensor_type": "ups-nut",
"sensor_descr": "Battery Charge",
"group": null,
"group": "ups-nut",
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 100,
@@ -56,7 +56,7 @@
"sensor_index": "8",
"sensor_type": "ups-nut",
"sensor_descr": "Ups Load",
"group": null,
"group": "ups-nut",
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 17,
@@ -81,10 +81,10 @@
"sensor_index": "3",
"sensor_type": "ups-nut",
"sensor_descr": "Time Remaining",
"group": null,
"group": "ups-nut",
"sensor_divisor": 60,
"sensor_multiplier": 1,
"sensor_current": 2280,
"sensor_current": 38,
"sensor_limit": 1000,
"sensor_limit_warn": null,
"sensor_limit_low": 0,
@@ -106,7 +106,7 @@
"sensor_index": "14",
"sensor_type": "UPSBatteryCharging",
"sensor_descr": "UPS the battery is charging",
"group": null,
"group": "ups-nut",
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 1,
@@ -131,7 +131,7 @@
"sensor_index": "15",
"sensor_type": "UPSBatteryDischarging",
"sensor_descr": "UPS the battery is discharging",
"group": null,
"group": "ups-nut",
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 1,
@@ -156,7 +156,7 @@
"sensor_index": "13",
"sensor_type": "UPSBatteryReplace",
"sensor_descr": "UPS the battery needs to be replaced",
"group": null,
"group": "ups-nut",
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 1,
@@ -181,7 +181,7 @@
"sensor_index": "22",
"sensor_type": "UPSForcedShutdown",
"sensor_descr": "UPS forced shutdown",
"group": null,
"group": "ups-nut",
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 1,
@@ -206,7 +206,7 @@
"sensor_index": "12",
"sensor_type": "UPSHighBattery",
"sensor_descr": "UPS high battery",
"group": null,
"group": "ups-nut",
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 1,
@@ -231,7 +231,7 @@
"sensor_index": "11",
"sensor_type": "UPSLowBattery",
"sensor_descr": "UPS low battery",
"group": null,
"group": "ups-nut",
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 1,
@@ -256,7 +256,7 @@
"sensor_index": "18",
"sensor_type": "UPSOffline",
"sensor_descr": "UPS is offline and is not supplying power to the load",
"group": null,
"group": "ups-nut",
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 1,
@@ -281,7 +281,7 @@
"sensor_index": "10",
"sensor_type": "UPSOnBattery",
"sensor_descr": "UPS on battery",
"group": null,
"group": "ups-nut",
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 1,
@@ -306,7 +306,7 @@
"sensor_index": "9",
"sensor_type": "UPSOnLine",
"sensor_descr": "UPS on line",
"group": null,
"group": "ups-nut",
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 1,
@@ -331,7 +331,7 @@
"sensor_index": "17",
"sensor_type": "UPSRuntimeCalibration",
"sensor_descr": "UPS is currently performing runtime calibration",
"group": null,
"group": "ups-nut",
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 1,
@@ -356,7 +356,7 @@
"sensor_index": "21",
"sensor_type": "UPSUPSBoost",
"sensor_descr": "UPS is boosting incoming voltage",
"group": null,
"group": "ups-nut",
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 1,
@@ -381,7 +381,7 @@
"sensor_index": "20",
"sensor_type": "UPSUPSBuck",
"sensor_descr": "UPS is trimming incoming voltage",
"group": null,
"group": "ups-nut",
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 1,
@@ -406,7 +406,7 @@
"sensor_index": "16",
"sensor_type": "UPSUPSBypass",
"sensor_descr": "UPS bypass circuit is active",
"group": null,
"group": "ups-nut",
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 1,
@@ -431,7 +431,7 @@
"sensor_index": "19",
"sensor_type": "UPSUPSOverloaded",
"sensor_descr": "UPS is overloaded.",
"group": null,
"group": "ups-nut",
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 1,
@@ -448,6 +448,31 @@
"rrd_type": "GAUGE",
"state_name": "UPSUPSOverloaded"
},
{
"sensor_deleted": 0,
"sensor_class": "temperature",
"poller_type": "snmp",
"sensor_oid": ".1.3.6.1.4.1.8072.1.3.2.4.1.2.7.117.112.115.45.110.117.116.24",
"sensor_index": "24",
"sensor_type": "ups-nut",
"sensor_descr": "Battery Temperature",
"group": "ups-nut",
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 25,
"sensor_limit": 40,
"sensor_limit_warn": 35,
"sensor_limit_low": 10,
"sensor_limit_low_warn": 15,
"sensor_alert": 1,
"sensor_custom": "No",
"entPhysicalIndex": null,
"entPhysicalIndex_measured": null,
"sensor_prev": null,
"user_func": null,
"rrd_type": "GAUGE",
"state_name": null
},
{
"sensor_deleted": 0,
"sensor_class": "voltage",
@@ -456,7 +481,7 @@
"sensor_index": "4",
"sensor_type": "ups-nut",
"sensor_descr": "Battery Voltage",
"group": null,
"group": "ups-nut",
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 44,
@@ -481,7 +506,7 @@
"sensor_index": "5",
"sensor_type": "ups-nut",
"sensor_descr": "Battery Nominal",
"group": null,
"group": "ups-nut",
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 45,
@@ -506,7 +531,7 @@
"sensor_index": "6",
"sensor_type": "ups-nut",
"sensor_descr": "Line Nominal",
"group": null,
"group": "ups-nut",
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 230,
@@ -531,7 +556,7 @@
"sensor_index": "7",
"sensor_type": "ups-nut",
"sensor_descr": "Input Voltage",
"group": null,
"group": "ups-nut",
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 252,
@@ -748,732 +773,6 @@
}
]
},
"poller": {
"sensors": [
{
"sensor_deleted": 0,
"sensor_class": "charge",
"poller_type": "snmp",
"sensor_oid": ".1.3.6.1.4.1.8072.1.3.2.4.1.2.7.117.112.115.45.110.117.116.1",
"sensor_index": "1",
"sensor_type": "ups-nut",
"sensor_descr": "Battery Charge",
"group": null,
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 100,
"sensor_limit": 100,
"sensor_limit_warn": null,
"sensor_limit_low": 0,
"sensor_limit_low_warn": 10,
"sensor_alert": 1,
"sensor_custom": "No",
"entPhysicalIndex": null,
"entPhysicalIndex_measured": null,
"sensor_prev": null,
"user_func": null,
"rrd_type": "GAUGE",
"state_name": null
},
{
"sensor_deleted": 0,
"sensor_class": "load",
"poller_type": "snmp",
"sensor_oid": ".1.3.6.1.4.1.8072.1.3.2.4.1.2.7.117.112.115.45.110.117.116.8",
"sensor_index": "8",
"sensor_type": "ups-nut",
"sensor_descr": "Ups Load",
"group": null,
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 17,
"sensor_limit": 100,
"sensor_limit_warn": null,
"sensor_limit_low": 0,
"sensor_limit_low_warn": 0,
"sensor_alert": 1,
"sensor_custom": "No",
"entPhysicalIndex": null,
"entPhysicalIndex_measured": null,
"sensor_prev": null,
"user_func": null,
"rrd_type": "GAUGE",
"state_name": null
},
{
"sensor_deleted": 0,
"sensor_class": "runtime",
"poller_type": "snmp",
"sensor_oid": ".1.3.6.1.4.1.8072.1.3.2.4.1.2.7.117.112.115.45.110.117.116.3",
"sensor_index": "3",
"sensor_type": "ups-nut",
"sensor_descr": "Time Remaining",
"group": null,
"sensor_divisor": 60,
"sensor_multiplier": 1,
"sensor_current": 38,
"sensor_limit": 1000,
"sensor_limit_warn": null,
"sensor_limit_low": 0,
"sensor_limit_low_warn": 0,
"sensor_alert": 1,
"sensor_custom": "No",
"entPhysicalIndex": null,
"entPhysicalIndex_measured": null,
"sensor_prev": 2280,
"user_func": null,
"rrd_type": "GAUGE",
"state_name": null
},
{
"sensor_deleted": 0,
"sensor_class": "state",
"poller_type": "snmp",
"sensor_oid": ".1.3.6.1.4.1.8072.1.3.2.4.1.2.7.117.112.115.45.110.117.116.14",
"sensor_index": "14",
"sensor_type": "UPSBatteryCharging",
"sensor_descr": "UPS the battery is charging",
"group": null,
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 1,
"sensor_limit": null,
"sensor_limit_warn": null,
"sensor_limit_low": null,
"sensor_limit_low_warn": null,
"sensor_alert": 1,
"sensor_custom": "No",
"entPhysicalIndex": "14",
"entPhysicalIndex_measured": null,
"sensor_prev": null,
"user_func": null,
"rrd_type": "GAUGE",
"state_name": "UPSBatteryCharging"
},
{
"sensor_deleted": 0,
"sensor_class": "state",
"poller_type": "snmp",
"sensor_oid": ".1.3.6.1.4.1.8072.1.3.2.4.1.2.7.117.112.115.45.110.117.116.15",
"sensor_index": "15",
"sensor_type": "UPSBatteryDischarging",
"sensor_descr": "UPS the battery is discharging",
"group": null,
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 1,
"sensor_limit": null,
"sensor_limit_warn": null,
"sensor_limit_low": null,
"sensor_limit_low_warn": null,
"sensor_alert": 1,
"sensor_custom": "No",
"entPhysicalIndex": "15",
"entPhysicalIndex_measured": null,
"sensor_prev": null,
"user_func": null,
"rrd_type": "GAUGE",
"state_name": "UPSBatteryDischarging"
},
{
"sensor_deleted": 0,
"sensor_class": "state",
"poller_type": "snmp",
"sensor_oid": ".1.3.6.1.4.1.8072.1.3.2.4.1.2.7.117.112.115.45.110.117.116.13",
"sensor_index": "13",
"sensor_type": "UPSBatteryReplace",
"sensor_descr": "UPS the battery needs to be replaced",
"group": null,
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 1,
"sensor_limit": null,
"sensor_limit_warn": null,
"sensor_limit_low": null,
"sensor_limit_low_warn": null,
"sensor_alert": 1,
"sensor_custom": "No",
"entPhysicalIndex": "13",
"entPhysicalIndex_measured": null,
"sensor_prev": null,
"user_func": null,
"rrd_type": "GAUGE",
"state_name": "UPSBatteryReplace"
},
{
"sensor_deleted": 0,
"sensor_class": "state",
"poller_type": "snmp",
"sensor_oid": ".1.3.6.1.4.1.8072.1.3.2.4.1.2.7.117.112.115.45.110.117.116.22",
"sensor_index": "22",
"sensor_type": "UPSForcedShutdown",
"sensor_descr": "UPS forced shutdown",
"group": null,
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 1,
"sensor_limit": null,
"sensor_limit_warn": null,
"sensor_limit_low": null,
"sensor_limit_low_warn": null,
"sensor_alert": 1,
"sensor_custom": "No",
"entPhysicalIndex": "22",
"entPhysicalIndex_measured": null,
"sensor_prev": null,
"user_func": null,
"rrd_type": "GAUGE",
"state_name": "UPSForcedShutdown"
},
{
"sensor_deleted": 0,
"sensor_class": "state",
"poller_type": "snmp",
"sensor_oid": ".1.3.6.1.4.1.8072.1.3.2.4.1.2.7.117.112.115.45.110.117.116.12",
"sensor_index": "12",
"sensor_type": "UPSHighBattery",
"sensor_descr": "UPS high battery",
"group": null,
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 1,
"sensor_limit": null,
"sensor_limit_warn": null,
"sensor_limit_low": null,
"sensor_limit_low_warn": null,
"sensor_alert": 1,
"sensor_custom": "No",
"entPhysicalIndex": "12",
"entPhysicalIndex_measured": null,
"sensor_prev": null,
"user_func": null,
"rrd_type": "GAUGE",
"state_name": "UPSHighBattery"
},
{
"sensor_deleted": 0,
"sensor_class": "state",
"poller_type": "snmp",
"sensor_oid": ".1.3.6.1.4.1.8072.1.3.2.4.1.2.7.117.112.115.45.110.117.116.11",
"sensor_index": "11",
"sensor_type": "UPSLowBattery",
"sensor_descr": "UPS low battery",
"group": null,
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 1,
"sensor_limit": null,
"sensor_limit_warn": null,
"sensor_limit_low": null,
"sensor_limit_low_warn": null,
"sensor_alert": 1,
"sensor_custom": "No",
"entPhysicalIndex": "11",
"entPhysicalIndex_measured": null,
"sensor_prev": null,
"user_func": null,
"rrd_type": "GAUGE",
"state_name": "UPSLowBattery"
},
{
"sensor_deleted": 0,
"sensor_class": "state",
"poller_type": "snmp",
"sensor_oid": ".1.3.6.1.4.1.8072.1.3.2.4.1.2.7.117.112.115.45.110.117.116.18",
"sensor_index": "18",
"sensor_type": "UPSOffline",
"sensor_descr": "UPS is offline and is not supplying power to the load",
"group": null,
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 1,
"sensor_limit": null,
"sensor_limit_warn": null,
"sensor_limit_low": null,
"sensor_limit_low_warn": null,
"sensor_alert": 1,
"sensor_custom": "No",
"entPhysicalIndex": "18",
"entPhysicalIndex_measured": null,
"sensor_prev": null,
"user_func": null,
"rrd_type": "GAUGE",
"state_name": "UPSOffline"
},
{
"sensor_deleted": 0,
"sensor_class": "state",
"poller_type": "snmp",
"sensor_oid": ".1.3.6.1.4.1.8072.1.3.2.4.1.2.7.117.112.115.45.110.117.116.10",
"sensor_index": "10",
"sensor_type": "UPSOnBattery",
"sensor_descr": "UPS on battery",
"group": null,
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 1,
"sensor_limit": null,
"sensor_limit_warn": null,
"sensor_limit_low": null,
"sensor_limit_low_warn": null,
"sensor_alert": 1,
"sensor_custom": "No",
"entPhysicalIndex": "10",
"entPhysicalIndex_measured": null,
"sensor_prev": null,
"user_func": null,
"rrd_type": "GAUGE",
"state_name": "UPSOnBattery"
},
{
"sensor_deleted": 0,
"sensor_class": "state",
"poller_type": "snmp",
"sensor_oid": ".1.3.6.1.4.1.8072.1.3.2.4.1.2.7.117.112.115.45.110.117.116.9",
"sensor_index": "9",
"sensor_type": "UPSOnLine",
"sensor_descr": "UPS on line",
"group": null,
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 1,
"sensor_limit": null,
"sensor_limit_warn": null,
"sensor_limit_low": null,
"sensor_limit_low_warn": null,
"sensor_alert": 1,
"sensor_custom": "No",
"entPhysicalIndex": "9",
"entPhysicalIndex_measured": null,
"sensor_prev": null,
"user_func": null,
"rrd_type": "GAUGE",
"state_name": "UPSOnLine"
},
{
"sensor_deleted": 0,
"sensor_class": "state",
"poller_type": "snmp",
"sensor_oid": ".1.3.6.1.4.1.8072.1.3.2.4.1.2.7.117.112.115.45.110.117.116.17",
"sensor_index": "17",
"sensor_type": "UPSRuntimeCalibration",
"sensor_descr": "UPS is currently performing runtime calibration",
"group": null,
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 1,
"sensor_limit": null,
"sensor_limit_warn": null,
"sensor_limit_low": null,
"sensor_limit_low_warn": null,
"sensor_alert": 1,
"sensor_custom": "No",
"entPhysicalIndex": "17",
"entPhysicalIndex_measured": null,
"sensor_prev": null,
"user_func": null,
"rrd_type": "GAUGE",
"state_name": "UPSRuntimeCalibration"
},
{
"sensor_deleted": 0,
"sensor_class": "state",
"poller_type": "snmp",
"sensor_oid": ".1.3.6.1.4.1.8072.1.3.2.4.1.2.7.117.112.115.45.110.117.116.21",
"sensor_index": "21",
"sensor_type": "UPSUPSBoost",
"sensor_descr": "UPS is boosting incoming voltage",
"group": null,
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 1,
"sensor_limit": null,
"sensor_limit_warn": null,
"sensor_limit_low": null,
"sensor_limit_low_warn": null,
"sensor_alert": 1,
"sensor_custom": "No",
"entPhysicalIndex": "21",
"entPhysicalIndex_measured": null,
"sensor_prev": null,
"user_func": null,
"rrd_type": "GAUGE",
"state_name": "UPSUPSBoost"
},
{
"sensor_deleted": 0,
"sensor_class": "state",
"poller_type": "snmp",
"sensor_oid": ".1.3.6.1.4.1.8072.1.3.2.4.1.2.7.117.112.115.45.110.117.116.20",
"sensor_index": "20",
"sensor_type": "UPSUPSBuck",
"sensor_descr": "UPS is trimming incoming voltage",
"group": null,
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 1,
"sensor_limit": null,
"sensor_limit_warn": null,
"sensor_limit_low": null,
"sensor_limit_low_warn": null,
"sensor_alert": 1,
"sensor_custom": "No",
"entPhysicalIndex": "20",
"entPhysicalIndex_measured": null,
"sensor_prev": null,
"user_func": null,
"rrd_type": "GAUGE",
"state_name": "UPSUPSBuck"
},
{
"sensor_deleted": 0,
"sensor_class": "state",
"poller_type": "snmp",
"sensor_oid": ".1.3.6.1.4.1.8072.1.3.2.4.1.2.7.117.112.115.45.110.117.116.16",
"sensor_index": "16",
"sensor_type": "UPSUPSBypass",
"sensor_descr": "UPS bypass circuit is active",
"group": null,
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 1,
"sensor_limit": null,
"sensor_limit_warn": null,
"sensor_limit_low": null,
"sensor_limit_low_warn": null,
"sensor_alert": 1,
"sensor_custom": "No",
"entPhysicalIndex": "16",
"entPhysicalIndex_measured": null,
"sensor_prev": null,
"user_func": null,
"rrd_type": "GAUGE",
"state_name": "UPSUPSBypass"
},
{
"sensor_deleted": 0,
"sensor_class": "state",
"poller_type": "snmp",
"sensor_oid": ".1.3.6.1.4.1.8072.1.3.2.4.1.2.7.117.112.115.45.110.117.116.19",
"sensor_index": "19",
"sensor_type": "UPSUPSOverloaded",
"sensor_descr": "UPS is overloaded.",
"group": null,
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 1,
"sensor_limit": null,
"sensor_limit_warn": null,
"sensor_limit_low": null,
"sensor_limit_low_warn": null,
"sensor_alert": 1,
"sensor_custom": "No",
"entPhysicalIndex": "19",
"entPhysicalIndex_measured": null,
"sensor_prev": null,
"user_func": null,
"rrd_type": "GAUGE",
"state_name": "UPSUPSOverloaded"
},
{
"sensor_deleted": 0,
"sensor_class": "voltage",
"poller_type": "snmp",
"sensor_oid": ".1.3.6.1.4.1.8072.1.3.2.4.1.2.7.117.112.115.45.110.117.116.4",
"sensor_index": "4",
"sensor_type": "ups-nut",
"sensor_descr": "Battery Voltage",
"group": null,
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 44,
"sensor_limit": 60,
"sensor_limit_warn": null,
"sensor_limit_low": 0,
"sensor_limit_low_warn": 0,
"sensor_alert": 1,
"sensor_custom": "No",
"entPhysicalIndex": null,
"entPhysicalIndex_measured": null,
"sensor_prev": null,
"user_func": null,
"rrd_type": "GAUGE",
"state_name": null
},
{
"sensor_deleted": 0,
"sensor_class": "voltage",
"poller_type": "snmp",
"sensor_oid": ".1.3.6.1.4.1.8072.1.3.2.4.1.2.7.117.112.115.45.110.117.116.5",
"sensor_index": "5",
"sensor_type": "ups-nut",
"sensor_descr": "Battery Nominal",
"group": null,
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 45,
"sensor_limit": 60,
"sensor_limit_warn": null,
"sensor_limit_low": 0,
"sensor_limit_low_warn": 0,
"sensor_alert": 1,
"sensor_custom": "No",
"entPhysicalIndex": null,
"entPhysicalIndex_measured": null,
"sensor_prev": null,
"user_func": null,
"rrd_type": "GAUGE",
"state_name": null
},
{
"sensor_deleted": 0,
"sensor_class": "voltage",
"poller_type": "snmp",
"sensor_oid": ".1.3.6.1.4.1.8072.1.3.2.4.1.2.7.117.112.115.45.110.117.116.6",
"sensor_index": "6",
"sensor_type": "ups-nut",
"sensor_descr": "Line Nominal",
"group": null,
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 230,
"sensor_limit": 0,
"sensor_limit_warn": null,
"sensor_limit_low": 0,
"sensor_limit_low_warn": 0,
"sensor_alert": 1,
"sensor_custom": "No",
"entPhysicalIndex": null,
"entPhysicalIndex_measured": null,
"sensor_prev": null,
"user_func": null,
"rrd_type": "GAUGE",
"state_name": null
},
{
"sensor_deleted": 0,
"sensor_class": "voltage",
"poller_type": "snmp",
"sensor_oid": ".1.3.6.1.4.1.8072.1.3.2.4.1.2.7.117.112.115.45.110.117.116.7",
"sensor_index": "7",
"sensor_type": "ups-nut",
"sensor_descr": "Input Voltage",
"group": null,
"sensor_divisor": 1,
"sensor_multiplier": 1,
"sensor_current": 252,
"sensor_limit": 280,
"sensor_limit_warn": null,
"sensor_limit_low": 200,
"sensor_limit_low_warn": 0,
"sensor_alert": 1,
"sensor_custom": "No",
"entPhysicalIndex": null,
"entPhysicalIndex_measured": null,
"sensor_prev": null,
"user_func": null,
"rrd_type": "GAUGE",
"state_name": null
}
],
"state_indexes": [
{
"state_name": "UPSBatteryCharging",
"state_descr": "False",
"state_draw_graph": 1,
"state_value": 0,
"state_generic_value": 0
},
{
"state_name": "UPSBatteryCharging",
"state_descr": "True",
"state_draw_graph": 1,
"state_value": 1,
"state_generic_value": 1
},
{
"state_name": "UPSBatteryDischarging",
"state_descr": "False",
"state_draw_graph": 1,
"state_value": 0,
"state_generic_value": 0
},
{
"state_name": "UPSBatteryDischarging",
"state_descr": "True",
"state_draw_graph": 1,
"state_value": 1,
"state_generic_value": 1
},
{
"state_name": "UPSBatteryReplace",
"state_descr": "False",
"state_draw_graph": 1,
"state_value": 0,
"state_generic_value": 0
},
{
"state_name": "UPSBatteryReplace",
"state_descr": "True",
"state_draw_graph": 1,
"state_value": 1,
"state_generic_value": 1
},
{
"state_name": "UPSForcedShutdown",
"state_descr": "False",
"state_draw_graph": 1,
"state_value": 0,
"state_generic_value": 0
},
{
"state_name": "UPSForcedShutdown",
"state_descr": "True",
"state_draw_graph": 1,
"state_value": 1,
"state_generic_value": 2
},
{
"state_name": "UPSHighBattery",
"state_descr": "False",
"state_draw_graph": 1,
"state_value": 0,
"state_generic_value": 0
},
{
"state_name": "UPSHighBattery",
"state_descr": "True",
"state_draw_graph": 1,
"state_value": 1,
"state_generic_value": 1
},
{
"state_name": "UPSLowBattery",
"state_descr": "False",
"state_draw_graph": 1,
"state_value": 0,
"state_generic_value": 0
},
{
"state_name": "UPSLowBattery",
"state_descr": "True",
"state_draw_graph": 1,
"state_value": 1,
"state_generic_value": 2
},
{
"state_name": "UPSOffline",
"state_descr": "False",
"state_draw_graph": 1,
"state_value": 0,
"state_generic_value": 0
},
{
"state_name": "UPSOffline",
"state_descr": "True",
"state_draw_graph": 1,
"state_value": 1,
"state_generic_value": 2
},
{
"state_name": "UPSOnBattery",
"state_descr": "False",
"state_draw_graph": 1,
"state_value": 0,
"state_generic_value": 0
},
{
"state_name": "UPSOnBattery",
"state_descr": "True",
"state_draw_graph": 1,
"state_value": 1,
"state_generic_value": 1
},
{
"state_name": "UPSOnLine",
"state_descr": "False",
"state_draw_graph": 1,
"state_value": 0,
"state_generic_value": 1
},
{
"state_name": "UPSOnLine",
"state_descr": "True",
"state_draw_graph": 1,
"state_value": 1,
"state_generic_value": 0
},
{
"state_name": "UPSRuntimeCalibration",
"state_descr": "False",
"state_draw_graph": 1,
"state_value": 0,
"state_generic_value": 0
},
{
"state_name": "UPSRuntimeCalibration",
"state_descr": "True",
"state_draw_graph": 1,
"state_value": 1,
"state_generic_value": 1
},
{
"state_name": "UPSUPSBoost",
"state_descr": "False",
"state_draw_graph": 1,
"state_value": 0,
"state_generic_value": 0
},
{
"state_name": "UPSUPSBoost",
"state_descr": "True",
"state_draw_graph": 1,
"state_value": 1,
"state_generic_value": 1
},
{
"state_name": "UPSUPSBuck",
"state_descr": "False",
"state_draw_graph": 1,
"state_value": 0,
"state_generic_value": 0
},
{
"state_name": "UPSUPSBuck",
"state_descr": "True",
"state_draw_graph": 1,
"state_value": 1,
"state_generic_value": 1
},
{
"state_name": "UPSUPSBypass",
"state_descr": "False",
"state_draw_graph": 1,
"state_value": 0,
"state_generic_value": 0
},
{
"state_name": "UPSUPSBypass",
"state_descr": "True",
"state_draw_graph": 1,
"state_value": 1,
"state_generic_value": 1
},
{
"state_name": "UPSUPSOverloaded",
"state_descr": "False",
"state_draw_graph": 1,
"state_value": 0,
"state_generic_value": 0
},
{
"state_name": "UPSUPSOverloaded",
"state_descr": "True",
"state_draw_graph": 1,
"state_value": 1,
"state_generic_value": 2
}
]
}
"poller": "matches discovery"
}
}

View File

@@ -25,3 +25,4 @@
1.3.6.1.4.1.8072.1.3.2.4.1.2.7.117.112.115.45.110.117.116.20|4|1
1.3.6.1.4.1.8072.1.3.2.4.1.2.7.117.112.115.45.110.117.116.21|4|1
1.3.6.1.4.1.8072.1.3.2.4.1.2.7.117.112.115.45.110.117.116.22|4|1
1.3.6.1.4.1.8072.1.3.2.4.1.2.7.117.112.115.45.110.117.116.24|4|25