Skip to content

docs(ups): NUT's driver retries for 14 seconds, riding out the card's stalls - #1702

Merged
Gerrrt merged 4 commits into
mainfrom
gerrrt/nut-snmp-retries
Nov 24, 2026
Merged

Gerrrt merged 4 commits into
mainfrom
gerrrt/nut-snmp-retries

Conversation

@Gerrrt

@Gerrrt Gerrrt commented Nov 24, 2026

Copy link
Copy Markdown
Owner

What changed

Records the NUT driver change made on morpheus at 18:36 local on 2026-11-23: Extra Arguments to driver gained snmp_timeout = 2 and snmp_retries = 6.

  • shut-down-on-the-ups.md: the two lines in step 1.3's argument list and in the expected ups.conf output, and a new section, Why the driver retries for 14 seconds.
  • observability.md: the data stale paragraph says what the spells are and links to that section.
  • Changelog: the cause, the change and the first hour after it.

Why

The data stale spells come from the UPS card. A 45-minute capture counted 93 stalls in which the card answered nothing for 2 to 8 seconds; ICMP to it lost nothing. NUT's defaults give up at about 6 seconds, and only the two stalls longer than that, 7.1 and 8.2 seconds, became spells, each logged the second its stall crossed 6 seconds. A 14-second retry budget rides out every stall measured and stays inside upsd's 15-second MAXAGE, so a card that is really gone is still marked stale, about 8 seconds later than before.

Blast radius

  • No change to network segmentation or firewall rules
  • No new port published to a VLAN that could not already reach the service
  • No credential added outside secrets/*.sops.yaml

Docs only. The box change is already live; it restarted the driver, upsd and upsmon once at 18:36.

Verification

  • check_docs.py and ./scripts/lint.sh pass
  • Deployed to the lab and confirmed working: live since 18:36. upsc reads driver.parameter.snmp_timeout: 2, driver.parameter.snmp_retries: 6, ups.status: OL. The first hour had no spell in Loki or system.log while the exporter timed out on 10 scrapes of the card, so the stalls continue. 13 of the 49 hours before also had none, so this stays open until a full day is clean.
  • Docs updated: the runbook, observability.md and the changelog

Refs #1503.

🤖 Generated with Claude Code

… stalls

The data stale spells were the UPS card going silent for 2-8 s; NUT's
defaults gave up at about 6 s. Records the snmp_timeout/snmp_retries
arguments applied on morpheus on 2026-11-23 in the runbook, observability
and the changelog.

Refs #1503.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Copilot AI balanced review requested due to automatic review settings November 24, 2026 03:40

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

The documentation conflates SNMP request timeouts with scrape failures and makes an unsupported stale-detection delay claim that needs correction.

2 open issues
What changed in this PR

This docs-only PR records the live NUT driver retry change on morpheus, intended to tolerate brief UPS card SNMP stalls without changing shutdown configuration.

Changes:

  • Adds snmp_timeout = 2 and snmp_retries = 6 to the runbook’s configuration and expected output.
  • Explains the observed stalls and links the monitoring documentation to that explanation.
  • Records the deployment and first-hour observations, with longer-term verification still pending.
File Description
docs/​runbooks/​shut-down-on-the-ups.md Adds retry settings and explains their purpose.
docs/​observability.md Updates the stale-data explanation and links to the runbook.
docs/​changelog.md Records the live change, capture results, and initial observations.

Review effort: Balanced

Comment thread docs/runbooks/shut-down-on-the-ups.md Resolved
Comment thread docs/runbooks/shut-down-on-the-ups.md Resolved
@Gerrrt
Gerrrt enabled auto-merge (squash) November 24, 2026 03:50
Gerrrt and others added 2 commits November 24, 2026 04:44
…retried, not failed

Review on #1702: upsd's MAXAGE counts from the driver's last message, so
the retry budget does not set an outage-detection delay, and the exporter's
5 s is a per-request timeout inside a 45 s scrape.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@Gerrrt
Gerrrt merged commit 3ca5fa3 into main Nov 24, 2026
9 checks passed
@Gerrrt
Gerrrt deleted the gerrrt/nut-snmp-retries branch November 24, 2026 05:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants