sources/azure: consolidate ephemeral DHCP configuration#1229
Merged
TheRealFalcon merged 1 commit intoFeb 4, 2022
Conversation
71a7eea to
38958d1
Compare
20b34b8 to
fb93045
Compare
anhvoms
suggested changes
Feb 3, 2022
fb93045 to
2f8bed1
Compare
anhvoms
approved these changes
Feb 3, 2022
2f8bed1 to
07c6541
Compare
07c6541 to
5d4ea2f
Compare
TheRealFalcon
approved these changes
Feb 4, 2022
Contributor
TheRealFalcon
left a comment
There was a problem hiding this comment.
LGTM. There are a couple pylint errors that need to be fixed though.
Introduce: - _setup_ephemeral_networking() to bring up networking. If no iface is specified, it will use net.find_fallback_nic() which is consistent with the previous usage of fallback_interface. This method now tracks the encoded address of the wireserver with a new property `_wireserver_endpoint`. Introduce a timeout parameter to allow for retrying for a specified amount of time. - _teardown_ephemeral_networking() to bring down networking. - _is_ephemeral_networking_up() to check status. Ephemeral networking is now: - Brought up prior to checking IMDS. - Torn down following metadata crawl. - For Savable PPS, torn down prior to waiting for NIC detach. The link must be torn down in advance or we will see errors from cleaning up network after the interface is unplugged. - For Running PPS, torn down after waiting for media switch. The link must be up for media switch to be detected. - For all PPS, after network switch is complete, networking is brought back up to poll for reprovision data and report ready. It will be torn down after metadata crawl is complete like non-PPS paths. Additionally: - Remove EphemeralDHCPv4WithReporting variant in favor of directly using EphemeralDHCPv4. The reporting was only for __enter__ usage which is no longer a used path. Continue to use dhcp_log_cb callback. Signed-off-by: Chris Patterson <cpatterson@microsoft.com>
5d4ea2f to
7695837
Compare
Contributor
Author
Fixed, I accidentally pushed the wrong ref earlier 😵💫 |
Closed
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.
Introduce:
_setup_ephemeral_networking() to bring up networking.
If no iface is specified, it will use net.find_fallback_nic()
which is consistent with the previous usage of fallback_interface.
This method now tracks the encoded address of the wireserver
with a new property
_wireserver_endpoint._teardown_ephemeral_networking() to bring down networking.
_is_ephemeral_networking_up() to check status.
Ephemeral networking is now:
Brought up prior to checking IMDS.
Torn down following metadata crawl.
For Savable PPS, torn down prior to waiting for NIC detach.
The link must be torn down in advance or we will see errors
from cleaning up network after the interface is unplugged.
For Running PPS, torn down after waiting for media switch.
The link must be up for media switch to be detected.
For all PPS, after network switch is complete, networking is
brought back up to poll for reprovision data and report ready.
It will be torn down after metadata crawl is complete like
non-PPS paths.
Additionally:
using EphemeralDHCPv4. The reporting was only for enter usage
which is no longer a used path. Continue to use dhcp_log_cb
callback.
Signed-off-by: Chris Patterson cpatterson@microsoft.com