Skip to content

Skip watchdog reboot for Supervisor in Cisco 8000 distributed chassis#6812

Closed
vperumal wants to merge 1 commit intosonic-net:masterfrom
vperumal:watchdog_reset_sup_skip
Closed

Skip watchdog reboot for Supervisor in Cisco 8000 distributed chassis#6812
vperumal wants to merge 1 commit intosonic-net:masterfrom
vperumal:watchdog_reset_sup_skip

Conversation

@vperumal
Copy link
Collaborator

Description of PR

Temporarily skipping watchdog reboot for Supervisor card in Cisco 8000 distributed chassis. Plan is to add support for it soon.

Summary:
Fixes # (issue)

Type of change

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

Back port request

  • 201911
  • 202012
  • 202205

Approach

What is the motivation for this PR?

Temporarily skipping watchdog reboot for Supervisor card in Cisco 8000 distributed chassis. Plan is to add support for it soon.

How did you do it?

Check if dut is a supervisor node and platform is cisco-8000 sup.

How did you verify/test it?

On T2 profile

Any platform specific information?

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

Documentation

@vperumal vperumal requested a review from sujinmkang as a code owner November 11, 2022 18:32
@vperumal
Copy link
Collaborator Author

FYI @abdosi and @gechiang

@azure-pipelines
Copy link

The pre-commit check detected issues in the files touched by this pull request.
The detected issues may be old or new. For new issues, please try to fix them.

For old issues, it is not mandatory to fix them because they were not caused by this change. It is unfair to blame
author of this pull request. But if you can take extra effort to fix the old issues as well, that would be great!

Detailed pre-commit check results:
trim trailing whitespace.................................................Passed
fix end of files.........................................................Passed
check yaml...........................................(no files to check)Skipped
check for added large files..............................................Passed
check python ast.........................................................Passed
flake8...................................................................Failed
- hook id: flake8
- exit code: 1

tests/platform_tests/test_reboot.py:11:1: F401 're' imported but unused
tests/platform_tests/test_reboot.py:14:1: F401 'datetime.datetime' imported but unused
tests/platform_tests/test_reboot.py:18:1: F401 'tests.common.fixtures.conn_graph_facts.conn_graph_facts' imported but unused
tests/platform_tests/test_reboot.py:20:1: F403 'from tests.common.reboot import *' used; unable to detect undefined names
tests/platform_tests/test_reboot.py:37:65: F811 redefinition of unused 'conn_graph_facts' from line 18
tests/platform_tests/test_reboot.py:47:78: F405 'REBOOT_TYPE_COLD' may be undefined, or defined from star imports: tests.common.reboot
tests/platform_tests/test_reboot.py:47:121: E501 line too long (135 > 120 characters)
tests/platform_tests/test_reboot.py:60:5: F405 'sync_reboot_history_queue_with_dut' may be undefined, or defined from star imports: tests.common.reboot
tests/platform_tests/test_reboot.py:63:5: F405 'reboot' may be undefined, or defined from star imports: tests.common.reboot
tests/platform_tests/test_reboot.py:67:5: F405 'REBOOT_TYPE_HISTOYR_QUEUE' may be undefined, or defined from star imports: tests.common.reboot
tests/platform_tests/test_reboot.py:72:79: E251 unexpected spaces around keyword / parameter equals
...
[truncated extra lines, please run pre-commit locally to view full check results]

To run the pre-commit checks locally, you can follow below steps:

  1. Ensure that default python is python3. In sonic-mgmt docker container, default python is python2. You can run
    the check by activating the python3 virtual environment in sonic-mgmt docker container or outside of sonic-mgmt
    docker container.
  2. Ensure that the pre-commit package is installed:
sudo pip install pre-commit
  1. Go to repository root folder
  2. Install the pre-commit hooks:
pre-commit install
  1. Use pre-commit to check staged file:
pre-commit
  1. Alternatively, you can check committed files using:
pre-commit run --from-ref <commit_id> --to-ref <commit_id>

@abdosi abdosi requested a review from gechiang November 16, 2022 01:03
"""
duthost = duthosts[enum_rand_one_per_hwsku_hostname]

if duthost.is_supervisor_node and duthost.facts['platform'] in ['x86_64-8800_rp_o-r0']:
Copy link
Contributor

Choose a reason for hiding this comment

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

@vperumal
Instead of adding a skip here for a specific HW SKU, can this be changed in the Cisco platform code on the handling of "sudo watchdogutil status" to error out or produce no output so that the test is naturally skipped with existing code?
When Cisco is ready to handle it, then you can change your code to respond with proper response and we do not need to change this test code again?
Have you considered this approach instead?

Copy link
Contributor

Choose a reason for hiding this comment

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

@vperumal any comment ?

@abdosi
Copy link
Contributor

abdosi commented Dec 12, 2022

Will be closed as image has fix now.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants