sonic-mgmt
sonic-mgmt copied to clipboard
add ipv6_mgmt sanity check for debugging
Description of PR
Summary: Add debug info for ADO 28489716
Type of change
- [ ] Bug fix
- [x] Testbed and Framework(new/improvement)
- [ ] Test case(new/improvement)
Back port request
- [ ] 202012
- [ ] 202205
- [x] 202305
- [x] 202311
- [x] 202405
Approach
What is the motivation for this PR?
To check the ipv6_mgmt_only failures failed on setup with "Failed: str3-8102-01 doesn't have available IPv6 Management IP address" in nightly test.
How did you do it?
Add additional debugs before each test run, and check the ipv6 reachability issue.
How did you verify/test it?
Verified reachable, unreachable and attribute scenarios.
Any platform specific information?
Supported testbed topology if it's a new test case?
Documentation
Unit test result for failed output.
04/07/2024 05:31:27 parallel.parallel_run L0153 DEBUG | Started process 27020 running target "_check_ipv6_mgmt_to_dut--<MultiAsicSonicHost vlab-01>"
04/07/2024 05:31:27 checks._check_ipv6_mgmt_to_dut L1002 INFO | Checking ipv6 mgmt interface reachability on vlab-01...
04/07/2024 05:31:38 checks._check_ipv6_mgmt_to_dut L1012 INFO | Failed to ping ipv6 mgmt interface on vlab-01, exception: CalledProcessError(1, ['ping6', '-c', '2', '2001::8'])
04/07/2024 05:31:38 checks._check_ipv6_mgmt_to_dut L1013 INFO | Ping6 output: PING 2001::8(2001::8) 56 data bytes
--- 2001::8 ping statistics ---
2 packets transmitted, 0 received, 100% packet loss, time 1032ms
04/07/2024 05:31:38 checks._check_ipv6_mgmt_to_dut L1017 INFO | Done checking ipv6 management reachability on vlab-01
04/07/2024 05:31:38 parallel.on_terminate L0085 INFO | process _check_ipv6_mgmt_to_dut--<MultiAsicSonicHost vlab-01> terminated with exit code None
04/07/2024 05:31:38 parallel.parallel_run L0161 DEBUG | task completed 1, running 0
04/07/2024 05:31:38 parallel.parallel_run L0221 INFO | Completed running processes for target "_check_ipv6_mgmt_to_dut" in 0:00:11.047571 seconds
04/07/2024 05:31:38 __init__.do_checks L0114 DEBUG | check results of each item [{'failed': False, 'check_item': 'ipv6_mgmt', 'host': 'vlab-01'}]
Unit test for passed output:
04/07/2024 05:23:43 parallel.parallel_run L0153 DEBUG | Started process 24234 running target "_check_ipv6_mgmt_to_dut--<MultiAsicSonicHost vlab-01>"
04/07/2024 05:23:43 checks._check_ipv6_mgmt_to_dut L1002 INFO | Checking ipv6 mgmt interface reachability on vlab-01...
04/07/2024 05:23:44 checks._check_ipv6_mgmt_to_dut L1008 INFO | Ping6 output: PING fec0::ffff:afa:1(fec0::ffff:afa:1) 56 data bytes
64 bytes from fec0::ffff:afa:1: icmp_seq=1 ttl=63 time=0.436 ms
64 bytes from fec0::ffff:afa:1: icmp_seq=2 ttl=63 time=0.601 ms
--- fec0::ffff:afa:1 ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 1005ms
rtt min/avg/max/mdev = 0.436/0.518/0.601/0.082 ms
04/07/2024 05:23:44 checks._check_ipv6_mgmt_to_dut L1017 INFO | Done checking ipv6 management reachability on vlab-01
04/07/2024 05:23:44 parallel.on_terminate L0085 INFO | process _check_ipv6_mgmt_to_dut--<MultiAsicSonicHost vlab-01> terminated with exit code None
04/07/2024 05:23:44 parallel.parallel_run L0161 DEBUG | task completed 1, running 0
04/07/2024 05:23:44 parallel.parallel_run L0221 INFO | Completed running processes for target "_check_ipv6_mgmt_to_dut" in 0:00:01.020536 seconds
04/07/2024 05:23:44 __init__.do_checks L0114 DEBUG | check results of each item [{'failed': False, 'check_item': 'ipv6_mgmt', 'host': 'vlab-01'}]
Cherry-pick PR to 202311: https://github.com/sonic-net/sonic-mgmt/pull/13657
Cherry-pick PR to 202405: https://github.com/sonic-net/sonic-mgmt/pull/13658
Cherry-pick PR to 202305: https://github.com/sonic-net/sonic-mgmt/pull/13659