Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ups.status contains TEST even after ups-selftest is finished (SNMP) #2416

Open
sebvonhelsinki opened this issue Apr 23, 2024 · 0 comments
Open
Assignees
Labels
Incorrect or missing readings On some devices driver-reported values are systemically off (e.g. x10, x0.1, const+Value, etc.) SNMP

Comments

@sebvonhelsinki
Copy link

My setup:

  • ups with network card and snmp
  • debian server with nut and nut-snmp installed and configured

I have recently set up the connection between a UPS and a Debian system. The network card supports the snmp OIDs from RFC1682, so I configured NUT to use the ietf MIB profile. That seems to work, the driver starts and I get correct data displayed from upsc.

But one thing that looks off is that the "ups.status" is constantly showing "OL TEST", even tough no test is running.

From what I gathered, NUT requests all relevant fields and receives correct answers from the network card (correct as in confirming to the RFC and the UPS status as reported in its webinterface). It even displays "ups.test.result" as "done and passed", so it knows that the test was finished successful.

The RFC defines that a read operation against "upsTestId" returns the value of the name of a test in progress, the last test performed if no one is in progress, or a predefined value if no test has been run.
A read operation against "upsTestResultsSummary" returns the status of the test with the id from the above operation. The status indicates if the test is currently running, or the result of the last test if no test is currently in progress.

But in the ietf mapping file for NUT, the return value of "upsTestId" gets mapped straight into "ups.status", no matter what "upsTestResultsSummary" shows :

snmp_info_default("ups.status", ST_FLAG_STRING, SU_INFOSIZE, IETF_OID_UPS_MIB "7.1.0", "", 0, ietf_test_active_info), /* upsTestId */

My questions here:

  • Did I understand the code correctly? If not, why does my client show ups.status = OL TEST ?
  • Does this impact the functionality of NUT? In this list of status values, TEST is not included. Does that mean it is only displayed but ignored when checking if the system should shut down? Or does this prevent shutdowns?
@jimklimov jimklimov added SNMP Incorrect or missing readings On some devices driver-reported values are systemically off (e.g. x10, x0.1, const+Value, etc.) labels Apr 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Incorrect or missing readings On some devices driver-reported values are systemically off (e.g. x10, x0.1, const+Value, etc.) SNMP
Projects
None yet
Development

No branches or pull requests

3 participants