-
Notifications
You must be signed in to change notification settings - Fork 240
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: remove PowerShell from Windows registry interactions #2993
Conversation
6cf43ba
to
3496998
Compare
In #2315, it was changed to conditionally because there was a livesite that our customer got error during the cns start up to set SdnRemoteArpMacAddress. somehow hns was not enabled on their machines so we need to skip this for them. |
@ZetaoZhuang is it okay to try to set it? Or can we not even try to set it if HNS is not enabled? |
from that livesite, if we set it when hns is not enabled, we will get error complaining about something like "hns state path does not exist" or so. that is the reason why we made it conditional. I believe we could set it if it does not complain anymore. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
9b9d321
to
f1f6c51
Compare
Signed-off-by: Evan Baker <[email protected]>
/azp run Azure Container Networking PR |
Azure Pipelines successfully started running 1 pipeline(s). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
remove powershell from windows registry txs Signed-off-by: Evan Baker <[email protected]>
remove powershell from windows registry txs Signed-off-by: Evan Baker <[email protected]>
remove powershell from windows registry txs Signed-off-by: Evan Baker <[email protected]>
) remove powershell from windows registry txs Signed-off-by: Evan Baker <[email protected]>
) remove powershell from windows registry txs Signed-off-by: Evan Baker <[email protected]>
Reason for Change:
PowerShell is heavy (+30mb of memory footprint per invocation). We don't need to use it to interact with the Windows Registry (or ServiceManager) - the Go stdlib has good native bindings that should use instead.
Notes:
This functionality was introduced in #1306. In #2315, it was changed to conditionally set the reg key value only if the HNS path exists. Why? It seems simpler and harmless to always try to set the reg key, so that's what I have done. Unclear if this is problematic - cc @ZetaoZhuang
Supersedes and closes #2974 and #2961 (and #2949)