coreos/zincati

zincati is calling /pre-reboot during interactive grace period

Closed this issue · 3 comments

Bug Report

Expected Behavior

Zincati acquires a fleetlock semaphore ticket exactly once before rebooting

Actual Behavior

Zincati detects an interactive session then continues trying to acquire the semaphore while waiting
image

Reproduction Steps

  1. log into a host using fleetlock
  2. monitor zincati logs

Ah, I see that it is actually part of the spec that fleetlock implementations must be idempotent.

lucab commented

Ah, I see that it is actually part of the spec that fleetlock implementations must be idempotent.

Correct, on the backend the underlying primitive is an ideal counting semaphore with recursive locking/unlocking (and lock ownership).
Both the pre-reboot and the steady-state endpoint can be called multiple times, and even in unbalanced way.
The idea is that the orchestrated state is only maintained in a strongly consistent way on the backend.
The Zincati client may crash, restart, reset or even disappear at any time; it does not hold any cached state wrt. lock management.

Thanks for confirming. I wrote https://github.com/nivekuil/zincati-consul/, seems to work pretty well with my 3-host cluster!