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

[vlan][dhcp_relay] Clear dhcpv6 relay counter while deleting vlan #2852

Merged
merged 1 commit into from
May 29, 2023

Conversation

yaqiangz
Copy link
Contributor

@yaqiangz yaqiangz commented May 26, 2023

What I did

Fix this issue: sonic-net/sonic-buildimage#15047
Show dhcp_relay ipv6 counter will display vlan which has been deleted.
Microsoft ADO number: 22635770

How I did it

Remove related info in state_db while deleting a vlan

How to verify it

  1. Add unit test
tests/vlan_test.py::TestVlan::test_config_vlan_del_vlan PASSED           [ 74%]
  1. Build utilities and run cmd to verify
admin@dut:~$ show dhcp_relay ipv6 counters
       Message Type    Vlan1000
-------------------  ----------
            Unknown           0
            Solicit           0
          Advertise           0
            Request           0
            Confirm           0
              Renew           0
             Rebind           0
              Reply           0
            Release           0
            Decline           0
        Reconfigure           0
Information-Request           0
      Relay-Forward           0
        Relay-Reply           0
          Malformed           0

       Message Type    Vlan1001
-------------------  ----------
            Unknown           0
            Solicit           0
          Advertise           0
            Request           0
            Confirm           0
              Renew           0
             Rebind           0
              Reply           0
            Release           0
            Decline           0
        Reconfigure           0
Information-Request           0
      Relay-Forward           0
        Relay-Reply           0
          Malformed           0

admin@dut:~$ show dhcp6relay_counters counts
       Message Type    Vlan1000
-------------------  ----------
            Unknown           0
            Solicit           0
          Advertise           0
            Request           0
            Confirm           0
              Renew           0
             Rebind           0
              Reply           0
            Release           0
            Decline           0
        Reconfigure           0
Information-Request           0
      Relay-Forward           0
        Relay-Reply           0
          Malformed           0

       Message Type    Vlan1001
-------------------  ----------
            Unknown           0
            Solicit           0
          Advertise           0
            Request           0
            Confirm           0
              Renew           0
             Rebind           0
              Reply           0
            Release           0
            Decline           0
        Reconfigure           0
Information-Request           0
      Relay-Forward           0
        Relay-Reply           0
          Malformed           0

admin@dut:~$ sudo config vlan del 1001
admin@dut:~$ show dhcp_relay ipv6 counters
       Message Type    Vlan1000
-------------------  ----------
            Unknown           0
            Solicit           0
          Advertise           0
            Request           0
            Confirm           0
              Renew           0
             Rebind           0
              Reply           0
            Release           0
            Decline           0
        Reconfigure           0
Information-Request           0
      Relay-Forward           0
        Relay-Reply           0
          Malformed           0

admin@dut:~$ show dhcp6relay_counters counts
       Message Type    Vlan1000
-------------------  ----------
            Unknown           0
            Solicit           0
          Advertise           0
            Request           0
            Confirm           0
              Renew           0
             Rebind           0
              Reply           0
            Release           0
            Decline           0
        Reconfigure           0
Information-Request           0
      Relay-Forward           0
        Relay-Reply           0
          Malformed           0

admin@dut:~$

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)

@yaqiangz
Copy link
Contributor Author

@jcaiMR @Blueve Could you pls help to review this PR?

Copy link
Contributor

@jcaiMR jcaiMR left a comment

Choose a reason for hiding this comment

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

Can we also add vlan check logic when do show command.

@yaqiangz yaqiangz merged commit db61efc into sonic-net:master May 29, 2023
qiluo-msft pushed a commit that referenced this pull request Jun 2, 2023
)

What I did
Fix this issue: sonic-net/sonic-buildimage#15047
Show dhcp_relay ipv6 counter will display vlan which has been deleted.

How I did it
Remove related info in state_db while deleting a vlan

How to verify it
Add unit test
Build utilities and run cmd to verify

Signed-off-by: Yaqiang Zhu <[email protected]>
yxieca pushed a commit that referenced this pull request Jun 2, 2023
)

What I did
Fix this issue: sonic-net/sonic-buildimage#15047
Show dhcp_relay ipv6 counter will display vlan which has been deleted.

How I did it
Remove related info in state_db while deleting a vlan

How to verify it
Add unit test
Build utilities and run cmd to verify

Signed-off-by: Yaqiang Zhu <[email protected]>
StormLiangMS pushed a commit that referenced this pull request Jun 10, 2023
)

What I did
Fix this issue: sonic-net/sonic-buildimage#15047
Show dhcp_relay ipv6 counter will display vlan which has been deleted.

How I did it
Remove related info in state_db while deleting a vlan

How to verify it
Add unit test
Build utilities and run cmd to verify

Signed-off-by: Yaqiang Zhu <[email protected]>
pdhruv-marvell pushed a commit to pdhruv-marvell/sonic-utilities that referenced this pull request Aug 23, 2023
…nic-net#2852)

What I did
Fix this issue: sonic-net/sonic-buildimage#15047
Show dhcp_relay ipv6 counter will display vlan which has been deleted.

How I did it
Remove related info in state_db while deleting a vlan

How to verify it
Add unit test
Build utilities and run cmd to verify

Signed-off-by: Yaqiang Zhu <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants