We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f2e95f7 commit ed9b12dCopy full SHA for ed9b12d
collectors/charts.d.plugin/apcupsd/apcupsd.chart.sh
@@ -154,7 +154,7 @@ BEGIN {
154
/^LOADPCT.*/ { load = \$3 * 100 };
155
/^ITEMP.*/ { temp = \$3 * 100 };
156
/^TIMELEFT.*/ { time = \$3 * 100 };
157
-/^STATUS.*/ { online=(\$3 == \"ONLINE\" || \$3 == \"ONBATT\")?1:0 };
+/^STATUS.*/ { online=(\$3 != \"COMMLOST\" && !(\$3 == \"SHUTTING\" && \$4 == \"DOWN\"))?1:0 };
158
END {
159
print \"BEGIN apcupsd_${host}.online $1\";
160
print \"SET online = \" online;
0 commit comments