From 5e3cfd879d964ee33bce30ae85f0d7497a50984c Mon Sep 17 00:00:00 2001 From: Frederik Kriewitz Date: Sun, 7 Jul 2024 12:57:20 +0200 Subject: [PATCH] nut-ups: adjust Line Nominal limits (#16180) --- includes/discovery/sensors/voltage/unix.inc.php | 2 +- tests/data/linux_ups-nut.json | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/includes/discovery/sensors/voltage/unix.inc.php b/includes/discovery/sensors/voltage/unix.inc.php index ade8698bca..e899e14774 100644 --- a/includes/discovery/sensors/voltage/unix.inc.php +++ b/includes/discovery/sensors/voltage/unix.inc.php @@ -46,7 +46,7 @@ if (! empty($snmpData)) { $upsnut = [ 4 => ['descr' => 'Battery Voltage', 'LL' => 0, 'LW' => 0, 'W' => null, 'H' => 60], 5 => ['descr' => 'Battery Nominal', 'LL' => 0, 'LW' => 0, 'W' => null, 'H' => 60], - 6 => ['descr' => 'Line Nominal', 'LL' => 0, 'LW' => 0, 'W' => null, 'H' => 0], + 6 => ['descr' => 'Line Nominal', 'LL' => null, 'LW' => null, 'W' => null, 'H' => null], 7 => ['descr' => 'Input Voltage', 'LL' => 200, 'LW' => 0, 'W' => null, 'H' => 280], ]; foreach ($snmpData as $index => $upsData) { diff --git a/tests/data/linux_ups-nut.json b/tests/data/linux_ups-nut.json index 8683b7a6ae..dd24714693 100644 --- a/tests/data/linux_ups-nut.json +++ b/tests/data/linux_ups-nut.json @@ -535,10 +535,10 @@ "sensor_divisor": 1, "sensor_multiplier": 1, "sensor_current": 230, - "sensor_limit": 0, + "sensor_limit": 264.5, "sensor_limit_warn": null, - "sensor_limit_low": 0, - "sensor_limit_low_warn": 0, + "sensor_limit_low": 195.5, + "sensor_limit_low_warn": null, "sensor_alert": 1, "sensor_custom": "No", "entPhysicalIndex": null,