Updated test_po_cleanup.py for multi-asic platforms.#3069
Merged
abdosi merged 10 commits intosonic-net:masterfrom Mar 10, 2021
Merged
Updated test_po_cleanup.py for multi-asic platforms.#3069abdosi merged 10 commits intosonic-net:masterfrom
abdosi merged 10 commits intosonic-net:masterfrom
Conversation
Signed-off-by: Abhishek Dosi <[email protected]>
Signed-off-by: Abhishek Dosi <[email protected]>
Signed-off-by: Abhishek Dosi <[email protected]>
Signed-off-by: Abhishek Dosi <[email protected]>
smaheshm
reviewed
Mar 4, 2021
Signed-off-by: Abhishek Dosi <[email protected]>
smaheshm
reviewed
Mar 4, 2021
Signed-off-by: Abhishek Dosi <[email protected]>
smaheshm
reviewed
Mar 9, 2021
| def check_kernel_po_interface_cleaned(duthost, asic_index): | ||
| namespace = duthost.get_namespace_from_asic_id(asic_index) | ||
| res = duthost.shell(duthost.get_linux_ip_cmd_for_namespace("ip link show | grep -c PortChannel", namespace),module_ignore_errors=True)["stdout_lines"][0].decode("utf-8") | ||
| return res == '0' |
Contributor
There was a problem hiding this comment.
This is fine but would be good to generalize by overriding "shell" (similar to command) in sonic_asic.py and use something like the following. Up to you.
duthost.asic_instance(enum_asic_index).shell(ip link show | grep -c PortChannel", module_ignore_errors=True)
smaheshm
approved these changes
Mar 9, 2021
Contributor
smaheshm
left a comment
There was a problem hiding this comment.
Just wait for tests to pass.
judyjoseph
reviewed
Mar 9, 2021
tests/pc/test_po_cleanup.py
Outdated
| duthost = duthosts[rand_one_dut_hostname] | ||
| mg_facts = duthost.get_extended_minigraph_facts(tbinfo) | ||
|
|
||
| if len(mg_facts['minigraph_portchannels'].keys()) == 0: |
Contributor
There was a problem hiding this comment.
We would need to check this per namespace/asic_index now ? as the test_po_cleanup is run per asic
Contributor
Author
There was a problem hiding this comment.
@judyjoseph updated.
Will still check only once and not per asic and for multi-asic it will always run as backend is always port-channel.
Signed-off-by: Abhishek Dosi <[email protected]>
Contributor
Author
|
/Azurepipelines run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
Contributor
Author
|
/Azurepipelines run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
judyjoseph
approved these changes
Mar 10, 2021
kazinator-arista
pushed a commit
to kazinator-arista/sonic-mgmt
that referenced
this pull request
Mar 4, 2026
…atically (sonic-net#17757) #### Why I did it src/sonic-utilities ``` * 651a80b1 - (HEAD -> 202305, origin/202305) Modify teamd retry count script to base BGP status on default BGP status (sonic-net#3069) (22 hours ago) [Saikrishna Arcot] ``` #### How I did it #### How to verify it #### Description for the changelog
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What/Why I did:
test_po_cleanup.pyfor multi-asic platforms./tmp/syslogwhich is resulting VS test failure. This does not happen consistently and will need further debug. With this change/tmp/syslogsize reduce from Mb to KbHow I did:
Run the test case on all the asic's.
How I verify:
Verified on both single and multi-asic platforms.