Skip to content

builder-reimage: take the node offline before syncing labels - #2697

Merged
djgalloway merged 1 commit into
mainfrom
wip-builder-reimage-offline-first
Aug 31, 2026
Merged

builder-reimage: take the node offline before syncing labels#2697
djgalloway merged 1 commit into
mainfrom
wip-builder-reimage-offline-first

Conversation

@djgalloway

Copy link
Copy Markdown
Contributor

Follow-up to the ceph-dev-build windows saga: the reimage of adami10 today did work, but the Sync Labels stage runs three stages before Prepare Jenkins Node marks the node offline. The moment sync_labels.py restored the windows label, Jenkins dispatched all four queued windows cells onto the still-online, still-dirty node — each failed in ~0.6s on the pre-reimage disk state, seconds before FOG wiped it.

Reorder so the node is marked temporarily offline before labels are synced. prepare_for_reimage is self-contained (needs only the node name, exits 0 if the node doesn't exist) and Detect OS reads the inventory file rather than the live node, so the reorder has no other effects. SKIP_REIMAGE=true label-only syncs behave exactly as before.

The Sync Labels stage ran while the node was still online, three stages
before Prepare Jenkins Node marked it offline for the reimage. A newly
synced label can instantly attract queued builds: when the windows label
was restored to adami10 today, all four queued ceph-dev-build windows
cells landed on the node in the seconds before the reimage wiped it, and
failed on the stale pre-reimage disk state.

Move Prepare Jenkins Node ahead of Sync Labels so the node is already
offline when new labels appear. prepare_for_reimage only needs the node
name and skips cleanly when the node does not exist yet, so it is safe
to run first; Detect OS reads the inventory file, not the live node.

Signed-off-by: David Galloway <david.galloway@ibm.com>
Assisted-by: Claude Fable 5 (claude-fable-5)
@djgalloway
djgalloway merged commit 1bb39ad into main Aug 31, 2026
1 check passed
@djgalloway
djgalloway deleted the wip-builder-reimage-offline-first branch August 31, 2026 15:02
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