Skip to content
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

[dualtor][tunnel] Add ipinip testcase #3014

Merged
merged 2 commits into from
Feb 26, 2021

Conversation

lolyu
Copy link
Contributor

@lolyu lolyu commented Feb 22, 2021

Description of PR

Add two testcases:

  1. test_decap_active_tor
    Send encapsulated packet to the active tor, verify the packet is
    decapsulated by the active tor and forwarded to the server.
  2. test_decap_standby_tor
    Send encapsulated packet to the standby tor, verify the packet is
    neither decapsulated and forwarded to server or decapsulated and
    re-encapsulated back to T1s.

Signed-off-by: Longxiang Lyu [email protected]

Summary:
Fixes #2777

Type of change

  • Bug fix
  • Testbed and Framework(new/improvement)
  • Test case(new/improvement)

Approach

What is the motivation for this PR?

Cover the testing scenario that aims to verify that encapsulated packet could be:

  1. decapsulated by the active tor and forwarded to the server.
  2. not decapsulated by the standby tor then either forwarded to the server or re-encapsulated back to T1s.

How did you do it?

  1. Randomly choose a ToR from the testbed.
  2. Randomly choose an interface on the target ToR and toggle it as active or standby
  3. Created encapsulated simulating tunnel traffic
    The outer packet is from the other ToR to the testing target ToR.
    The inner packet is to one of the servers.
  4. Send the encapsulated packet to the target ToR from the ptf intercepted interface of T1s.
  5. Do the verification
    For active mode, the encapsulated packet should be decapped by the target ToR and forwarded to the server.
    For standby mode, the encapsulated packet should not be either forwarded to the server or re-encapsulated back to T1s.

How did you verify/test it?

Run those two tests against dualtor testbeds.

Any platform specific information?

dualtor testbeds

Supported testbed topology if it's a new test case?

Documentation

@lolyu lolyu requested a review from a team as a code owner February 22, 2021 06:54
@lolyu lolyu force-pushed the add_orchagent_ipinip branch from 0d70f12 to a4bc081 Compare February 22, 2021 08:08
@lolyu lolyu force-pushed the add_orchagent_ipinip branch 4 times, most recently from 9fa6589 to 9d0dcd7 Compare February 24, 2021 05:41
Add two testcases:
1. `test_dualtor_ipinip_active_tor`
Send encapsulated packet to the active tor, verify the packet is
decapsulated by the active tor and forwarded to the server.
2. `test_dualtor_ipinip_standby_tor`
Send encapsulated packet to the standby tor, verify the packet is
neither decapsulated and forwarded to server or decapsulated and
re-encapsulated back to T1s.

Signed-off-by: Longxiang Lyu <[email protected]>
@lolyu lolyu force-pushed the add_orchagent_ipinip branch from 9d0dcd7 to 7e80af5 Compare February 24, 2021 06:17
@lolyu
Copy link
Contributor Author

lolyu commented Feb 24, 2021

/Azurepipeline run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@lolyu
Copy link
Contributor Author

lolyu commented Feb 24, 2021

/Azurepipelines run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@lolyu
Copy link
Contributor Author

lolyu commented Feb 25, 2021

/Azurepipelines run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@lolyu lolyu force-pushed the add_orchagent_ipinip branch from fb3dd5d to edf9c2a Compare February 26, 2021 08:34
Signed-off-by: Longxiang Lyu <[email protected]>
@lolyu lolyu force-pushed the add_orchagent_ipinip branch from edf9c2a to 5f9ede1 Compare February 26, 2021 09:26
@yxieca yxieca merged commit f845851 into sonic-net:master Feb 26, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

IP-in-IP Tunnel Test Cases
5 participants