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

Support for aggregrate VOQ Counters. #3163

Closed
wants to merge 6 commits into from

Conversation

vivekverma-arista
Copy link

@vivekverma-arista vivekverma-arista commented Feb 13, 2024

What I did

Added CLI support for aggregate VOQ counters according to HLD #1578

How I did it

Extended the existing CLI command show queue counters [interface] --voq for the SSI.

How to verify it

Sent traffic destined to egress out of different queues of a interface through multiple ingress interface chosen across FSIs and verified that the command displays the correct aggregate view of the counters when run from the SSI

From FSI-3

admin@nfc404-3:~$ show queue counters "nfc404-3|Asic0|Ethernet4" --voq
                    Port    Voq    Counter/pkts    Counter/bytes    Drop/pkts    Drop/bytes
------------------------  -----  --------------  ---------------  -----------  ------------
nfc404-3|Asic0|Ethernet4   VOQ0              45            12386            0             0
nfc404-3|Asic0|Ethernet4   VOQ1               0                0            0             0
nfc404-3|Asic0|Ethernet4   VOQ2             204            10200            0             0
nfc404-3|Asic0|Ethernet4   VOQ3               0                0            0             0
nfc404-3|Asic0|Ethernet4   VOQ4              21             1050            0             0
nfc404-3|Asic0|Ethernet4   VOQ5               0                0            0             0
nfc404-3|Asic0|Ethernet4   VOQ6              29             1450            0             0
nfc404-3|Asic0|Ethernet4   VOQ7               0                0            0             0

From FSI-8

admin@nfc404-8:~$ show queue counters "nfc404-3|Asic0|Ethernet4" --voq
                    Port    Voq    Counter/pkts    Counter/bytes    Drop/pkts    Drop/bytes
------------------------  -----  --------------  ---------------  -----------  ------------
nfc404-3|Asic0|Ethernet4   VOQ0               0                0            0             0
nfc404-3|Asic0|Ethernet4   VOQ1               1               50            0             0
nfc404-3|Asic0|Ethernet4   VOQ2              51             2550            0             0
nfc404-3|Asic0|Ethernet4   VOQ3               0                0            0             0
nfc404-3|Asic0|Ethernet4   VOQ4              16              800            0             0
nfc404-3|Asic0|Ethernet4   VOQ5               0                0            0             0
nfc404-3|Asic0|Ethernet4   VOQ6             143             7150            0             0
nfc404-3|Asic0|Ethernet4   VOQ7               0                0            0             0
From SSI

admin@nfc404:~$ show queue counters "nfc404-3|Asic0|Ethernet4" --voq
                    Port    Voq    Counter/pkts    Counter/bytes    Drop/pkts    Drop/bytes
------------------------  -----  --------------  ---------------  -----------  ------------
nfc404-3|Asic0|Ethernet4   VOQ0              45            12386            0             0
nfc404-3|Asic0|Ethernet4   VOQ1               1               50            0             0
nfc404-3|Asic0|Ethernet4   VOQ2             255            12750            0             0
nfc404-3|Asic0|Ethernet4   VOQ3               0                0            0             0
nfc404-3|Asic0|Ethernet4   VOQ4              37             1850            0             0
nfc404-3|Asic0|Ethernet4   VOQ5               0                0            0             0
nfc404-3|Asic0|Ethernet4   VOQ6             172             8600            0             0
nfc404-3|Asic0|Ethernet4   VOQ7               0                0            0             0

Previous command output (if the output of a command-line utility has changed)

New command output (if the output of a command-line utility has changed)

admin@nfc404:~$ show queue counters "nfc404-3|Asic0|Ethernet4" --voq
                    Port    Voq    Counter/pkts    Counter/bytes    Drop/pkts    Drop/bytes
------------------------  -----  --------------  ---------------  -----------  ------------
nfc404-3|Asic0|Ethernet4   VOQ0              45            12386            0             0
nfc404-3|Asic0|Ethernet4   VOQ1               1               50            0             0
nfc404-3|Asic0|Ethernet4   VOQ2             255            12750            0             0
nfc404-3|Asic0|Ethernet4   VOQ3               0                0            0             0
nfc404-3|Asic0|Ethernet4   VOQ4              37             1850            0             0
nfc404-3|Asic0|Ethernet4   VOQ5               0                0            0             0
nfc404-3|Asic0|Ethernet4   VOQ6             172             8600            0             0
nfc404-3|Asic0|Ethernet4   VOQ7               0                0            0             0

Should merge after #908, #20057 and #3271

Tracked by #1543

HLD: #1578

@vivekverma-arista vivekverma-arista changed the title Added CLI support for aggregate VOQ counters. Support for aggregrate VOQ Counters. Feb 18, 2024
@rlhui rlhui requested a review from vmittal-msft May 22, 2024 17:13
Copy link
Contributor

@vmittal-msft vmittal-msft left a comment

Choose a reason for hiding this comment

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

  1. Based on my understanding,
  • Sysport is the one where VoQ pointing to and we are aggregating the stats for ?
  • fap id is the source asics where we are getting the count and aggregating for all faps ?
  • idx is the VoQ id 0-7 ? or real VoQ id ?
  1. Do we support "show queue counter --voq" without any interface info ?
  2. Can you please add test case for this ?

vmittal-msft
vmittal-msft previously approved these changes May 24, 2024
@vmittal-msft
Copy link
Contributor

scripts/queuestat Outdated Show resolved Hide resolved
@kenneth-arista
Copy link
Contributor

@ysmanman @jfeng-arista

@kenneth-arista
Copy link
Contributor

@arlakshm

@vivekverma-arista
Copy link
Author

vivekverma-arista commented Aug 29, 2024

  1. Based on my understanding,
  • Sysport is the one where VoQ pointing to and we are aggregating the stats for ?
  • fap id is the source asics where we are getting the count and aggregating for all faps ?
  • idx is the VoQ id 0-7 ? or real VoQ id ?
  1. Do we support "show queue counter --voq" without any interface info ?
  2. Can you please add test case for this ?

Yes the understanding of the key is correct. Refer https://github.com/vivekverma-arista/SONiC/blob/aggVoq/doc/voq/aggregate_voq_counters.md#database-changes for more details.

show queue counter --voq is also supported on SSI and it will aggregate VOQ counters for all interfaces. The command is however not available for FSI as we need to specify asic there -n aiscX

@saksarav-nokia
Copy link
Contributor

When the Line card is reset or goes offlline, are these counters cleared from SUP?.

@vivekverma-arista
Copy link
Author

vivekverma-arista commented Sep 9, 2024

When the Line card is reset or goes offlline, are these counters cleared from SUP?.

We are not doing anything explicit to clear this, but when the LC comes up online, it will overwrite the counters for it's own VOQs so it will happen naturally.

So aggregation on SSI show voq counters --voq will always be consistent with counters presented on FSI show queue counters -n <asic> --voq

swss changes -> sonic-net/sonic-swss#3271

Copy link
Contributor

@vmittal-msft vmittal-msft left a comment

Choose a reason for hiding this comment

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

We are waiting for HLD to be finalized before approving PRs.

@vivekverma-arista
Copy link
Author

New PR raised as approach got changed: #3617

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

4 participants