Do not allow to add port to .1Q bridge while router port deletion is not completed #2669
Merged
prsunny merged 5 commits intosonic-net:masterfrom Feb 22, 2023
Merged
Do not allow to add port to .1Q bridge while router port deletion is not completed #2669prsunny merged 5 commits intosonic-net:masterfrom
prsunny merged 5 commits intosonic-net:masterfrom
Conversation
stepanblyschak
previously approved these changes
Feb 16, 2023
dgsudharsan
requested changes
Feb 17, 2023
orchagent/portsorch.cpp
Outdated
|
|
||
| if (port.m_rif_id != 0) | ||
| { | ||
| SWSS_LOG_NOTICE("Interface %s is a router port", port.m_alias.c_str()); |
Collaborator
There was a problem hiding this comment.
Can you please add more context in the log message and change it to warning since we are returning here in a failure scenario?
"Cannot create bridge port. Interface %s is a router port"
Collaborator
There was a problem hiding this comment.
@liorghub I recommend changing it to "WARN" log instead of notice since here are returning here in a failure scenario.
Contributor
Author
There was a problem hiding this comment.
@dgsudharsan this is actually a retry mechanism (not failure).
When we print this message we also return false in the next line, DB change is not consumed and we will try again till success.
stepanblyschak
approved these changes
Feb 20, 2023
dgsudharsan
approved these changes
Feb 21, 2023
Collaborator
|
@prsunny any objection to merge? |
dprital
added a commit
to dprital/sonic-buildimage
that referenced
this pull request
Feb 23, 2023
Update sonic-swss submodule pointer to include the following: * baa302e Do not allow to add port to .1Q bridge while router port deletion is not completed ([sonic-net#2669](sonic-net/sonic-swss#2669)) * f66abed Support for tc-dot1p and tc-dscp qosmap ([sonic-net#2559](sonic-net/sonic-swss#2559)) * 35385ad [RouteOrch] Record ROUTE_TABLE entry programming status to APPL_STATE_DB ([sonic-net#2512](sonic-net/sonic-swss#2512)) * 0704f78 [Workaround] EvpnRemoteVnip2pOrch warmboot check failure ([sonic-net#2626](sonic-net/sonic-swss#2626)) * 4df5cab [ResponsePublisher] add pipeline support ([sonic-net#2511](sonic-net/sonic-swss#2511)) Signed-off-by: dprital <[email protected]>
8 tasks
prsunny
pushed a commit
to sonic-net/sonic-buildimage
that referenced
this pull request
Feb 23, 2023
Update sonic-swss submodule pointer to include the following: * baa302e Do not allow to add port to .1Q bridge while router port deletion is not completed ([#2669](sonic-net/sonic-swss#2669)) * f66abed Support for tc-dot1p and tc-dscp qosmap ([#2559](sonic-net/sonic-swss#2559)) * 35385ad [RouteOrch] Record ROUTE_TABLE entry programming status to APPL_STATE_DB ([#2512](sonic-net/sonic-swss#2512)) * 0704f78 [Workaround] EvpnRemoteVnip2pOrch warmboot check failure ([#2626](sonic-net/sonic-swss#2626)) * 4df5cab [ResponsePublisher] add pipeline support ([#2511](sonic-net/sonic-swss#2511))
StormLiangMS
pushed a commit
that referenced
this pull request
Mar 7, 2023
…not completed (#2669) * Do not set port to be a bridge port while it is still a router port
yxieca
pushed a commit
that referenced
this pull request
Mar 8, 2023
…not completed (#2669) * Do not set port to be a bridge port while it is still a router port
Janetxxx
pushed a commit
to Janetxxx/sonic-swss
that referenced
this pull request
Nov 10, 2025
…not completed (sonic-net#2669) * Do not set port to be a bridge port while it is still a router port
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.
What I did
Do not allow to add port to .1Q bridge while router port deletion is not completed.
Why I did it
Adding router port to .1Q bridge is not allowed and will cause to errors in the driver.
How I verified it
Create PortChannel102 and set it as router port.
Make sure PortChannel102 has active neighbors.
Now run the following commands using a shell script (not one by one).
Follow the logs and verify addBridgePort is not perfomed until removeRouterIntfs is completed.
Unitest added as well.
This PR fixes issue sonic-net/sonic-buildimage#13714
Details if related