-
Notifications
You must be signed in to change notification settings - Fork 740
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
[Snappi] Support for DUT statistics - Interface counters, PFC counters, and Queue counters. #13848
[Snappi] Support for DUT statistics - Interface counters, PFC counters, and Queue counters. #13848
Conversation
@vmittal-msft for viz |
return i_stats | ||
|
||
|
||
def get_queue_count(duthost, port): |
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.
@amitpawar12 What is the difference between get_egress_queue_count and this one ? we may need to use better name here ?
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.
@vmittal-msft :
The get_egress_queue_count returns the egress queue packets ONLY for a certain priority. The get_queue_count is internally calling get_egres_queue_count and returns the dictionary for all the priorities, for a given interface and DUT.
This function is one-stop-place to fetch packet counts for all the priorities for a given interface and DUT.
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 let's rename get_queue_count()
to get_queue_count_all_prio()
@amitpawar12 we may plan to add such interface for VoQ stats as well as pfcwd stats so our tests may use them. |
@vmittal-msft : Ideally, voq counters, priority-group counters, and drop counters also needs to be added. But they can be targeted in different PR's. Adding is just a one part, we will need to also enhance the test-cases to incorporate checks with these counters. |
302d050
to
e02f937
Compare
raw_out = duthost.shell("show pfc counters | sed -n '/Port Tx/,/^$/p' | grep '{} '".format(port))['stdout'] | ||
pause_frame_count = raw_out.split() | ||
for m in range(1, len(pause_frame_count)): | ||
pfc_dict[dut_key+'_tx_pfc_'+str(m-1)] = int(pause_frame_count[m].replace(',', '')) |
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.
can we use something like pfc_dict[dut]['tx_pfc'][0]
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.
Thanks for the comment. Nested dictionary will require additional logic to initialize and unpacking them. Needs check for the key errors too.
|
||
# Preparing the dictionary for all 7 priority queues. | ||
for priority in range(7): | ||
dut_key = (duthost.hostname+'_'+port+'_prio_'+str(priority)).lower() |
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.
same here. try to use multi level dictionary for easy access instead of customized key.
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.
Thanks for the comment. The flat dictionary was used because at the end of the test, entire dictionary was converted into data-frame. However, I have added the nested dictionaries for get_interface_stats, get_pfc_count and queue count function and then flattening it, for use in data-frame.
@rraghav-cisco for review, Thanks. |
a0fe77b
to
b5ffaad
Compare
@zhixzhu @vmittal-msft @developfast any further comments? or is it fine to approve the updated change? |
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.
LGTM
…s, and Queue counters. (sonic-net#13848) Description of PR Support to pull the DUT statistics, namely interface counters, PFC counters and Queue counters. This support will enable users to pull the DUT statistics run-time and capture them in form of dictionary for further processing. Summary: Fixes # (issue) sonic-net#13843 Approach What is the motivation for this PR? Currently, there is no one stop-place to fetch the DUT statistics and use them for verification, especially the SNAPPI testcases. There should be some way to pull the DUT statistics ( at least important ones) and use them for verification. How did you do it? Clear counters: Common function to clear interface, PFC and queue counter stats. Interface counters: Ability to fetch the interface counters for a given DUT and port. Returns dictionary with keys - Rx and Tx packet count, Rx and Tx failures (Error + drops + ovr), and Rx and Tx throughput in Mbps. PFC counters: Ability to fetch the PFC counters for a given DUT and port. Returns dictionary with keys - Rx and Tx PFC for the given DUT, port and priority. Queue counters: Ability to fetch the Queue counters for a given DUT and port. Internally calls get_egress_queue_count for all the priorities. Returns dictionary with as key with transmitted packets as counter. How did you verify/test it? These functions are called as part of new testcases for PFC-ECN. for dut, port in dutport_list: f_stats = update_dict(m, f_stats, interface_stats(dut, port)) f_stats = update_dict(m, f_stats, get_pfc_count(dut, port)) f_stats = update_dict(m, f_stats, get_queue_count(dut, port)) These are then used to create CSV with raw DUT statistics and then to summarize the test in the end. co-authorized by: [email protected]
Cherry-pick PR to 202405: #14429 |
…s, and Queue counters. (#13848) Description of PR Support to pull the DUT statistics, namely interface counters, PFC counters and Queue counters. This support will enable users to pull the DUT statistics run-time and capture them in form of dictionary for further processing. Summary: Fixes # (issue) #13843 Approach What is the motivation for this PR? Currently, there is no one stop-place to fetch the DUT statistics and use them for verification, especially the SNAPPI testcases. There should be some way to pull the DUT statistics ( at least important ones) and use them for verification. How did you do it? Clear counters: Common function to clear interface, PFC and queue counter stats. Interface counters: Ability to fetch the interface counters for a given DUT and port. Returns dictionary with keys - Rx and Tx packet count, Rx and Tx failures (Error + drops + ovr), and Rx and Tx throughput in Mbps. PFC counters: Ability to fetch the PFC counters for a given DUT and port. Returns dictionary with keys - Rx and Tx PFC for the given DUT, port and priority. Queue counters: Ability to fetch the Queue counters for a given DUT and port. Internally calls get_egress_queue_count for all the priorities. Returns dictionary with as key with transmitted packets as counter. How did you verify/test it? These functions are called as part of new testcases for PFC-ECN. for dut, port in dutport_list: f_stats = update_dict(m, f_stats, interface_stats(dut, port)) f_stats = update_dict(m, f_stats, get_pfc_count(dut, port)) f_stats = update_dict(m, f_stats, get_queue_count(dut, port)) These are then used to create CSV with raw DUT statistics and then to summarize the test in the end. co-authorized by: [email protected]
…s, and Queue counters. (sonic-net#13848) Description of PR Support to pull the DUT statistics, namely interface counters, PFC counters and Queue counters. This support will enable users to pull the DUT statistics run-time and capture them in form of dictionary for further processing. Summary: Fixes # (issue) sonic-net#13843 Approach What is the motivation for this PR? Currently, there is no one stop-place to fetch the DUT statistics and use them for verification, especially the SNAPPI testcases. There should be some way to pull the DUT statistics ( at least important ones) and use them for verification. How did you do it? Clear counters: Common function to clear interface, PFC and queue counter stats. Interface counters: Ability to fetch the interface counters for a given DUT and port. Returns dictionary with keys - Rx and Tx packet count, Rx and Tx failures (Error + drops + ovr), and Rx and Tx throughput in Mbps. PFC counters: Ability to fetch the PFC counters for a given DUT and port. Returns dictionary with keys - Rx and Tx PFC for the given DUT, port and priority. Queue counters: Ability to fetch the Queue counters for a given DUT and port. Internally calls get_egress_queue_count for all the priorities. Returns dictionary with as key with transmitted packets as counter. How did you verify/test it? These functions are called as part of new testcases for PFC-ECN. for dut, port in dutport_list: f_stats = update_dict(m, f_stats, interface_stats(dut, port)) f_stats = update_dict(m, f_stats, get_pfc_count(dut, port)) f_stats = update_dict(m, f_stats, get_queue_count(dut, port)) These are then used to create CSV with raw DUT statistics and then to summarize the test in the end. co-authorized by: [email protected]
…s, and Queue counters. (sonic-net#13848) Description of PR Support to pull the DUT statistics, namely interface counters, PFC counters and Queue counters. This support will enable users to pull the DUT statistics run-time and capture them in form of dictionary for further processing. Summary: Fixes # (issue) sonic-net#13843 Approach What is the motivation for this PR? Currently, there is no one stop-place to fetch the DUT statistics and use them for verification, especially the SNAPPI testcases. There should be some way to pull the DUT statistics ( at least important ones) and use them for verification. How did you do it? Clear counters: Common function to clear interface, PFC and queue counter stats. Interface counters: Ability to fetch the interface counters for a given DUT and port. Returns dictionary with keys - Rx and Tx packet count, Rx and Tx failures (Error + drops + ovr), and Rx and Tx throughput in Mbps. PFC counters: Ability to fetch the PFC counters for a given DUT and port. Returns dictionary with keys - Rx and Tx PFC for the given DUT, port and priority. Queue counters: Ability to fetch the Queue counters for a given DUT and port. Internally calls get_egress_queue_count for all the priorities. Returns dictionary with as key with transmitted packets as counter. How did you verify/test it? These functions are called as part of new testcases for PFC-ECN. for dut, port in dutport_list: f_stats = update_dict(m, f_stats, interface_stats(dut, port)) f_stats = update_dict(m, f_stats, get_pfc_count(dut, port)) f_stats = update_dict(m, f_stats, get_queue_count(dut, port)) These are then used to create CSV with raw DUT statistics and then to summarize the test in the end. co-authorized by: [email protected]
…14416) Description of PR Summary: Adding dut counter verification for PFC Oversubscription cases Fixes # (issue) #13596 Approach Dependency #13848 What is the motivation for this PR? Verifies the packet drops from the dut interface counters How did you do it? How did you verify/test it? Any platform specific information? Supported testbed topology if it's a new test case? Documentation Output 18:43:03 test_m2o_oversubscribe_lossless.test_m2o L0077 INFO | Running test for testbed subtype: single-dut-single-asic 18:43:03 snappi_fixtures.__intf_config_multidut L0796 INFO | Configuring Dut: sonic-s6100-dut1 with port Ethernet0 with IP 20.1.1.1/24 18:43:05 snappi_fixtures.__intf_config_multidut L0796 INFO | Configuring Dut: sonic-s6100-dut1 with port Ethernet4 with IP 20.1.2.1/24 18:43:07 snappi_fixtures.__intf_config_multidut L0796 INFO | Configuring Dut: sonic-s6100-dut1 with port Ethernet8 with IP 20.1.3.1/24 18:43:10 connection._warn L0246 WARNING| Verification of certificates is disabled 18:43:10 connection._info L0243 INFO | Determining the platform and rest_port using the 10.36.78.59 address... 18:43:10 connection._warn L0246 WARNING| Unable to connect to http://10.36.78.59:443. 18:43:10 connection._info L0243 INFO | Connection established to https://10.36.78.59:443 on linux 18:43:24 connection._info L0243 INFO | Using IxNetwork api server version 10.20.2403.2 18:43:24 connection._info L0243 INFO | User info IxNetwork/ixnetworkweb/admin-68-20480 18:43:25 snappi_api.info L1132 INFO | snappi-0.9.1 18:43:25 snappi_api.info L1132 INFO | snappi_ixnetwork-0.8.2 18:43:25 snappi_api.info L1132 INFO | ixnetwork_restpy-1.0.64 18:43:25 snappi_api.info L1132 INFO | Config validation 0.020s 18:43:27 snappi_api.info L1132 INFO | Ports configuration 1.544s 18:43:27 snappi_api.info L1132 INFO | Captures configuration 0.161s 18:43:30 snappi_api.info L1132 INFO | Add location hosts [10.36.78.53] 2.285s 18:43:34 snappi_api.info L1132 INFO | Location hosts ready [10.36.78.53] 4.212s 18:43:35 snappi_api.info L1132 INFO | Speed conversion is not require for (port.name, speed) : [('Port 0', 'novusHundredGigNonFanOut'), ('Port 1', 'novusHundredGigNonFanOut'), ('Port 2', 'novusHundredGigNonFanOut')] 18:43:35 snappi_api.info L1132 INFO | Aggregation mode speed change 0.479s 18:43:42 snappi_api.info L1132 INFO | Location preemption [10.36.78.53;6;1, 10.36.78.53;6;2, 10.36.78.53;6;3] 0.111s 18:44:07 snappi_api.info L1132 INFO | Location connect [Port 0, Port 1, Port 2] 25.066s 18:44:07 snappi_api.warning L1138 WARNING| Port 0 connectedLinkDown 18:44:07 snappi_api.warning L1138 WARNING| Port 1 connectedLinkDown 18:44:07 snappi_api.warning L1138 WARNING| Port 2 connectedLinkDown 18:44:07 snappi_api.info L1132 INFO | Location state check [Port 0, Port 1, Port 2] 0.245s 18:44:07 snappi_api.info L1132 INFO | Location configuration 39.389s 18:44:19 snappi_api.info L1132 INFO | Layer1 configuration 12.161s 18:44:19 snappi_api.info L1132 INFO | Lag Configuration 0.082s 18:44:19 snappi_api.info L1132 INFO | Convert device config : 0.224s 18:44:19 snappi_api.info L1132 INFO | Create IxNetwork device config : 0.000s 18:44:20 snappi_api.info L1132 INFO | Push IxNetwork device config : 0.641s 18:44:20 snappi_api.info L1132 INFO | Devices configuration 0.940s 18:44:25 snappi_api.info L1132 INFO | Flows configuration 5.128s 18:45:25 snappi_api.info L1132 INFO | Start interfaces 59.556s 18:45:25 snappi_api.info L1132 INFO | IxNet - The Traffic Item was modified. Please perform a Traffic Generate to update the associated traffic Flow Groups 18:45:30 traffic_generation.run_traffic L0322 INFO | Wait for Arp to Resolve ... 18:45:36 traffic_generation.run_traffic L0322 INFO | Starting transmit on all flows ... 18:48:41 snappi_api.info L1132 INFO | Flows generate/apply 184.474s 18:48:54 snappi_api.info L1132 INFO | Flows clear statistics 12.396s 18:48:54 snappi_api.info L1132 INFO | Captures start 0.000s 18:49:17 snappi_api.info L1132 INFO | Flows start 22.926s 18:49:17 traffic_generation.run_traffic L0322 INFO | Polling DUT for traffic statistics for 15 seconds ... 18:49:23 traffic_generation.run_traffic L0322 INFO | Polling TGEN for in-flight traffic statistics... 18:49:25 traffic_generation.run_traffic L0322 INFO | In-flight traffic statistics for flows: ['Test Flow 1 -> 0', 'Test Flow 2 -> 0', 'Background Flow 1 -> 0', 'Background Flow 2 -> 0'] 18:49:25 traffic_generation.run_traffic L0322 INFO | In-flight TX frames: [6312174, 6312175, 6310775, 6310775] 18:49:25 traffic_generation.run_traffic L0322 INFO | In-flight RX frames: [6311444, 6311444, 6310765, 6310766] 18:49:29 traffic_generation.run_traffic L0322 INFO | DUT polling complete 18:49:29 traffic_generation.run_traffic L0322 INFO | Checking if all flows have stopped. Attempt #1 18:49:30 traffic_generation.run_traffic L0322 INFO | ['started', 'started', 'started', 'started'] 18:49:31 traffic_generation.run_traffic L0322 INFO | Checking if all flows have stopped. Attempt #2 18:49:32 traffic_generation.run_traffic L0322 INFO | ['started', 'started', 'started', 'started'] 18:49:33 traffic_generation.run_traffic L0322 INFO | Checking if all flows have stopped. Attempt #3 18:49:35 traffic_generation.run_traffic L0322 INFO | ['started', 'started', 'stopped', 'stopped'] 18:49:36 traffic_generation.run_traffic L0322 INFO | Checking if all flows have stopped. Attempt #4 18:49:37 traffic_generation.run_traffic L0322 INFO | ['stopped', 'stopped', 'stopped', 'stopped'] 18:49:37 traffic_generation.run_traffic L0322 INFO | All test and background traffic flows stopped 18:49:39 traffic_generation.run_traffic L0322 INFO | Dumping per-flow statistics 18:49:40 traffic_generation.run_traffic L0322 INFO | Stopping transmit on all remaining flows 18:49:41 snappi_fixtures.cleanup_config L0952 INFO | Removing Configuration on Dut: sonic-s6100-dut1 with port Ethernet0 with ip :20.1.1.1/24 18:49:43 snappi_fixtures.cleanup_config L0952 INFO | Removing Configuration on Dut: sonic-s6100-dut1 with port Ethernet4 with ip :20.1.2.1/24 18:49:45 snappi_fixtures.cleanup_config L0952 INFO | Removing Configuration on Dut: sonic-s6100-dut1 with port Ethernet8 with ip :20.1.3.1/24 PASSED [100%] ------------------------------------------------------------ live log teardown ------------------------------------------------------------- 18:49:47 init.pytest_runtest_teardown L0049 INFO | collect memory after test test_m2o_oversubscribe_lossless[multidut_port_info0] 18:49:48 init.pytest_runtest_teardown L0072 INFO | After test: collected memory_values {'before_test': {'sonic-s6100-dut1': {'monit': {'memory_usage': 13.9}}}, 'after_test': {'sonic-s6100-dut1': {'monit': {'memory_usage': 31.3}}}} 18:49:48 init._fixture_generator_decorator L0093 INFO | -------------------- fixture snappi_api teardown starts -------------------- 18:50:03 init._fixture_generator_decorator L0102 INFO | -------------------- fixture snappi_api teardown ends -------------------- 18:50:03 init._fixture_generator_decorator L0093 INFO | -------------------- fixture start_pfcwd_after_test teardown starts -------------------- 18:50:05 init._fixture_generator_decorator L0102 INFO | -------------------- fixture start_pfcwd_after_test teardown ends -------------------- 18:50:05 init._fixture_generator_decorator L0093 INFO | -------------------- fixture rand_lossy_prio teardown starts -------------------- 18:50:05 init._fixture_generator_decorator L0102 INFO | -------------------- fixture rand_lossy_prio teardown ends -------------------- 18:50:05 init._fixture_generator_decorator L0093 INFO | -------------------- fixture rand_lossless_prio teardown starts -------------------- 18:50:05 init._fixture_generator_decorator L0102 INFO | -------------------- fixture rand_lossless_prio teardown ends -------------------- 18:50:05 init._fixture_generator_decorator L0093 INFO | -------------------- fixture enable_packet_aging_after_test teardown starts -------------------- 18:50:05 init._fixture_generator_decorator L0102 INFO | -------------------- fixture enable_packet_aging_after_test teardown ends -------------------- 18:50:05 conftest.core_dump_and_config_check L2203 INFO | Dumping Disk and Memory Space informataion after test on sonic-s6100-dut1 18:50:06 conftest.core_dump_and_config_check L2207 INFO | Collecting core dumps after test on sonic-s6100-dut1 18:50:07 conftest.core_dump_and_config_check L2224 INFO | Collecting running config after test on sonic-s6100-dut1 18:50:08 conftest.core_dump_and_config_check L2352 WARNING| Core dump or config check failed for test_m2o_oversubscribe_lossless.py, results: {"core_dump_check": {"pass": true, "new_core_dumps": {"sonic-s6100-dut1": []}}, "config_db_check": {"pass": false, "pre_only_config": {"sonic-s6100-dut1": {"null": {"INTERFACE": {"Ethernet0": {}, "Ethernet12": {}, "Ethernet4": {}, "Ethernet8": {}, "Ethernet0|21.1.1.1/24": {}, "Ethernet12|24.1.1.1/24": {}, "Ethernet4|22.1.1.1/24": {}, "Ethernet8|23.1.1.1/24": {}}}}}, "cur_only_config": {"sonic-s6100-dut1": {"null": {}}}, "inconsistent_config": {"sonic-s6100-dut1": {"null": {"PFC_WD": {"pre_value": {"GLOBAL": {"POLL_INTERVAL": "200"}}, "cur_value": {"Ethernet0": {"action": "drop", "detection_time": "200", "restoration_time": "200"}, "Ethernet12": {"action": "drop", "detection_time": "200", "restoration_time": "200"}, "Ethernet4": {"action": "drop", "detection_time": "200", "restoration_time": "200"}, "Ethernet8": {"action": "drop", "detection_time": "200", "restoration_time": "200"}, "GLOBAL": {"POLL_INTERVAL": "200"}}}}}}}} 18:50:08 conftest.__dut_reload L2091 INFO | dut reload called on sonic-s6100-dut1 18:50:10 parallel.on_terminate L0085 INFO | process __dut_reload-- terminated with exit code None 18:50:10 parallel.parallel_run L0221 INFO | Completed running processes for target "__dut_reload" in 0:00:01.443244 seconds 18:50:10 conftest.core_dump_and_config_check L2362 INFO | -----$$$$$$$$$$--------------- Executing config reload of config_db_bgp.json -------------$$$$$$$$$$$$$$ ============================================================= warnings summary ============================================================= ../../../../usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755 /usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755: PytestAssertRewriteWarning: Module already imported so cannot be rewritten: tests.common.plugins.loganalyzer self.import_plugin(import_spec) ../../../../usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755 /usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755: PytestAssertRewriteWarning: Module already imported so cannot be rewritten: tests.common.plugins.sanity_check self.import_plugin(import_spec) ../../../../usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755 /usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755: PytestAssertRewriteWarning: Module already imported so cannot be rewritten: tests.common.plugins.test_completeness self.import_plugin(import_spec) ../../../../usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755 /usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755: PytestAssertRewriteWarning: Module already imported so cannot be rewritten: tests.common.dualtor self.import_plugin(import_spec) ../../../../usr/local/lib/python3.8/dist-packages/paramiko/transport.py:236 /usr/local/lib/python3.8/dist-packages/paramiko/transport.py:236: CryptographyDeprecationWarning: Blowfish has been deprecated "class": algorithms.Blowfish, snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] /usr/local/lib/python3.8/dist-packages/pytest_ansible/module_dispatcher/v213.py:100: UserWarning: provided hosts list is empty, only localhost is available warnings.warn("provided hosts list is empty, only localhost is available") snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] /var/AzDevOps/.local/lib/python3.8/site-packages/snappi_ixnetwork/device/utils.py:2: DeprecationWarning: Using or importing the ABCs from 'collections' instead of from 'collections.abc' is deprecated since Python 3.3, and in 3.10 it will stop working from collections import namedtuple, Mapping snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] /usr/local/lib/python3.8/dist-packages/ixnetwork_restpy/testplatform/sessions/sessions.py:59: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead. elif LooseVersion(build_number) < LooseVersion('8.52'): -- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html ---------------------------------------------------------- live log sessionfinish ---------------------------------------------------------- 18:50:41 init.pytest_terminal_summary L0067 INFO | Can not get Allure report URL. Please check logs ================================================ 1 passed, 13 warnings in 473.16s (0:07:53) ================================================ co-authorized by: [email protected]
…onic-net#14416) Description of PR Summary: Adding dut counter verification for PFC Oversubscription cases Fixes # (issue) sonic-net#13596 Approach Dependency sonic-net#13848 What is the motivation for this PR? Verifies the packet drops from the dut interface counters How did you do it? How did you verify/test it? Any platform specific information? Supported testbed topology if it's a new test case? Documentation Output 18:43:03 test_m2o_oversubscribe_lossless.test_m2o L0077 INFO | Running test for testbed subtype: single-dut-single-asic 18:43:03 snappi_fixtures.__intf_config_multidut L0796 INFO | Configuring Dut: sonic-s6100-dut1 with port Ethernet0 with IP 20.1.1.1/24 18:43:05 snappi_fixtures.__intf_config_multidut L0796 INFO | Configuring Dut: sonic-s6100-dut1 with port Ethernet4 with IP 20.1.2.1/24 18:43:07 snappi_fixtures.__intf_config_multidut L0796 INFO | Configuring Dut: sonic-s6100-dut1 with port Ethernet8 with IP 20.1.3.1/24 18:43:10 connection._warn L0246 WARNING| Verification of certificates is disabled 18:43:10 connection._info L0243 INFO | Determining the platform and rest_port using the 10.36.78.59 address... 18:43:10 connection._warn L0246 WARNING| Unable to connect to http://10.36.78.59:443. 18:43:10 connection._info L0243 INFO | Connection established to https://10.36.78.59:443 on linux 18:43:24 connection._info L0243 INFO | Using IxNetwork api server version 10.20.2403.2 18:43:24 connection._info L0243 INFO | User info IxNetwork/ixnetworkweb/admin-68-20480 18:43:25 snappi_api.info L1132 INFO | snappi-0.9.1 18:43:25 snappi_api.info L1132 INFO | snappi_ixnetwork-0.8.2 18:43:25 snappi_api.info L1132 INFO | ixnetwork_restpy-1.0.64 18:43:25 snappi_api.info L1132 INFO | Config validation 0.020s 18:43:27 snappi_api.info L1132 INFO | Ports configuration 1.544s 18:43:27 snappi_api.info L1132 INFO | Captures configuration 0.161s 18:43:30 snappi_api.info L1132 INFO | Add location hosts [10.36.78.53] 2.285s 18:43:34 snappi_api.info L1132 INFO | Location hosts ready [10.36.78.53] 4.212s 18:43:35 snappi_api.info L1132 INFO | Speed conversion is not require for (port.name, speed) : [('Port 0', 'novusHundredGigNonFanOut'), ('Port 1', 'novusHundredGigNonFanOut'), ('Port 2', 'novusHundredGigNonFanOut')] 18:43:35 snappi_api.info L1132 INFO | Aggregation mode speed change 0.479s 18:43:42 snappi_api.info L1132 INFO | Location preemption [10.36.78.53;6;1, 10.36.78.53;6;2, 10.36.78.53;6;3] 0.111s 18:44:07 snappi_api.info L1132 INFO | Location connect [Port 0, Port 1, Port 2] 25.066s 18:44:07 snappi_api.warning L1138 WARNING| Port 0 connectedLinkDown 18:44:07 snappi_api.warning L1138 WARNING| Port 1 connectedLinkDown 18:44:07 snappi_api.warning L1138 WARNING| Port 2 connectedLinkDown 18:44:07 snappi_api.info L1132 INFO | Location state check [Port 0, Port 1, Port 2] 0.245s 18:44:07 snappi_api.info L1132 INFO | Location configuration 39.389s 18:44:19 snappi_api.info L1132 INFO | Layer1 configuration 12.161s 18:44:19 snappi_api.info L1132 INFO | Lag Configuration 0.082s 18:44:19 snappi_api.info L1132 INFO | Convert device config : 0.224s 18:44:19 snappi_api.info L1132 INFO | Create IxNetwork device config : 0.000s 18:44:20 snappi_api.info L1132 INFO | Push IxNetwork device config : 0.641s 18:44:20 snappi_api.info L1132 INFO | Devices configuration 0.940s 18:44:25 snappi_api.info L1132 INFO | Flows configuration 5.128s 18:45:25 snappi_api.info L1132 INFO | Start interfaces 59.556s 18:45:25 snappi_api.info L1132 INFO | IxNet - The Traffic Item was modified. Please perform a Traffic Generate to update the associated traffic Flow Groups 18:45:30 traffic_generation.run_traffic L0322 INFO | Wait for Arp to Resolve ... 18:45:36 traffic_generation.run_traffic L0322 INFO | Starting transmit on all flows ... 18:48:41 snappi_api.info L1132 INFO | Flows generate/apply 184.474s 18:48:54 snappi_api.info L1132 INFO | Flows clear statistics 12.396s 18:48:54 snappi_api.info L1132 INFO | Captures start 0.000s 18:49:17 snappi_api.info L1132 INFO | Flows start 22.926s 18:49:17 traffic_generation.run_traffic L0322 INFO | Polling DUT for traffic statistics for 15 seconds ... 18:49:23 traffic_generation.run_traffic L0322 INFO | Polling TGEN for in-flight traffic statistics... 18:49:25 traffic_generation.run_traffic L0322 INFO | In-flight traffic statistics for flows: ['Test Flow 1 -> 0', 'Test Flow 2 -> 0', 'Background Flow 1 -> 0', 'Background Flow 2 -> 0'] 18:49:25 traffic_generation.run_traffic L0322 INFO | In-flight TX frames: [6312174, 6312175, 6310775, 6310775] 18:49:25 traffic_generation.run_traffic L0322 INFO | In-flight RX frames: [6311444, 6311444, 6310765, 6310766] 18:49:29 traffic_generation.run_traffic L0322 INFO | DUT polling complete 18:49:29 traffic_generation.run_traffic L0322 INFO | Checking if all flows have stopped. Attempt #1 18:49:30 traffic_generation.run_traffic L0322 INFO | ['started', 'started', 'started', 'started'] 18:49:31 traffic_generation.run_traffic L0322 INFO | Checking if all flows have stopped. Attempt #2 18:49:32 traffic_generation.run_traffic L0322 INFO | ['started', 'started', 'started', 'started'] 18:49:33 traffic_generation.run_traffic L0322 INFO | Checking if all flows have stopped. Attempt sonic-net#3 18:49:35 traffic_generation.run_traffic L0322 INFO | ['started', 'started', 'stopped', 'stopped'] 18:49:36 traffic_generation.run_traffic L0322 INFO | Checking if all flows have stopped. Attempt sonic-net#4 18:49:37 traffic_generation.run_traffic L0322 INFO | ['stopped', 'stopped', 'stopped', 'stopped'] 18:49:37 traffic_generation.run_traffic L0322 INFO | All test and background traffic flows stopped 18:49:39 traffic_generation.run_traffic L0322 INFO | Dumping per-flow statistics 18:49:40 traffic_generation.run_traffic L0322 INFO | Stopping transmit on all remaining flows 18:49:41 snappi_fixtures.cleanup_config L0952 INFO | Removing Configuration on Dut: sonic-s6100-dut1 with port Ethernet0 with ip :20.1.1.1/24 18:49:43 snappi_fixtures.cleanup_config L0952 INFO | Removing Configuration on Dut: sonic-s6100-dut1 with port Ethernet4 with ip :20.1.2.1/24 18:49:45 snappi_fixtures.cleanup_config L0952 INFO | Removing Configuration on Dut: sonic-s6100-dut1 with port Ethernet8 with ip :20.1.3.1/24 PASSED [100%] ------------------------------------------------------------ live log teardown ------------------------------------------------------------- 18:49:47 init.pytest_runtest_teardown L0049 INFO | collect memory after test test_m2o_oversubscribe_lossless[multidut_port_info0] 18:49:48 init.pytest_runtest_teardown L0072 INFO | After test: collected memory_values {'before_test': {'sonic-s6100-dut1': {'monit': {'memory_usage': 13.9}}}, 'after_test': {'sonic-s6100-dut1': {'monit': {'memory_usage': 31.3}}}} 18:49:48 init._fixture_generator_decorator L0093 INFO | -------------------- fixture snappi_api teardown starts -------------------- 18:50:03 init._fixture_generator_decorator L0102 INFO | -------------------- fixture snappi_api teardown ends -------------------- 18:50:03 init._fixture_generator_decorator L0093 INFO | -------------------- fixture start_pfcwd_after_test teardown starts -------------------- 18:50:05 init._fixture_generator_decorator L0102 INFO | -------------------- fixture start_pfcwd_after_test teardown ends -------------------- 18:50:05 init._fixture_generator_decorator L0093 INFO | -------------------- fixture rand_lossy_prio teardown starts -------------------- 18:50:05 init._fixture_generator_decorator L0102 INFO | -------------------- fixture rand_lossy_prio teardown ends -------------------- 18:50:05 init._fixture_generator_decorator L0093 INFO | -------------------- fixture rand_lossless_prio teardown starts -------------------- 18:50:05 init._fixture_generator_decorator L0102 INFO | -------------------- fixture rand_lossless_prio teardown ends -------------------- 18:50:05 init._fixture_generator_decorator L0093 INFO | -------------------- fixture enable_packet_aging_after_test teardown starts -------------------- 18:50:05 init._fixture_generator_decorator L0102 INFO | -------------------- fixture enable_packet_aging_after_test teardown ends -------------------- 18:50:05 conftest.core_dump_and_config_check L2203 INFO | Dumping Disk and Memory Space informataion after test on sonic-s6100-dut1 18:50:06 conftest.core_dump_and_config_check L2207 INFO | Collecting core dumps after test on sonic-s6100-dut1 18:50:07 conftest.core_dump_and_config_check L2224 INFO | Collecting running config after test on sonic-s6100-dut1 18:50:08 conftest.core_dump_and_config_check L2352 WARNING| Core dump or config check failed for test_m2o_oversubscribe_lossless.py, results: {"core_dump_check": {"pass": true, "new_core_dumps": {"sonic-s6100-dut1": []}}, "config_db_check": {"pass": false, "pre_only_config": {"sonic-s6100-dut1": {"null": {"INTERFACE": {"Ethernet0": {}, "Ethernet12": {}, "Ethernet4": {}, "Ethernet8": {}, "Ethernet0|21.1.1.1/24": {}, "Ethernet12|24.1.1.1/24": {}, "Ethernet4|22.1.1.1/24": {}, "Ethernet8|23.1.1.1/24": {}}}}}, "cur_only_config": {"sonic-s6100-dut1": {"null": {}}}, "inconsistent_config": {"sonic-s6100-dut1": {"null": {"PFC_WD": {"pre_value": {"GLOBAL": {"POLL_INTERVAL": "200"}}, "cur_value": {"Ethernet0": {"action": "drop", "detection_time": "200", "restoration_time": "200"}, "Ethernet12": {"action": "drop", "detection_time": "200", "restoration_time": "200"}, "Ethernet4": {"action": "drop", "detection_time": "200", "restoration_time": "200"}, "Ethernet8": {"action": "drop", "detection_time": "200", "restoration_time": "200"}, "GLOBAL": {"POLL_INTERVAL": "200"}}}}}}}} 18:50:08 conftest.__dut_reload L2091 INFO | dut reload called on sonic-s6100-dut1 18:50:10 parallel.on_terminate L0085 INFO | process __dut_reload-- terminated with exit code None 18:50:10 parallel.parallel_run L0221 INFO | Completed running processes for target "__dut_reload" in 0:00:01.443244 seconds 18:50:10 conftest.core_dump_and_config_check L2362 INFO | -----$$$$$$$$$$--------------- Executing config reload of config_db_bgp.json -------------$$$$$$$$$$$$$$ ============================================================= warnings summary ============================================================= ../../../../usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755 /usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755: PytestAssertRewriteWarning: Module already imported so cannot be rewritten: tests.common.plugins.loganalyzer self.import_plugin(import_spec) ../../../../usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755 /usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755: PytestAssertRewriteWarning: Module already imported so cannot be rewritten: tests.common.plugins.sanity_check self.import_plugin(import_spec) ../../../../usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755 /usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755: PytestAssertRewriteWarning: Module already imported so cannot be rewritten: tests.common.plugins.test_completeness self.import_plugin(import_spec) ../../../../usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755 /usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755: PytestAssertRewriteWarning: Module already imported so cannot be rewritten: tests.common.dualtor self.import_plugin(import_spec) ../../../../usr/local/lib/python3.8/dist-packages/paramiko/transport.py:236 /usr/local/lib/python3.8/dist-packages/paramiko/transport.py:236: CryptographyDeprecationWarning: Blowfish has been deprecated "class": algorithms.Blowfish, snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] /usr/local/lib/python3.8/dist-packages/pytest_ansible/module_dispatcher/v213.py:100: UserWarning: provided hosts list is empty, only localhost is available warnings.warn("provided hosts list is empty, only localhost is available") snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] /var/AzDevOps/.local/lib/python3.8/site-packages/snappi_ixnetwork/device/utils.py:2: DeprecationWarning: Using or importing the ABCs from 'collections' instead of from 'collections.abc' is deprecated since Python 3.3, and in 3.10 it will stop working from collections import namedtuple, Mapping snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] /usr/local/lib/python3.8/dist-packages/ixnetwork_restpy/testplatform/sessions/sessions.py:59: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead. elif LooseVersion(build_number) < LooseVersion('8.52'): -- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html ---------------------------------------------------------- live log sessionfinish ---------------------------------------------------------- 18:50:41 init.pytest_terminal_summary L0067 INFO | Can not get Allure report URL. Please check logs ================================================ 1 passed, 13 warnings in 473.16s (0:07:53) ================================================ co-authorized by: [email protected]
…14416) Description of PR Summary: Adding dut counter verification for PFC Oversubscription cases Fixes # (issue) #13596 Approach Dependency #13848 What is the motivation for this PR? Verifies the packet drops from the dut interface counters How did you do it? How did you verify/test it? Any platform specific information? Supported testbed topology if it's a new test case? Documentation Output 18:43:03 test_m2o_oversubscribe_lossless.test_m2o L0077 INFO | Running test for testbed subtype: single-dut-single-asic 18:43:03 snappi_fixtures.__intf_config_multidut L0796 INFO | Configuring Dut: sonic-s6100-dut1 with port Ethernet0 with IP 20.1.1.1/24 18:43:05 snappi_fixtures.__intf_config_multidut L0796 INFO | Configuring Dut: sonic-s6100-dut1 with port Ethernet4 with IP 20.1.2.1/24 18:43:07 snappi_fixtures.__intf_config_multidut L0796 INFO | Configuring Dut: sonic-s6100-dut1 with port Ethernet8 with IP 20.1.3.1/24 18:43:10 connection._warn L0246 WARNING| Verification of certificates is disabled 18:43:10 connection._info L0243 INFO | Determining the platform and rest_port using the 10.36.78.59 address... 18:43:10 connection._warn L0246 WARNING| Unable to connect to http://10.36.78.59:443. 18:43:10 connection._info L0243 INFO | Connection established to https://10.36.78.59:443 on linux 18:43:24 connection._info L0243 INFO | Using IxNetwork api server version 10.20.2403.2 18:43:24 connection._info L0243 INFO | User info IxNetwork/ixnetworkweb/admin-68-20480 18:43:25 snappi_api.info L1132 INFO | snappi-0.9.1 18:43:25 snappi_api.info L1132 INFO | snappi_ixnetwork-0.8.2 18:43:25 snappi_api.info L1132 INFO | ixnetwork_restpy-1.0.64 18:43:25 snappi_api.info L1132 INFO | Config validation 0.020s 18:43:27 snappi_api.info L1132 INFO | Ports configuration 1.544s 18:43:27 snappi_api.info L1132 INFO | Captures configuration 0.161s 18:43:30 snappi_api.info L1132 INFO | Add location hosts [10.36.78.53] 2.285s 18:43:34 snappi_api.info L1132 INFO | Location hosts ready [10.36.78.53] 4.212s 18:43:35 snappi_api.info L1132 INFO | Speed conversion is not require for (port.name, speed) : [('Port 0', 'novusHundredGigNonFanOut'), ('Port 1', 'novusHundredGigNonFanOut'), ('Port 2', 'novusHundredGigNonFanOut')] 18:43:35 snappi_api.info L1132 INFO | Aggregation mode speed change 0.479s 18:43:42 snappi_api.info L1132 INFO | Location preemption [10.36.78.53;6;1, 10.36.78.53;6;2, 10.36.78.53;6;3] 0.111s 18:44:07 snappi_api.info L1132 INFO | Location connect [Port 0, Port 1, Port 2] 25.066s 18:44:07 snappi_api.warning L1138 WARNING| Port 0 connectedLinkDown 18:44:07 snappi_api.warning L1138 WARNING| Port 1 connectedLinkDown 18:44:07 snappi_api.warning L1138 WARNING| Port 2 connectedLinkDown 18:44:07 snappi_api.info L1132 INFO | Location state check [Port 0, Port 1, Port 2] 0.245s 18:44:07 snappi_api.info L1132 INFO | Location configuration 39.389s 18:44:19 snappi_api.info L1132 INFO | Layer1 configuration 12.161s 18:44:19 snappi_api.info L1132 INFO | Lag Configuration 0.082s 18:44:19 snappi_api.info L1132 INFO | Convert device config : 0.224s 18:44:19 snappi_api.info L1132 INFO | Create IxNetwork device config : 0.000s 18:44:20 snappi_api.info L1132 INFO | Push IxNetwork device config : 0.641s 18:44:20 snappi_api.info L1132 INFO | Devices configuration 0.940s 18:44:25 snappi_api.info L1132 INFO | Flows configuration 5.128s 18:45:25 snappi_api.info L1132 INFO | Start interfaces 59.556s 18:45:25 snappi_api.info L1132 INFO | IxNet - The Traffic Item was modified. Please perform a Traffic Generate to update the associated traffic Flow Groups 18:45:30 traffic_generation.run_traffic L0322 INFO | Wait for Arp to Resolve ... 18:45:36 traffic_generation.run_traffic L0322 INFO | Starting transmit on all flows ... 18:48:41 snappi_api.info L1132 INFO | Flows generate/apply 184.474s 18:48:54 snappi_api.info L1132 INFO | Flows clear statistics 12.396s 18:48:54 snappi_api.info L1132 INFO | Captures start 0.000s 18:49:17 snappi_api.info L1132 INFO | Flows start 22.926s 18:49:17 traffic_generation.run_traffic L0322 INFO | Polling DUT for traffic statistics for 15 seconds ... 18:49:23 traffic_generation.run_traffic L0322 INFO | Polling TGEN for in-flight traffic statistics... 18:49:25 traffic_generation.run_traffic L0322 INFO | In-flight traffic statistics for flows: ['Test Flow 1 -> 0', 'Test Flow 2 -> 0', 'Background Flow 1 -> 0', 'Background Flow 2 -> 0'] 18:49:25 traffic_generation.run_traffic L0322 INFO | In-flight TX frames: [6312174, 6312175, 6310775, 6310775] 18:49:25 traffic_generation.run_traffic L0322 INFO | In-flight RX frames: [6311444, 6311444, 6310765, 6310766] 18:49:29 traffic_generation.run_traffic L0322 INFO | DUT polling complete 18:49:29 traffic_generation.run_traffic L0322 INFO | Checking if all flows have stopped. Attempt #1 18:49:30 traffic_generation.run_traffic L0322 INFO | ['started', 'started', 'started', 'started'] 18:49:31 traffic_generation.run_traffic L0322 INFO | Checking if all flows have stopped. Attempt #2 18:49:32 traffic_generation.run_traffic L0322 INFO | ['started', 'started', 'started', 'started'] 18:49:33 traffic_generation.run_traffic L0322 INFO | Checking if all flows have stopped. Attempt #3 18:49:35 traffic_generation.run_traffic L0322 INFO | ['started', 'started', 'stopped', 'stopped'] 18:49:36 traffic_generation.run_traffic L0322 INFO | Checking if all flows have stopped. Attempt #4 18:49:37 traffic_generation.run_traffic L0322 INFO | ['stopped', 'stopped', 'stopped', 'stopped'] 18:49:37 traffic_generation.run_traffic L0322 INFO | All test and background traffic flows stopped 18:49:39 traffic_generation.run_traffic L0322 INFO | Dumping per-flow statistics 18:49:40 traffic_generation.run_traffic L0322 INFO | Stopping transmit on all remaining flows 18:49:41 snappi_fixtures.cleanup_config L0952 INFO | Removing Configuration on Dut: sonic-s6100-dut1 with port Ethernet0 with ip :20.1.1.1/24 18:49:43 snappi_fixtures.cleanup_config L0952 INFO | Removing Configuration on Dut: sonic-s6100-dut1 with port Ethernet4 with ip :20.1.2.1/24 18:49:45 snappi_fixtures.cleanup_config L0952 INFO | Removing Configuration on Dut: sonic-s6100-dut1 with port Ethernet8 with ip :20.1.3.1/24 PASSED [100%] ------------------------------------------------------------ live log teardown ------------------------------------------------------------- 18:49:47 init.pytest_runtest_teardown L0049 INFO | collect memory after test test_m2o_oversubscribe_lossless[multidut_port_info0] 18:49:48 init.pytest_runtest_teardown L0072 INFO | After test: collected memory_values {'before_test': {'sonic-s6100-dut1': {'monit': {'memory_usage': 13.9}}}, 'after_test': {'sonic-s6100-dut1': {'monit': {'memory_usage': 31.3}}}} 18:49:48 init._fixture_generator_decorator L0093 INFO | -------------------- fixture snappi_api teardown starts -------------------- 18:50:03 init._fixture_generator_decorator L0102 INFO | -------------------- fixture snappi_api teardown ends -------------------- 18:50:03 init._fixture_generator_decorator L0093 INFO | -------------------- fixture start_pfcwd_after_test teardown starts -------------------- 18:50:05 init._fixture_generator_decorator L0102 INFO | -------------------- fixture start_pfcwd_after_test teardown ends -------------------- 18:50:05 init._fixture_generator_decorator L0093 INFO | -------------------- fixture rand_lossy_prio teardown starts -------------------- 18:50:05 init._fixture_generator_decorator L0102 INFO | -------------------- fixture rand_lossy_prio teardown ends -------------------- 18:50:05 init._fixture_generator_decorator L0093 INFO | -------------------- fixture rand_lossless_prio teardown starts -------------------- 18:50:05 init._fixture_generator_decorator L0102 INFO | -------------------- fixture rand_lossless_prio teardown ends -------------------- 18:50:05 init._fixture_generator_decorator L0093 INFO | -------------------- fixture enable_packet_aging_after_test teardown starts -------------------- 18:50:05 init._fixture_generator_decorator L0102 INFO | -------------------- fixture enable_packet_aging_after_test teardown ends -------------------- 18:50:05 conftest.core_dump_and_config_check L2203 INFO | Dumping Disk and Memory Space informataion after test on sonic-s6100-dut1 18:50:06 conftest.core_dump_and_config_check L2207 INFO | Collecting core dumps after test on sonic-s6100-dut1 18:50:07 conftest.core_dump_and_config_check L2224 INFO | Collecting running config after test on sonic-s6100-dut1 18:50:08 conftest.core_dump_and_config_check L2352 WARNING| Core dump or config check failed for test_m2o_oversubscribe_lossless.py, results: {"core_dump_check": {"pass": true, "new_core_dumps": {"sonic-s6100-dut1": []}}, "config_db_check": {"pass": false, "pre_only_config": {"sonic-s6100-dut1": {"null": {"INTERFACE": {"Ethernet0": {}, "Ethernet12": {}, "Ethernet4": {}, "Ethernet8": {}, "Ethernet0|21.1.1.1/24": {}, "Ethernet12|24.1.1.1/24": {}, "Ethernet4|22.1.1.1/24": {}, "Ethernet8|23.1.1.1/24": {}}}}}, "cur_only_config": {"sonic-s6100-dut1": {"null": {}}}, "inconsistent_config": {"sonic-s6100-dut1": {"null": {"PFC_WD": {"pre_value": {"GLOBAL": {"POLL_INTERVAL": "200"}}, "cur_value": {"Ethernet0": {"action": "drop", "detection_time": "200", "restoration_time": "200"}, "Ethernet12": {"action": "drop", "detection_time": "200", "restoration_time": "200"}, "Ethernet4": {"action": "drop", "detection_time": "200", "restoration_time": "200"}, "Ethernet8": {"action": "drop", "detection_time": "200", "restoration_time": "200"}, "GLOBAL": {"POLL_INTERVAL": "200"}}}}}}}} 18:50:08 conftest.__dut_reload L2091 INFO | dut reload called on sonic-s6100-dut1 18:50:10 parallel.on_terminate L0085 INFO | process __dut_reload-- terminated with exit code None 18:50:10 parallel.parallel_run L0221 INFO | Completed running processes for target "__dut_reload" in 0:00:01.443244 seconds 18:50:10 conftest.core_dump_and_config_check L2362 INFO | -----$$$$$$$$$$--------------- Executing config reload of config_db_bgp.json -------------$$$$$$$$$$$$$$ ============================================================= warnings summary ============================================================= ../../../../usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755 /usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755: PytestAssertRewriteWarning: Module already imported so cannot be rewritten: tests.common.plugins.loganalyzer self.import_plugin(import_spec) ../../../../usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755 /usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755: PytestAssertRewriteWarning: Module already imported so cannot be rewritten: tests.common.plugins.sanity_check self.import_plugin(import_spec) ../../../../usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755 /usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755: PytestAssertRewriteWarning: Module already imported so cannot be rewritten: tests.common.plugins.test_completeness self.import_plugin(import_spec) ../../../../usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755 /usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755: PytestAssertRewriteWarning: Module already imported so cannot be rewritten: tests.common.dualtor self.import_plugin(import_spec) ../../../../usr/local/lib/python3.8/dist-packages/paramiko/transport.py:236 /usr/local/lib/python3.8/dist-packages/paramiko/transport.py:236: CryptographyDeprecationWarning: Blowfish has been deprecated "class": algorithms.Blowfish, snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] /usr/local/lib/python3.8/dist-packages/pytest_ansible/module_dispatcher/v213.py:100: UserWarning: provided hosts list is empty, only localhost is available warnings.warn("provided hosts list is empty, only localhost is available") snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] /var/AzDevOps/.local/lib/python3.8/site-packages/snappi_ixnetwork/device/utils.py:2: DeprecationWarning: Using or importing the ABCs from 'collections' instead of from 'collections.abc' is deprecated since Python 3.3, and in 3.10 it will stop working from collections import namedtuple, Mapping snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] /usr/local/lib/python3.8/dist-packages/ixnetwork_restpy/testplatform/sessions/sessions.py:59: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead. elif LooseVersion(build_number) < LooseVersion('8.52'): -- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html ---------------------------------------------------------- live log sessionfinish ---------------------------------------------------------- 18:50:41 init.pytest_terminal_summary L0067 INFO | Can not get Allure report URL. Please check logs ================================================ 1 passed, 13 warnings in 473.16s (0:07:53) ================================================ co-authorized by: [email protected]
…onic-net#14416) Description of PR Summary: Adding dut counter verification for PFC Oversubscription cases Fixes # (issue) sonic-net#13596 Approach Dependency sonic-net#13848 What is the motivation for this PR? Verifies the packet drops from the dut interface counters How did you do it? How did you verify/test it? Any platform specific information? Supported testbed topology if it's a new test case? Documentation Output 18:43:03 test_m2o_oversubscribe_lossless.test_m2o L0077 INFO | Running test for testbed subtype: single-dut-single-asic 18:43:03 snappi_fixtures.__intf_config_multidut L0796 INFO | Configuring Dut: sonic-s6100-dut1 with port Ethernet0 with IP 20.1.1.1/24 18:43:05 snappi_fixtures.__intf_config_multidut L0796 INFO | Configuring Dut: sonic-s6100-dut1 with port Ethernet4 with IP 20.1.2.1/24 18:43:07 snappi_fixtures.__intf_config_multidut L0796 INFO | Configuring Dut: sonic-s6100-dut1 with port Ethernet8 with IP 20.1.3.1/24 18:43:10 connection._warn L0246 WARNING| Verification of certificates is disabled 18:43:10 connection._info L0243 INFO | Determining the platform and rest_port using the 10.36.78.59 address... 18:43:10 connection._warn L0246 WARNING| Unable to connect to http://10.36.78.59:443. 18:43:10 connection._info L0243 INFO | Connection established to https://10.36.78.59:443 on linux 18:43:24 connection._info L0243 INFO | Using IxNetwork api server version 10.20.2403.2 18:43:24 connection._info L0243 INFO | User info IxNetwork/ixnetworkweb/admin-68-20480 18:43:25 snappi_api.info L1132 INFO | snappi-0.9.1 18:43:25 snappi_api.info L1132 INFO | snappi_ixnetwork-0.8.2 18:43:25 snappi_api.info L1132 INFO | ixnetwork_restpy-1.0.64 18:43:25 snappi_api.info L1132 INFO | Config validation 0.020s 18:43:27 snappi_api.info L1132 INFO | Ports configuration 1.544s 18:43:27 snappi_api.info L1132 INFO | Captures configuration 0.161s 18:43:30 snappi_api.info L1132 INFO | Add location hosts [10.36.78.53] 2.285s 18:43:34 snappi_api.info L1132 INFO | Location hosts ready [10.36.78.53] 4.212s 18:43:35 snappi_api.info L1132 INFO | Speed conversion is not require for (port.name, speed) : [('Port 0', 'novusHundredGigNonFanOut'), ('Port 1', 'novusHundredGigNonFanOut'), ('Port 2', 'novusHundredGigNonFanOut')] 18:43:35 snappi_api.info L1132 INFO | Aggregation mode speed change 0.479s 18:43:42 snappi_api.info L1132 INFO | Location preemption [10.36.78.53;6;1, 10.36.78.53;6;2, 10.36.78.53;6;3] 0.111s 18:44:07 snappi_api.info L1132 INFO | Location connect [Port 0, Port 1, Port 2] 25.066s 18:44:07 snappi_api.warning L1138 WARNING| Port 0 connectedLinkDown 18:44:07 snappi_api.warning L1138 WARNING| Port 1 connectedLinkDown 18:44:07 snappi_api.warning L1138 WARNING| Port 2 connectedLinkDown 18:44:07 snappi_api.info L1132 INFO | Location state check [Port 0, Port 1, Port 2] 0.245s 18:44:07 snappi_api.info L1132 INFO | Location configuration 39.389s 18:44:19 snappi_api.info L1132 INFO | Layer1 configuration 12.161s 18:44:19 snappi_api.info L1132 INFO | Lag Configuration 0.082s 18:44:19 snappi_api.info L1132 INFO | Convert device config : 0.224s 18:44:19 snappi_api.info L1132 INFO | Create IxNetwork device config : 0.000s 18:44:20 snappi_api.info L1132 INFO | Push IxNetwork device config : 0.641s 18:44:20 snappi_api.info L1132 INFO | Devices configuration 0.940s 18:44:25 snappi_api.info L1132 INFO | Flows configuration 5.128s 18:45:25 snappi_api.info L1132 INFO | Start interfaces 59.556s 18:45:25 snappi_api.info L1132 INFO | IxNet - The Traffic Item was modified. Please perform a Traffic Generate to update the associated traffic Flow Groups 18:45:30 traffic_generation.run_traffic L0322 INFO | Wait for Arp to Resolve ... 18:45:36 traffic_generation.run_traffic L0322 INFO | Starting transmit on all flows ... 18:48:41 snappi_api.info L1132 INFO | Flows generate/apply 184.474s 18:48:54 snappi_api.info L1132 INFO | Flows clear statistics 12.396s 18:48:54 snappi_api.info L1132 INFO | Captures start 0.000s 18:49:17 snappi_api.info L1132 INFO | Flows start 22.926s 18:49:17 traffic_generation.run_traffic L0322 INFO | Polling DUT for traffic statistics for 15 seconds ... 18:49:23 traffic_generation.run_traffic L0322 INFO | Polling TGEN for in-flight traffic statistics... 18:49:25 traffic_generation.run_traffic L0322 INFO | In-flight traffic statistics for flows: ['Test Flow 1 -> 0', 'Test Flow 2 -> 0', 'Background Flow 1 -> 0', 'Background Flow 2 -> 0'] 18:49:25 traffic_generation.run_traffic L0322 INFO | In-flight TX frames: [6312174, 6312175, 6310775, 6310775] 18:49:25 traffic_generation.run_traffic L0322 INFO | In-flight RX frames: [6311444, 6311444, 6310765, 6310766] 18:49:29 traffic_generation.run_traffic L0322 INFO | DUT polling complete 18:49:29 traffic_generation.run_traffic L0322 INFO | Checking if all flows have stopped. Attempt sonic-net#1 18:49:30 traffic_generation.run_traffic L0322 INFO | ['started', 'started', 'started', 'started'] 18:49:31 traffic_generation.run_traffic L0322 INFO | Checking if all flows have stopped. Attempt sonic-net#2 18:49:32 traffic_generation.run_traffic L0322 INFO | ['started', 'started', 'started', 'started'] 18:49:33 traffic_generation.run_traffic L0322 INFO | Checking if all flows have stopped. Attempt sonic-net#3 18:49:35 traffic_generation.run_traffic L0322 INFO | ['started', 'started', 'stopped', 'stopped'] 18:49:36 traffic_generation.run_traffic L0322 INFO | Checking if all flows have stopped. Attempt sonic-net#4 18:49:37 traffic_generation.run_traffic L0322 INFO | ['stopped', 'stopped', 'stopped', 'stopped'] 18:49:37 traffic_generation.run_traffic L0322 INFO | All test and background traffic flows stopped 18:49:39 traffic_generation.run_traffic L0322 INFO | Dumping per-flow statistics 18:49:40 traffic_generation.run_traffic L0322 INFO | Stopping transmit on all remaining flows 18:49:41 snappi_fixtures.cleanup_config L0952 INFO | Removing Configuration on Dut: sonic-s6100-dut1 with port Ethernet0 with ip :20.1.1.1/24 18:49:43 snappi_fixtures.cleanup_config L0952 INFO | Removing Configuration on Dut: sonic-s6100-dut1 with port Ethernet4 with ip :20.1.2.1/24 18:49:45 snappi_fixtures.cleanup_config L0952 INFO | Removing Configuration on Dut: sonic-s6100-dut1 with port Ethernet8 with ip :20.1.3.1/24 PASSED [100%] ------------------------------------------------------------ live log teardown ------------------------------------------------------------- 18:49:47 init.pytest_runtest_teardown L0049 INFO | collect memory after test test_m2o_oversubscribe_lossless[multidut_port_info0] 18:49:48 init.pytest_runtest_teardown L0072 INFO | After test: collected memory_values {'before_test': {'sonic-s6100-dut1': {'monit': {'memory_usage': 13.9}}}, 'after_test': {'sonic-s6100-dut1': {'monit': {'memory_usage': 31.3}}}} 18:49:48 init._fixture_generator_decorator L0093 INFO | -------------------- fixture snappi_api teardown starts -------------------- 18:50:03 init._fixture_generator_decorator L0102 INFO | -------------------- fixture snappi_api teardown ends -------------------- 18:50:03 init._fixture_generator_decorator L0093 INFO | -------------------- fixture start_pfcwd_after_test teardown starts -------------------- 18:50:05 init._fixture_generator_decorator L0102 INFO | -------------------- fixture start_pfcwd_after_test teardown ends -------------------- 18:50:05 init._fixture_generator_decorator L0093 INFO | -------------------- fixture rand_lossy_prio teardown starts -------------------- 18:50:05 init._fixture_generator_decorator L0102 INFO | -------------------- fixture rand_lossy_prio teardown ends -------------------- 18:50:05 init._fixture_generator_decorator L0093 INFO | -------------------- fixture rand_lossless_prio teardown starts -------------------- 18:50:05 init._fixture_generator_decorator L0102 INFO | -------------------- fixture rand_lossless_prio teardown ends -------------------- 18:50:05 init._fixture_generator_decorator L0093 INFO | -------------------- fixture enable_packet_aging_after_test teardown starts -------------------- 18:50:05 init._fixture_generator_decorator L0102 INFO | -------------------- fixture enable_packet_aging_after_test teardown ends -------------------- 18:50:05 conftest.core_dump_and_config_check L2203 INFO | Dumping Disk and Memory Space informataion after test on sonic-s6100-dut1 18:50:06 conftest.core_dump_and_config_check L2207 INFO | Collecting core dumps after test on sonic-s6100-dut1 18:50:07 conftest.core_dump_and_config_check L2224 INFO | Collecting running config after test on sonic-s6100-dut1 18:50:08 conftest.core_dump_and_config_check L2352 WARNING| Core dump or config check failed for test_m2o_oversubscribe_lossless.py, results: {"core_dump_check": {"pass": true, "new_core_dumps": {"sonic-s6100-dut1": []}}, "config_db_check": {"pass": false, "pre_only_config": {"sonic-s6100-dut1": {"null": {"INTERFACE": {"Ethernet0": {}, "Ethernet12": {}, "Ethernet4": {}, "Ethernet8": {}, "Ethernet0|21.1.1.1/24": {}, "Ethernet12|24.1.1.1/24": {}, "Ethernet4|22.1.1.1/24": {}, "Ethernet8|23.1.1.1/24": {}}}}}, "cur_only_config": {"sonic-s6100-dut1": {"null": {}}}, "inconsistent_config": {"sonic-s6100-dut1": {"null": {"PFC_WD": {"pre_value": {"GLOBAL": {"POLL_INTERVAL": "200"}}, "cur_value": {"Ethernet0": {"action": "drop", "detection_time": "200", "restoration_time": "200"}, "Ethernet12": {"action": "drop", "detection_time": "200", "restoration_time": "200"}, "Ethernet4": {"action": "drop", "detection_time": "200", "restoration_time": "200"}, "Ethernet8": {"action": "drop", "detection_time": "200", "restoration_time": "200"}, "GLOBAL": {"POLL_INTERVAL": "200"}}}}}}}} 18:50:08 conftest.__dut_reload L2091 INFO | dut reload called on sonic-s6100-dut1 18:50:10 parallel.on_terminate L0085 INFO | process __dut_reload-- terminated with exit code None 18:50:10 parallel.parallel_run L0221 INFO | Completed running processes for target "__dut_reload" in 0:00:01.443244 seconds 18:50:10 conftest.core_dump_and_config_check L2362 INFO | -----$$$$$$$$$$--------------- Executing config reload of config_db_bgp.json -------------$$$$$$$$$$$$$$ ============================================================= warnings summary ============================================================= ../../../../usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755 /usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755: PytestAssertRewriteWarning: Module already imported so cannot be rewritten: tests.common.plugins.loganalyzer self.import_plugin(import_spec) ../../../../usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755 /usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755: PytestAssertRewriteWarning: Module already imported so cannot be rewritten: tests.common.plugins.sanity_check self.import_plugin(import_spec) ../../../../usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755 /usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755: PytestAssertRewriteWarning: Module already imported so cannot be rewritten: tests.common.plugins.test_completeness self.import_plugin(import_spec) ../../../../usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755 /usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755: PytestAssertRewriteWarning: Module already imported so cannot be rewritten: tests.common.dualtor self.import_plugin(import_spec) ../../../../usr/local/lib/python3.8/dist-packages/paramiko/transport.py:236 /usr/local/lib/python3.8/dist-packages/paramiko/transport.py:236: CryptographyDeprecationWarning: Blowfish has been deprecated "class": algorithms.Blowfish, snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] /usr/local/lib/python3.8/dist-packages/pytest_ansible/module_dispatcher/v213.py:100: UserWarning: provided hosts list is empty, only localhost is available warnings.warn("provided hosts list is empty, only localhost is available") snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] /var/AzDevOps/.local/lib/python3.8/site-packages/snappi_ixnetwork/device/utils.py:2: DeprecationWarning: Using or importing the ABCs from 'collections' instead of from 'collections.abc' is deprecated since Python 3.3, and in 3.10 it will stop working from collections import namedtuple, Mapping snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] /usr/local/lib/python3.8/dist-packages/ixnetwork_restpy/testplatform/sessions/sessions.py:59: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead. elif LooseVersion(build_number) < LooseVersion('8.52'): -- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html ---------------------------------------------------------- live log sessionfinish ---------------------------------------------------------- 18:50:41 init.pytest_terminal_summary L0067 INFO | Can not get Allure report URL. Please check logs ================================================ 1 passed, 13 warnings in 473.16s (0:07:53) ================================================ co-authorized by: [email protected]
…s, and Queue counters. (sonic-net#13848) Description of PR Support to pull the DUT statistics, namely interface counters, PFC counters and Queue counters. This support will enable users to pull the DUT statistics run-time and capture them in form of dictionary for further processing. Summary: Fixes # (issue) sonic-net#13843 Approach What is the motivation for this PR? Currently, there is no one stop-place to fetch the DUT statistics and use them for verification, especially the SNAPPI testcases. There should be some way to pull the DUT statistics ( at least important ones) and use them for verification. How did you do it? Clear counters: Common function to clear interface, PFC and queue counter stats. Interface counters: Ability to fetch the interface counters for a given DUT and port. Returns dictionary with keys - Rx and Tx packet count, Rx and Tx failures (Error + drops + ovr), and Rx and Tx throughput in Mbps. PFC counters: Ability to fetch the PFC counters for a given DUT and port. Returns dictionary with keys - Rx and Tx PFC for the given DUT, port and priority. Queue counters: Ability to fetch the Queue counters for a given DUT and port. Internally calls get_egress_queue_count for all the priorities. Returns dictionary with as key with transmitted packets as counter. How did you verify/test it? These functions are called as part of new testcases for PFC-ECN. for dut, port in dutport_list: f_stats = update_dict(m, f_stats, interface_stats(dut, port)) f_stats = update_dict(m, f_stats, get_pfc_count(dut, port)) f_stats = update_dict(m, f_stats, get_queue_count(dut, port)) These are then used to create CSV with raw DUT statistics and then to summarize the test in the end. co-authorized by: [email protected]
…onic-net#14416) Description of PR Summary: Adding dut counter verification for PFC Oversubscription cases Fixes # (issue) sonic-net#13596 Approach Dependency sonic-net#13848 What is the motivation for this PR? Verifies the packet drops from the dut interface counters How did you do it? How did you verify/test it? Any platform specific information? Supported testbed topology if it's a new test case? Documentation Output 18:43:03 test_m2o_oversubscribe_lossless.test_m2o L0077 INFO | Running test for testbed subtype: single-dut-single-asic 18:43:03 snappi_fixtures.__intf_config_multidut L0796 INFO | Configuring Dut: sonic-s6100-dut1 with port Ethernet0 with IP 20.1.1.1/24 18:43:05 snappi_fixtures.__intf_config_multidut L0796 INFO | Configuring Dut: sonic-s6100-dut1 with port Ethernet4 with IP 20.1.2.1/24 18:43:07 snappi_fixtures.__intf_config_multidut L0796 INFO | Configuring Dut: sonic-s6100-dut1 with port Ethernet8 with IP 20.1.3.1/24 18:43:10 connection._warn L0246 WARNING| Verification of certificates is disabled 18:43:10 connection._info L0243 INFO | Determining the platform and rest_port using the 10.36.78.59 address... 18:43:10 connection._warn L0246 WARNING| Unable to connect to http://10.36.78.59:443. 18:43:10 connection._info L0243 INFO | Connection established to https://10.36.78.59:443 on linux 18:43:24 connection._info L0243 INFO | Using IxNetwork api server version 10.20.2403.2 18:43:24 connection._info L0243 INFO | User info IxNetwork/ixnetworkweb/admin-68-20480 18:43:25 snappi_api.info L1132 INFO | snappi-0.9.1 18:43:25 snappi_api.info L1132 INFO | snappi_ixnetwork-0.8.2 18:43:25 snappi_api.info L1132 INFO | ixnetwork_restpy-1.0.64 18:43:25 snappi_api.info L1132 INFO | Config validation 0.020s 18:43:27 snappi_api.info L1132 INFO | Ports configuration 1.544s 18:43:27 snappi_api.info L1132 INFO | Captures configuration 0.161s 18:43:30 snappi_api.info L1132 INFO | Add location hosts [10.36.78.53] 2.285s 18:43:34 snappi_api.info L1132 INFO | Location hosts ready [10.36.78.53] 4.212s 18:43:35 snappi_api.info L1132 INFO | Speed conversion is not require for (port.name, speed) : [('Port 0', 'novusHundredGigNonFanOut'), ('Port 1', 'novusHundredGigNonFanOut'), ('Port 2', 'novusHundredGigNonFanOut')] 18:43:35 snappi_api.info L1132 INFO | Aggregation mode speed change 0.479s 18:43:42 snappi_api.info L1132 INFO | Location preemption [10.36.78.53;6;1, 10.36.78.53;6;2, 10.36.78.53;6;3] 0.111s 18:44:07 snappi_api.info L1132 INFO | Location connect [Port 0, Port 1, Port 2] 25.066s 18:44:07 snappi_api.warning L1138 WARNING| Port 0 connectedLinkDown 18:44:07 snappi_api.warning L1138 WARNING| Port 1 connectedLinkDown 18:44:07 snappi_api.warning L1138 WARNING| Port 2 connectedLinkDown 18:44:07 snappi_api.info L1132 INFO | Location state check [Port 0, Port 1, Port 2] 0.245s 18:44:07 snappi_api.info L1132 INFO | Location configuration 39.389s 18:44:19 snappi_api.info L1132 INFO | Layer1 configuration 12.161s 18:44:19 snappi_api.info L1132 INFO | Lag Configuration 0.082s 18:44:19 snappi_api.info L1132 INFO | Convert device config : 0.224s 18:44:19 snappi_api.info L1132 INFO | Create IxNetwork device config : 0.000s 18:44:20 snappi_api.info L1132 INFO | Push IxNetwork device config : 0.641s 18:44:20 snappi_api.info L1132 INFO | Devices configuration 0.940s 18:44:25 snappi_api.info L1132 INFO | Flows configuration 5.128s 18:45:25 snappi_api.info L1132 INFO | Start interfaces 59.556s 18:45:25 snappi_api.info L1132 INFO | IxNet - The Traffic Item was modified. Please perform a Traffic Generate to update the associated traffic Flow Groups 18:45:30 traffic_generation.run_traffic L0322 INFO | Wait for Arp to Resolve ... 18:45:36 traffic_generation.run_traffic L0322 INFO | Starting transmit on all flows ... 18:48:41 snappi_api.info L1132 INFO | Flows generate/apply 184.474s 18:48:54 snappi_api.info L1132 INFO | Flows clear statistics 12.396s 18:48:54 snappi_api.info L1132 INFO | Captures start 0.000s 18:49:17 snappi_api.info L1132 INFO | Flows start 22.926s 18:49:17 traffic_generation.run_traffic L0322 INFO | Polling DUT for traffic statistics for 15 seconds ... 18:49:23 traffic_generation.run_traffic L0322 INFO | Polling TGEN for in-flight traffic statistics... 18:49:25 traffic_generation.run_traffic L0322 INFO | In-flight traffic statistics for flows: ['Test Flow 1 -> 0', 'Test Flow 2 -> 0', 'Background Flow 1 -> 0', 'Background Flow 2 -> 0'] 18:49:25 traffic_generation.run_traffic L0322 INFO | In-flight TX frames: [6312174, 6312175, 6310775, 6310775] 18:49:25 traffic_generation.run_traffic L0322 INFO | In-flight RX frames: [6311444, 6311444, 6310765, 6310766] 18:49:29 traffic_generation.run_traffic L0322 INFO | DUT polling complete 18:49:29 traffic_generation.run_traffic L0322 INFO | Checking if all flows have stopped. Attempt sonic-net#1 18:49:30 traffic_generation.run_traffic L0322 INFO | ['started', 'started', 'started', 'started'] 18:49:31 traffic_generation.run_traffic L0322 INFO | Checking if all flows have stopped. Attempt sonic-net#2 18:49:32 traffic_generation.run_traffic L0322 INFO | ['started', 'started', 'started', 'started'] 18:49:33 traffic_generation.run_traffic L0322 INFO | Checking if all flows have stopped. Attempt sonic-net#3 18:49:35 traffic_generation.run_traffic L0322 INFO | ['started', 'started', 'stopped', 'stopped'] 18:49:36 traffic_generation.run_traffic L0322 INFO | Checking if all flows have stopped. Attempt sonic-net#4 18:49:37 traffic_generation.run_traffic L0322 INFO | ['stopped', 'stopped', 'stopped', 'stopped'] 18:49:37 traffic_generation.run_traffic L0322 INFO | All test and background traffic flows stopped 18:49:39 traffic_generation.run_traffic L0322 INFO | Dumping per-flow statistics 18:49:40 traffic_generation.run_traffic L0322 INFO | Stopping transmit on all remaining flows 18:49:41 snappi_fixtures.cleanup_config L0952 INFO | Removing Configuration on Dut: sonic-s6100-dut1 with port Ethernet0 with ip :20.1.1.1/24 18:49:43 snappi_fixtures.cleanup_config L0952 INFO | Removing Configuration on Dut: sonic-s6100-dut1 with port Ethernet4 with ip :20.1.2.1/24 18:49:45 snappi_fixtures.cleanup_config L0952 INFO | Removing Configuration on Dut: sonic-s6100-dut1 with port Ethernet8 with ip :20.1.3.1/24 PASSED [100%] ------------------------------------------------------------ live log teardown ------------------------------------------------------------- 18:49:47 init.pytest_runtest_teardown L0049 INFO | collect memory after test test_m2o_oversubscribe_lossless[multidut_port_info0] 18:49:48 init.pytest_runtest_teardown L0072 INFO | After test: collected memory_values {'before_test': {'sonic-s6100-dut1': {'monit': {'memory_usage': 13.9}}}, 'after_test': {'sonic-s6100-dut1': {'monit': {'memory_usage': 31.3}}}} 18:49:48 init._fixture_generator_decorator L0093 INFO | -------------------- fixture snappi_api teardown starts -------------------- 18:50:03 init._fixture_generator_decorator L0102 INFO | -------------------- fixture snappi_api teardown ends -------------------- 18:50:03 init._fixture_generator_decorator L0093 INFO | -------------------- fixture start_pfcwd_after_test teardown starts -------------------- 18:50:05 init._fixture_generator_decorator L0102 INFO | -------------------- fixture start_pfcwd_after_test teardown ends -------------------- 18:50:05 init._fixture_generator_decorator L0093 INFO | -------------------- fixture rand_lossy_prio teardown starts -------------------- 18:50:05 init._fixture_generator_decorator L0102 INFO | -------------------- fixture rand_lossy_prio teardown ends -------------------- 18:50:05 init._fixture_generator_decorator L0093 INFO | -------------------- fixture rand_lossless_prio teardown starts -------------------- 18:50:05 init._fixture_generator_decorator L0102 INFO | -------------------- fixture rand_lossless_prio teardown ends -------------------- 18:50:05 init._fixture_generator_decorator L0093 INFO | -------------------- fixture enable_packet_aging_after_test teardown starts -------------------- 18:50:05 init._fixture_generator_decorator L0102 INFO | -------------------- fixture enable_packet_aging_after_test teardown ends -------------------- 18:50:05 conftest.core_dump_and_config_check L2203 INFO | Dumping Disk and Memory Space informataion after test on sonic-s6100-dut1 18:50:06 conftest.core_dump_and_config_check L2207 INFO | Collecting core dumps after test on sonic-s6100-dut1 18:50:07 conftest.core_dump_and_config_check L2224 INFO | Collecting running config after test on sonic-s6100-dut1 18:50:08 conftest.core_dump_and_config_check L2352 WARNING| Core dump or config check failed for test_m2o_oversubscribe_lossless.py, results: {"core_dump_check": {"pass": true, "new_core_dumps": {"sonic-s6100-dut1": []}}, "config_db_check": {"pass": false, "pre_only_config": {"sonic-s6100-dut1": {"null": {"INTERFACE": {"Ethernet0": {}, "Ethernet12": {}, "Ethernet4": {}, "Ethernet8": {}, "Ethernet0|21.1.1.1/24": {}, "Ethernet12|24.1.1.1/24": {}, "Ethernet4|22.1.1.1/24": {}, "Ethernet8|23.1.1.1/24": {}}}}}, "cur_only_config": {"sonic-s6100-dut1": {"null": {}}}, "inconsistent_config": {"sonic-s6100-dut1": {"null": {"PFC_WD": {"pre_value": {"GLOBAL": {"POLL_INTERVAL": "200"}}, "cur_value": {"Ethernet0": {"action": "drop", "detection_time": "200", "restoration_time": "200"}, "Ethernet12": {"action": "drop", "detection_time": "200", "restoration_time": "200"}, "Ethernet4": {"action": "drop", "detection_time": "200", "restoration_time": "200"}, "Ethernet8": {"action": "drop", "detection_time": "200", "restoration_time": "200"}, "GLOBAL": {"POLL_INTERVAL": "200"}}}}}}}} 18:50:08 conftest.__dut_reload L2091 INFO | dut reload called on sonic-s6100-dut1 18:50:10 parallel.on_terminate L0085 INFO | process __dut_reload-- terminated with exit code None 18:50:10 parallel.parallel_run L0221 INFO | Completed running processes for target "__dut_reload" in 0:00:01.443244 seconds 18:50:10 conftest.core_dump_and_config_check L2362 INFO | -----$$$$$$$$$$--------------- Executing config reload of config_db_bgp.json -------------$$$$$$$$$$$$$$ ============================================================= warnings summary ============================================================= ../../../../usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755 /usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755: PytestAssertRewriteWarning: Module already imported so cannot be rewritten: tests.common.plugins.loganalyzer self.import_plugin(import_spec) ../../../../usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755 /usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755: PytestAssertRewriteWarning: Module already imported so cannot be rewritten: tests.common.plugins.sanity_check self.import_plugin(import_spec) ../../../../usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755 /usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755: PytestAssertRewriteWarning: Module already imported so cannot be rewritten: tests.common.plugins.test_completeness self.import_plugin(import_spec) ../../../../usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755 /usr/local/lib/python3.8/dist-packages/_pytest/config/init.py:755: PytestAssertRewriteWarning: Module already imported so cannot be rewritten: tests.common.dualtor self.import_plugin(import_spec) ../../../../usr/local/lib/python3.8/dist-packages/paramiko/transport.py:236 /usr/local/lib/python3.8/dist-packages/paramiko/transport.py:236: CryptographyDeprecationWarning: Blowfish has been deprecated "class": algorithms.Blowfish, snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] /usr/local/lib/python3.8/dist-packages/pytest_ansible/module_dispatcher/v213.py:100: UserWarning: provided hosts list is empty, only localhost is available warnings.warn("provided hosts list is empty, only localhost is available") snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] /var/AzDevOps/.local/lib/python3.8/site-packages/snappi_ixnetwork/device/utils.py:2: DeprecationWarning: Using or importing the ABCs from 'collections' instead of from 'collections.abc' is deprecated since Python 3.3, and in 3.10 it will stop working from collections import namedtuple, Mapping snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] snappi_tests/multidut/pfc/test_m2o_oversubscribe_lossless.py::test_m2o_oversubscribe_lossless[multidut_port_info0] /usr/local/lib/python3.8/dist-packages/ixnetwork_restpy/testplatform/sessions/sessions.py:59: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead. elif LooseVersion(build_number) < LooseVersion('8.52'): -- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html ---------------------------------------------------------- live log sessionfinish ---------------------------------------------------------- 18:50:41 init.pytest_terminal_summary L0067 INFO | Can not get Allure report URL. Please check logs ================================================ 1 passed, 13 warnings in 473.16s (0:07:53) ================================================ co-authorized by: [email protected]
Description of PR
Support to pull the DUT statistics, namely interface counters, PFC counters and Queue counters.
This support will enable users to pull the DUT statistics run-time and capture them in form of dictionary for further processing.
Summary:
Fixes # (issue)
#13843
Type of change
Back port request
Approach
What is the motivation for this PR?
Currently, there is no one stop-place to fetch the DUT statistics and use them for verification, especially the SNAPPI testcases. There should be some way to pull the DUT statistics ( at least important ones) and use them for verification.
How did you do it?
Clear counters:
Common function to clear interface, PFC and queue counter stats.
Interface counters:
Ability to fetch the interface counters for a given DUT and port. Returns dictionary with keys - Rx and Tx packet count, Rx and Tx failures (Error + drops + ovr), and Rx and Tx throughput in Mbps.
PFC counters:
Ability to fetch the PFC counters for a given DUT and port. Returns dictionary with keys - Rx and Tx PFC for the given DUT, port and priority.
Queue counters:
Ability to fetch the Queue counters for a given DUT and port. Internally calls get_egress_queue_count for all the priorities. Returns dictionary with as key with transmitted packets as counter.
How did you verify/test it?
These functions are called as part of new testcases for PFC-ECN.
These are then used to create CSV with raw DUT statistics and then to summarize the test in the end.
Any platform specific information?
Supported testbed topology if it's a new test case?
Documentation