towerops/priv/profiles
Graham McIntire c545672efe fix(snmp): auto-rescale implausible temperature readings
Some MikroTik models report `mtxrGaugeValue` (mtxrGaugeUnit=1, °C) in
deci-degrees, while others — like the CRS317 in upstream test data —
return whole degrees. The MIB doesn't disclose which, so the YAML
profile can't pick one literal divisor. Result: a sensor that should
read 56.92 °C was being stored and alerted on as 5,692 °C.

- Towerops.Snmp.SensorScale.normalize/2: divide-by-10 a temperature
  reading until it falls below 150 °C, capped at 3 iterations. Other
  sensor types pass through untouched.
- DevicePollerWorker.poll_simple_sensor wires the normaliser in after
  the YAML divisor is applied, so live polling stops storing bogus
  values immediately.
- DeviceOverheating rule now bounds the query at 150 °C as defense in
  depth so a future scaling glitch never produces a 5,000 °C alert.
- mix towerops.fix_mikrotik_temperature_scaling backfills any rows
  already in the DB by re-running normalize/2 over them.
- routeros.yaml profile gets a comment pointing at the runtime
  normaliser instead of a wrong unconditional divisor.
2026-05-10 12:21:24 -05:00
..
os_detection feat: ePMP firmware extraction + ePMP3000 NetSNMP-quirk detection 2026-05-09 08:34:23 -05:00
os_discovery fix(snmp): auto-rescale implausible temperature readings 2026-05-10 12:21:24 -05:00