[Everflow/ERSPAN] Set correct destination port and mac address when the nexthop is updated for ERSPAN mirror destination#2392
Merged
judyjoseph merged 3 commits intosonic-net:masterfrom Sep 9, 2022
saksarav-nokia:saksarav-nokia-everflow
Merged
[Everflow/ERSPAN] Set correct destination port and mac address when the nexthop is updated for ERSPAN mirror destination#2392judyjoseph merged 3 commits intosonic-net:masterfrom saksarav-nokia:saksarav-nokia-everflow
judyjoseph merged 3 commits intosonic-net:masterfrom
saksarav-nokia:saksarav-nokia-everflow
Conversation
Contributor
Author
|
@judyjoseph @prsunny , could you please review this PR since this is blocking everflow testing with github image |
Contributor
Author
Contributor
|
/easycla |
Contributor
|
/Azurepipelines run Azure.sonic-buildimage |
|
No pipelines are associated with this pull request. |
Contributor
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
judyjoseph
reviewed
Sep 7, 2022
judyjoseph
reviewed
Sep 7, 2022
judyjoseph
reviewed
Sep 7, 2022
nexthop is updated for ERSPAN mirror destination Signed-off-by: Sakthivadivu Saravanaraj <sakthivadivu.saravanaraj@nokia.com>
crash Signed-off-by: Sakthivadivu Saravanaraj <sakthivadivu.saravanaraj@nokia.com>
Contributor
bingwang-ms
reviewed
Sep 8, 2022
Signed-off-by: Sakthivadivu Saravanaraj <sakthivadivu.saravanaraj@nokia.com>
abdosi
reviewed
Sep 9, 2022
abdosi
approved these changes
Sep 9, 2022
bingwang-ms
approved these changes
Sep 9, 2022
judyjoseph
approved these changes
Sep 9, 2022
7 tasks
Contributor
|
@saksarav-nokia , can you raise a new PR in 202205 branch to cherry pick this same change and I will help approve it and merge it so that we don't need to wait for 202205 branch owner to perform the cherry-pick. |
gechiang
pushed a commit
that referenced
this pull request
Sep 16, 2022
…he nexthop is updated for ERSPAN mirror destination (#2392) (#2455) * [Everflow/ERSPAN] Set correct destination port and mac address when the nexthop is updated for ERSPAN mirror destination * [Everflow] Fixed show mirror-session, Acl rule remove failure, orchagent crash Signed-off-by: Sakthivadivu Saravanaraj <sakthivadivu.saravanaraj@nokia.com> Signed-off-by: Sakthivadivu Saravanaraj <sakthivadivu.saravanaraj@nokia.com>
Contributor
|
Removed label "Request for 202205 branch" because we have already merged in by the following PR: |
Janetxxx
pushed a commit
to Janetxxx/sonic-swss
that referenced
this pull request
Nov 10, 2025
…he nexthop is updated for ERSPAN mirror destination (sonic-net#2392) * [Everflow/ERSPAN] Set correct destination port and mac address when the nexthop is updated for ERSPAN mirror destination * [Everflow] Fixed show mirror-session, Acl rule remove failure, orchagent crash Signed-off-by: Sakthivadivu Saravanaraj <sakthivadivu.saravanaraj@nokia.com>
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.
Signed-off-by: Sakthivadivu Saravanaraj sakthivadivu.saravanaraj@nokia.com
What I did
Fixed the issues reported in sonic-net/sonic-buildimage#11457
Why I did it
getNeighborEntry: This function compares Neighbor alias with nexthop alias. Since the alias for nexthop was modified from systemport name to Inband port name in addNextHop, the alias comparison was failing and mirror session was deactivated. Modified the getNeighborEntry to compare the correct alias.
updateSessionDstMac: Modified the code to set the dest mac of the mirror to gMacAddress if it is voq switch
updateSessionDstPort: Set the dest port of the mirror to Rec port if the mirror is ERSPAN mirror
removeRanges: Delete the acl range only if it was created . If the acl entry with mirror action is created when the mirror is not activated, only counter is created. Acl range and acl rule are not created. So removeRanges returns false and hence "Failed to remove acl rule" errors printed many times in syslog.
AclRuleMirror::activate : If Acl rule with mirror action was created before the mirror was activated and deleted, the counter was deleted. So activating the mirror calls AclRule:::createRule without creating counter and orchagent calls sairedis with counter Object as NULL and sai_meta layer returns error, so orchagent crashes. Added code to create counter if not valid before creating the rule.
How I verified it
Verified ingress and egress mirror oc tests passes
Details if related