Skip to content

Commit

Permalink
Address PR comments
Browse files Browse the repository at this point in the history
  • Loading branch information
kellyyeh authored Dec 8, 2022
1 parent 5c874a6 commit 7f46964
Showing 1 changed file with 45 additions and 4 deletions.
49 changes: 45 additions & 4 deletions doc/DHCPv6_relay/DHCPv6-relay-agent-High-Level-Design.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@
- [CONFIG DB schema](#config-db-schema)
- [YANG Model schema](#yang-model-schema)
- [Option 79 for client link-layer address](#option-79-for-client-link-layer-address)
- [Option 18 for Interface-ID](#option-18-for-interface-id)
- [Config Update](#config-update)
- [Option for Dual ToR](#option-for-dual-tor)
- [Feature table](#feature-table)
- [RADV modification](#radv-modification)
Expand Down Expand Up @@ -167,6 +169,20 @@ RELAY-REPLY
DHCP|intf-i|dhcpv6_servers: ["dhcp-server-0", "dhcp-server-1", ...., "dhcp-server-n-1"]

DHCP|intf-i|dhcpv6_option|rfc6939_support: "true"

DHCP|intf-i|dhcpv6_option|interface_id: "true"
</pre>

<pre>
{
"DHCP_RELAY" :{
"Vlan100" : {
"dhcpv6_servers" : ["fc02:2000::2"]
"dhcpv6_option|rfc6939_support" : "true"
"dhcpv6_option|interface_id" : "true"
}
}
}
</pre>

# YANG Model schema
Expand Down Expand Up @@ -239,11 +255,19 @@ config vlan dhcp_relay add <vlan_id> <dhcp_relay_destination_ip>
```
Restart dhcp_relay after updating ipv6 helper information.

**only DHCP_RELAY table needs to be updated for the latest versions.

Example:
Or edit directly in config_db.json and apply config_reload:
```
admin@sonic:~$ redis-cli -n 4 hset DHCP_RELAY|Vlan1000 dhcpv6_option|rfc6939_support false
/etc/sonic/config_db.json:
{
"DHCP_RELAY" :{
"Vlan100" : {
"dhcpv6_servers" : ["fc02:2000::2"]
"dhcpv6_option|rfc6939_support" : "true"
}
}
}
sudo config reload
```

# Option 18 for Interface-ID
Expand All @@ -255,12 +279,29 @@ Usage:
config vlan dhcp_relay add <vlan_id> <dhcp_relay_destination_ip>
redis-cli -n 4 hset DHCP_RELAY|<vlan> dhcpv6_option|interface_id <true/false>
```
Or edit directly in config_db.json and apply config_reload:
/etc/sonic/config_db.json:
{
"DHCP_RELAY" :{
"Vlan100" : {
"dhcpv6_servers" : ["fc02:2000::2"],
"dhcpv6_option|interface_id" : "true"
}
}
}

sudo config reload

Example:
```
admin@sonic:~$ redis-cli -n 4 hset DHCP_RELAY|Vlan1000 dhcpv6_option|interface_id true
```

# Config Update

We have shifted from VLAN table to DHCP_RELAY table to store ipv6 helper information.
Only DHCP_RELAY table needs to be updated for the versions containing PR https://github.com/sonic-net/sonic-buildimage/pull/10654, or version 20201231.75 and 20181130.98 and above

# Option for Dual ToR

Relayed DHCPv6 packet from ToR may have the response routed to the peer ToR that has the link as standby. Since the originating client is not active on this ToR, the peer ToR won't be able to relay the response. Peer ToR will not receive the packets as the originating client is not active on this ToR. Instead of using Vlan SVI IP address, relay agent source address needs to be set to listen on the loopback address. When DHCP server responses are received by relay agent on the peer ToR, DHCP relay agent would then forward the packet to the peer ToR using its loopback IP interface.
Expand Down

0 comments on commit 7f46964

Please sign in to comment.