Werk #19840 · Apr 21, 26
Value store: handle corrupt persistence file gracefully instead of crashing
When the value store file (stored in tmpfs) used to persist counter values
across check cycles could not be decoded, the next check execution crashed
with a JSONDecodeError while loading the file. This affected every check on
the host, not just the one whose counters were corrupted.
This most commonly surfaced as a side effect of an upgrade from 2.3 to 2.4, where the on-disk format changed without a compatibility path: files written by 2.3 looked corrupt to 2.4.
Checkmk now logs a warning and falls back to an empty value store when the persistence file cannot be decoded. Counter history is lost for the affected host until the next successful write, but checks continue to run.
Details
- Class:
- Bug Fixes
- Level:
- Trivial
- Component:
- Core
- Versions:
- 3.0.0b1Not yet releasedAll Editions
- 2.5.0p1All Editions
- 2.4.0p39All Editions