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

ECN probabilistic marking with PFC induced congestion #15909

Merged

Conversation

sreejithsreekumaran
Copy link
Contributor

Description of PR

Summary:
Fixes # (issue)

Type of change

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

Back port request

  • 202012
  • 202205
  • 202305
  • 202311
  • 202405

Approach

What is the motivation for this PR?

Add IXIA based test case to demonstrate ECN marking. The test will inject XOFF frame(s) to congest a queue that results in ECN marking.

How did you do it?

Using Snappi infra

How did you verify/test it?

  • setup continous traffic at 99.98% line rate with 1350B packets
  • Test sends a single XOFF frame to the egress port to create congestion in the queue3.
  • A pfc frame is sent with quanta set to values between 500 and 65000, one at a time -
  • read the base ECN counter using serviceability CLI
  • inject XOFF-
  • read the ECN counters
  • At the end of the iteration, once the data is collected, ensure that for each case, with increase in quanta, the marked count at index (n+1) is >= count observed with collection at index (n). Further if the marked count at index (n) > 0, verify that once marking happens, the marking probability increases with an increase in queue occupancy caused by increase in quanta

Any platform specific information?

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

Documentation

@sreejithsreekumaran sreejithsreekumaran marked this pull request as draft December 5, 2024 12:50
@sreejithsreekumaran
Copy link
Contributor Author

Test logs

T0/T1

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
============================================================================================================================================ PASSES =============================================================================================================================================
________________________________________________________________________________________________________ test_ecn_marking_with_pfc_quanta_variance[multidut_port_info0-test_ecn_config0] ________________________________________________________________________________________________________
________________________________________________________________________________________________________ test_ecn_marking_with_pfc_quanta_variance[multidut_port_info0-test_ecn_config1] ________________________________________________________________________________________________________
________________________________________________________________________________________________________ test_ecn_marking_with_pfc_quanta_variance[multidut_port_info0-test_ecn_config2] ________________________________________________________________________________________________________
________________________________________________________________________________________________________ test_ecn_marking_with_pfc_quanta_variance[multidut_port_info0-test_ecn_config3] ________________________________________________________________________________________________________
---------------------------------------------------------------------------------------------------- generated xml file: /run_logs/ixia/17467/2024-12-09-15-34-30/tr_2024-12-09-15-34-30.xml ----------------------------------------------------------------------------------------------------
INFO:root:Can not get Allure report URL. Please check logs
------------------------------------------------------------------------------------------------------------------------------------ live log sessionfinish -------------------------------------------------------------------------------------------------------------------------------------
17:06:43 __init__.pytest_terminal_summary         L0067 INFO   | Can not get Allure report URL. Please check logs
==================================================================================================================================== short test summary info ====================================================================================================================================
PASSED snappi_tests/multidut/ecn/test_multidut_ecn_marking_with_pfc_quanta_variance_with_snappi.py::test_ecn_marking_with_pfc_quanta_variance[multidut_port_info0-test_ecn_config0]
PASSED snappi_tests/multidut/ecn/test_multidut_ecn_marking_with_pfc_quanta_variance_with_snappi.py::test_ecn_marking_with_pfc_quanta_variance[multidut_port_info0-test_ecn_config1]
PASSED snappi_tests/multidut/ecn/test_multidut_ecn_marking_with_pfc_quanta_variance_with_snappi.py::test_ecn_marking_with_pfc_quanta_variance[multidut_port_info0-test_ecn_config2]
PASSED snappi_tests/multidut/ecn/test_multidut_ecn_marking_with_pfc_quanta_variance_with_snappi.py::test_ecn_marking_with_pfc_quanta_variance[multidut_port_info0-test_ecn_config3]
========================================================================================================================== 4 passed, 7 warnings in 5530.72s (1:32:10) ===========================================================================================================================


sonic@snappi-sonic-mgmt-202405:/run_logs/ixia/17467/2024-12-09-15-34-30$ ls -lrth
total 4.0M
-rw-r--r-- 1 sonic sonic  801 Dec  9 15:56 xoff_quanta_variance_results_1_4_5.csv
-rw-r--r-- 1 sonic sonic  822 Dec  9 16:18 xoff_quanta_variance_results_1_4_10.csv
-rw-r--r-- 1 sonic sonic  792 Dec  9 16:39 xoff_quanta_variance_results_2_4_5.csv
-rw-r--r-- 1 sonic sonic  796 Dec  9 17:00 xoff_quanta_variance_results_2_4_10.csv
-rw-r--r-- 1 sonic sonic 2.7K Dec  9 17:06 tr_2024-12-09-15-34-30.xml
-rw-r--r-- 1 sonic sonic 4.0M Dec  9 17:06 test_2024-12-09-15-34-30.log

in T2

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
============================================================================================================================================ PASSES =============================================================================================================================================
________________________________________________________________________________________________________ test_ecn_marking_with_pfc_quanta_variance[multidut_port_info0-test_ecn_config0] ________________________________________________________________________________________________________
________________________________________________________________________________________________________ test_ecn_marking_with_pfc_quanta_variance[multidut_port_info0-test_ecn_config1] ________________________________________________________________________________________________________
________________________________________________________________________________________________________ test_ecn_marking_with_pfc_quanta_variance[multidut_port_info0-test_ecn_config2] ________________________________________________________________________________________________________
________________________________________________________________________________________________________ test_ecn_marking_with_pfc_quanta_variance[multidut_port_info0-test_ecn_config3] ________________________________________________________________________________________________________
---------------------------------------------------------------------------------------------------- generated xml file: /run_logs/ixia/18881/2024-12-09-16-31-38/tr_2024-12-09-16-31-38.xml ----------------------------------------------------------------------------------------------------
INFO:root:Can not get Allure report URL. Please check logs
------------------------------------------------------------------------------------------------------------------------------------ live log sessionfinish -------------------------------------------------------------------------------------------------------------------------------------
17:48:11 __init__.pytest_terminal_summary         L0067 INFO   | Can not get Allure report URL. Please check logs
==================================================================================================================================== short test summary info ====================================================================================================================================
PASSED snappi_tests/multidut/ecn/test_multidut_ecn_marking_with_pfc_quanta_variance_with_snappi.py::test_ecn_marking_with_pfc_quanta_variance[multidut_port_info0-test_ecn_config0]
PASSED snappi_tests/multidut/ecn/test_multidut_ecn_marking_with_pfc_quanta_variance_with_snappi.py::test_ecn_marking_with_pfc_quanta_variance[multidut_port_info0-test_ecn_config1]
PASSED snappi_tests/multidut/ecn/test_multidut_ecn_marking_with_pfc_quanta_variance_with_snappi.py::test_ecn_marking_with_pfc_quanta_variance[multidut_port_info0-test_ecn_config2]
PASSED snappi_tests/multidut/ecn/test_multidut_ecn_marking_with_pfc_quanta_variance_with_snappi.py::test_ecn_marking_with_pfc_quanta_variance[multidut_port_info0-test_ecn_config3]
========================================================================================================================== 4 passed, 7 warnings in 4590.67s (1:16:30) ===========================================================================================================================

sonic@ixia-sonic-mgmt-whitebox:/run_logs/ixia/18881/2024-12-09-16-31-38$ ls -lrth
total 3.9M
-rw-r--r-- 1 sonic sonic  812 Dec  9 16:50 xoff_quanta_variance_results_1_4_5.csv
-rw-r--r-- 1 sonic sonic  810 Dec  9 17:08 xoff_quanta_variance_results_1_4_10.csv
-rw-r--r-- 1 sonic sonic  779 Dec  9 17:25 xoff_quanta_variance_results_2_4_5.csv
-rw-r--r-- 1 sonic sonic  811 Dec  9 17:42 xoff_quanta_variance_results_2_4_10.csv
-rw-r--r-- 1 sonic sonic 2.7K Dec  9 17:48 tr_2024-12-09-16-31-38.xml
-rw-r--r-- 1 sonic sonic 3.9M Dec  9 17:48 test_2024-12-09-16-31-38.log

@sreejithsreekumaran sreejithsreekumaran changed the title ECN probabilistic marking with with PFC induced congestion ECN probabilistic marking with PFC induced congestion Dec 9, 2024
@sdszhang
Copy link
Contributor

sdszhang commented Dec 10, 2024

@abdosi @amitpawar12 @selldinesh for review.

@sreejithsreekumaran sreejithsreekumaran marked this pull request as ready for review December 11, 2024 22:16
@mssonicbld
Copy link
Collaborator

/azp run

Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@mssonicbld
Copy link
Collaborator

/azp run

Copy link

Azure Pipelines successfully started running 1 pipeline(s).

Copy link
Contributor

@sdszhang sdszhang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@yejianquan yejianquan merged commit 1023154 into sonic-net:master Dec 21, 2024
20 checks passed
mssonicbld pushed a commit to mssonicbld/sonic-mgmt that referenced this pull request Dec 21, 2024
Description of PR
Summary:
Fixes # (issue)

Approach
What is the motivation for this PR?
Add IXIA based test case to demonstrate ECN marking. The test will inject XOFF frame(s) to congest a queue that results in ECN marking.

How did you do it?
Using Snappi infra

How did you verify/test it?
setup continous traffic at 99.98% line rate with 1350B packets
Test sends a single XOFF frame to the egress port to create congestion in the queue3.
A pfc frame is sent with quanta set to values between 500 and 65000, one at a time -
read the base ECN counter using serviceability CLI
inject XOFF-
read the ECN counters
At the end of the iteration, once the data is collected, ensure that for each case, with increase in quanta, the marked count at index (n+1) is >= count observed with collection at index (n). Further if the marked count at index (n) > 0, verify that once marking happens, the marking probability increases with an increase in queue occupancy caused by increase in quanta

co-authorized by: [email protected]
@mssonicbld
Copy link
Collaborator

Cherry-pick PR to 202405: #16194

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants