Repository navigation
sled-agent: Change timeout waiting to find switch zones - #9699
Merged
Merged
Conversation
sled-agent attempts to find the IPs of all switch zones in two places: 1. During rack setup (to know what to tell Nexus during handoff) 2. When starting a zone that requires external connectivity (to set up NAT entries in dendrite) Prior to this PR, both of these would attempt to find both switches for 5 minutes, and after that point would proceed as long as they'd found at least one. This was fine for NAT entries, because Nexus has a background task that will come back around and sync NAT entries for services eventually. But it's not fine for rack setup: if we proceed with only one switch found when the RSS config specifies uplinks for both, we'll fail to hand off to Nexus (details in #9678). After this change, we change rack setup to wait forever for all switches which have a configured uplink. This means if a switch hasn't come up yet RSS won't proceed, but that should be okay. (It seems _better_ if we could come up with one switch then have Nexus reconcile things after the fact, but that will be a larger change with more risk and more testing difficulty, I think.) The zone startup path still uses a 5-minute timeout. If Nexus is up this is much longer than necessary, since Nexus's bg task will also do this work. But it's critical sled-agent autonomously set up NAT entries for boundary NTP during cold boot, so it seems a little dicey to lower this timeout without much more rigorous testing.
Contributor
Author
|
Testing notes from dublin: I manually shut off one of the switch zones and kicked off RSS. (This reproduced #9678 prior to this change.) RSS got stuck, as expected, waiting to find both switch zones: Once I restarted the missing switch zone, we found it and proceeded with RSS: and successfully handed off to Nexus |
internet-diglett
approved these changes
Jan 27, 2026
internet-diglett
left a comment
Contributor
There was a problem hiding this comment.
Took a few passes over it, LGTM
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.
sled-agent attempts to find the IPs of all switch zones in two places:
Prior to this PR, both of these would attempt to find both switches for 5 minutes, and after that point would proceed as long as they'd found at least one. This is sorta-okay-but-not-really (more on this in another issue shortly) fine for NAT entries, because Nexus has a background task that will come back around and sync NAT entries for services eventually. But it's not fine for rack setup: if we proceed with only one switch found when the RSS config specifies uplinks for both, we'll fail to hand off to Nexus (details in #9678).
After this change, we change rack setup to wait forever for all switches which have a configured uplink. This means if a switch hasn't come up yet RSS won't proceed, but that should be okay. (It seems better if we could come up with one switch then have Nexus reconcile things after the fact, but that will be a larger change with more risk and more testing difficulty, I think.)
Fixes #9678.