-
Notifications
You must be signed in to change notification settings - Fork 543
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
If available, read port settings from Config DB first #723
Conversation
Signed-off-by: Andriy Moroz <[email protected]>
retest this please |
if (!port_config_file.empty()) | ||
{ | ||
handlePortConfigFile(p, port_config_file, warm); | ||
} |
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.
should we "throw" if port_config_file.empty() is true in this else branch?
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.
I tried to keep the old logic as it was before
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.
ok, if not in this PR, we probably need add some logic here later in case both places do not have the port config.
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.
Please test the cases where the ports have an alias and then they don't and vice versa for s2s upgrade in both scenarios where we read port configuration from config_db and port_config.ini.
@nikos-github |
@andriymoroz-mlnx Thank you. I understand how it works. I'm just requesting explicit testing of the various scenarios including the ones where the alias is explicitly specified but then it's not and is derived from the port name and vice versa. |
@nikos-github |
@andriymoroz-mlnx If I have a config_db.json file with an alias, where will the code look for the alias? Similarly if I have a config_db.json without an alias, will the code go looking in port_config.ini for one? If the answer to this is yes, then that's wrong. |
@nikos-github |
Signed-off-by: Andriy Moroz <[email protected]>
Signed-off-by: Andriy Moroz [email protected]
What I did
Implemented #2 from this comment to the issue
Why I did it
Fixes issue with the custom port split reset after SONiC-to-SONiC update
How I verified it
Executed SONiC-to-SONiC update on one of setups where we use custom port split. Verified split survived.
Details if related