sonic-net / sonic-mgmt

Configuration management examples for SONiC
Other
176 stars 700 forks source link

[Bug]: snappi_tests/multi_dut: Skip PFC check for lossy priority for cisco-8000 #13800

Open rraghav-cisco opened 1 month ago

rraghav-cisco commented 1 month ago

Issue Description

When running snappi_tests/multidut/pfc/test_multidut_pfc_pause_lossy_with_snappi.py::test_pfc_pause_multi_lossy_prio_reboot[linecard_configuration_set0-chassis_single_line_card_multi_asic-cold], we see this error:

                else:
>                   pytest_assert(pfc_pause_rx_frames > 0,
                                  "PFC pause frames should be received and counted in RX PFC counters for priority {}"
                                  .format(prio))
E                   Failed: PFC pause frames should be received and counted in RX PFC counters for priority 1

dut_port_config = [{'Ethernet96': [1, 5, 6, 2, 0]}, {'Ethernet0': [1, 5, 6, 2, 0]}]
global_pause = False

But Prio 1 is a lossy priority, and is marked as such in tests/priority/ folder. Pls let me know if something needs to change in variables.py for this:

pfcQueueGroupSize = 4 # can have values 4 or 8 pfcQueueValueDict = {0: 0, 1: 1, 2: 0, 3: 3, 4: 2, 5: 0, 6: 1, 7: 0}

Results you see

Pls see description. Failure of run.

Results you expected to see

TC should pass.

Is it platform specific

generic

Relevant log output

No response

Output of show version

No response

Attach files (if any)

No response

rraghav-cisco commented 1 month ago

@selldinesh , @kamalsahu0001 : for viz.

sdszhang commented 1 month ago

I'm seeing the same behavior in my local testbed. "show pfc counters" stays at 0 if the PFC pause frames are for lossy priorities. However, in this test case, it's expecting the pfc counters to be increasing. Not sure if this behavior is platform specific or not. @kamalsahu0001 can you take a look?

sdszhang commented 1 month ago

The error is observed in T0/T1 testbed since 2024-02-02. Seems due to the changes in https://github.com/sonic-net/sonic-mgmt/pull/11400

sdszhang commented 1 month ago

not sure about the counter behavior in SAI. Will let @rraghav-cisco to work on test cases to suit Cisco first.

sdszhang commented 2 weeks ago

will document it in internal Jira. @rraghav-cisco to work on test cases to suit Cisco.