fix(volumemgr): floor deferContentDelete ticker at 1 second#5894
Open
akaouris wants to merge 1 commit intolf-edge:masterfrom
Open
fix(volumemgr): floor deferContentDelete ticker at 1 second#5894akaouris wants to merge 1 commit intolf-edge:masterfrom
akaouris wants to merge 1 commit intolf-edge:masterfrom
Conversation
time.NewTicker(0) panics with "non-positive interval for NewTicker". ctx.deferContentDelete is uint32, so the existing / 10 truncated values 1..9 to 0 and crashed zedbox, triggering a watchdog reboot. Signed-off-by: Alexandros Kaouris <a.kaouris@speedcast.com>
christoph-zededa
approved these changes
May 4, 2026
eriknordmark
approved these changes
May 5, 2026
Contributor
eriknordmark
left a comment
There was a problem hiding this comment.
LGTM. Thanks for fixing this @akaouris
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Pushing a value in
1..9for thetimer.defer.content.deleteglobal setting(via
zcli edge-node update --config="timer.defer.content.delete:N"orequivalent) crashes
zedboxand triggers a watchdog reboot of the device. This was reproduced in an edge node running16.0.0-lts-kvm-amd64.maybeUpdateConfigItemsinvolumemgrcomputes the ticker interval asctx.deferContentDelete / 10, wheredeferContentDeleteisuint32. Forany value below 10 the integer division truncates to
0, andtime.NewTicker(0)panics withnon-positive interval for NewTicker.Because all pillar agents share the
zedboxprocess, this single panictakes down every microservice and the EVE watchdog reboots the node.
Fix
Floor the ticker period at 1 second:
How to test and validate this PR
On a running node:
Followed later by:
Changelog notes
PR Backports
Should be backported to:
Checklist
The tests were done only on x86 device.
And the last but not least:
check them.
Please, check the boxes above after submitting the PR in interactive mode.