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

[dhcpv6_relay] Fix DHCPv6 Relay config CLI to update DHCP_RELAY table #13039

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

praveen-ramamoorthi
Copy link

Why I did it

Recently, DHCPv6 Relay DB table is changed from VLAN to DHCP_RELAY. The dhcp6relay process is spawned with the data fetched from this new table . The show CLIs were updated , but config CLIs were not updated to write to new table and still updated old VLAN table. Hence the DHCPv6 Relay was not working with CLI configurations.

How I did it

The config CLI script is modified to update new table DHCP_RELAY. The UT scripts are modified to test new table.

How to verify it

Configure DHCPv6 Relay address for vlan using CLI and check if the config is updated in DHCP_RELAY table and verify if DHCPv6 Relay process is started for that vlan.

Which release branch to backport (provide reason below if selected)

  • 201811
  • 201911
  • 202006
  • 202012
  • 202106
  • 202111
  • 202205
  • 202211

Description for the changelog

Fixed configuration CLI for DHCPv6 Relay to update data in DHCP_RELAY table.

Link to config_db schema for YANG module changes

A picture of a cute animal (not mandatory but encouraged)

@linux-foundation-easycla
Copy link

linux-foundation-easycla bot commented Dec 13, 2022

CLA Signed

The committers listed above are authorized under a signed CLA.

  • ✅ login: praveen-ramamoorthi / name: Praveen Ramamoorthi (34aa355)

@praveen-ramamoorthi
Copy link
Author

@kellyyeh Can you please review this fix?

@vivekrnv
Copy link
Contributor

I don't think we should just redirect the dhcpv6_servers field to DHCP_RELAY table. We're also leaving out rfc6939_support field.

i instead think we should update the VLAN cli to reject adding dhcpv6 config and just load the config with config load and restart the service. Related issue on that: #12954. @kellyyeh , @yxieca what do you think

@kellyyeh
Copy link
Contributor

I don't think we should just redirect the dhcpv6_servers field to DHCP_RELAY table. We're also leaving out rfc6939_support field.

i instead think we should update the VLAN cli to reject adding dhcpv6 config and just load the config with config load and restart the service. Related issue on that: #12954. @kellyyeh , @yxieca what do you think

@vivekrnv Agreed. Config add/del was a feature for VLAN table and we did not have plan to use config cli to update DHCP_RELAY. dhcp6relay does not support dynamic change in DHCP_RELAY table yet, so let's stick with config load and restart service only

@praveen-ramamoorthi
Copy link
Author

@vivekrnv @kellyyeh - This PR implements config load + service restart in Click command & thus avoid manual config load + service restart sequence. For #12954, I would prefer fixing the issue (update in proper redis tables) rather than rejecting the config.

From command definition perspective, VLAN related configurations are grouped under "config vlan <>" tree. This does not mean that all such configurations are stored in single redis DB table. For example, "config vlan member <>" & "config vlan proxy_arp <>" are being updated into VLAN_MEMBER & VLAN_INTERFACE tables respectively.

Regarding "rfc6939_support", no Click command is available yet which shall be treated as new command enhancement.

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