Skip to content

Commit 430e25e

Browse files
Merge pull request sonic-net#242 from BRCM-SONIC/dhcp_snooping_updates
Add a limitations section to the HLD.
2 parents 03ebfde + 18295f9 commit 430e25e

File tree

1 file changed

+61
-42
lines changed

1 file changed

+61
-42
lines changed

L2/DHCP_Snooping/DHCP_Snooping_HLD.md

+61-42
Original file line numberDiff line numberDiff line change
@@ -37,20 +37,22 @@
3737
- [5 Serviceability and Debug](#5-serviceability-and-debug)
3838
- [6 Warm Boot Support](#6-warm-boot-support)
3939
- [7 Scalability](#7-scalability)
40-
- [8 Unit Test](#8-unit-test)
41-
- [9 Internal Design Information](#9internal-design-information)
40+
- [8 Future enhancement](#7-future-enhancement)
41+
- [9 Unit Test](#9-unit-test)
42+
- [10 Internal Design Information](#10internal-design-information)
4243

4344

4445
# List of Tables
4546
[Table 1: Abbreviations](#table-1-abbreviations)
4647

4748
# Revision
4849

49-
| Rev | Date | Author | Change Description |
50-
|-----|-------------|--------------------|-----------------------------------|
51-
| 0.1 | 02/22/2021 | Phanindra TV | Initial version |
52-
| 0.2 | 03/31/2021 | Ravi Vemuri | More details added |
53-
| 0.3 | 06/07/2021 | Ravi Vemuri | Address review comments. |
50+
| Rev | Date | Author | Change Description |
51+
|-----|-------------|--------------------|------------------------------------------------------|
52+
| 0.1 | 02/22/2021 | Phanindra TV | Initial version |
53+
| 0.2 | 03/31/2021 | Ravi Vemuri | More details added |
54+
| 0.3 | 06/07/2021 | Ravi Vemuri | Address review comments. |
55+
| 0.4 | 07/15/2021 | Ravi Vemuri | Add Limitations/Future enhancements section |
5456

5557
# About this Manual
5658
This document provides general information about the support for DHCPv4 snooping and DHCPv6 snooping in SONiC.
@@ -299,11 +301,11 @@ For example,
299301

300302
;Stores user configured static DHCP bindings
301303
;Status: work in progress
302-
key = DHCP_SNOOPING_STATIC_BINDING|GLOBAL ; Global DHCP snooping static binding table key
303-
mac = mac-address ; client hardware address
304-
vlan = vlan-id ; DHCP snooping enabled vlan
305-
intf = interface ; front panel physical port or port channel
306-
ipaddress = ipv4 address / ipv6 address ; ipv4/ipv6 address
304+
key = DHCP_SNOOPING_STATIC_BINDING|mac|ipType ; DHCP snooping static binding table key - mac + "ipv4" or "ipv6"
305+
mac = mac-address ; client hardware address
306+
vlan = vlan-id ; DHCP snooping enabled vlan
307+
intf = interface ; front panel physical port or port channel
308+
ipaddress = ipv4 address / ipv6 address ; ipv4/ipv6 address
307309

308310
#### 3.2.1.4 Trust Configuration
309311

@@ -338,13 +340,13 @@ DHCP_SNOOPING_BINDING_GLOBAL_TABLE
338340

339341
;Stores dynamic DHCP bindings
340342
;Status: work in progress
341-
key = DHCP_SNOOPING_BINDING|GLOBAL ; Global DHCP snooping binding table key
342-
mac = mac-address ; client hardware address
343-
vlan = vlan-id ; DHCP snooping enabled vlan
344-
intf = interface ; front panel physical port or port channel
345-
ipaddress = ipv4 address / ipv6 address ; ipv4/ipv6 address
346-
lease_time = time in seconds ; time allotted by DHCP server, NA for static entry
347-
type = "static"/"dynamic" ; static or dynamic
343+
key = DHCP_SNOOPING_BINDING|mac|ipType ; DHCP snooping binding table key - mac + "ipv4" or "ipv6"
344+
mac = mac-address ; client hardware address
345+
vlan = vlan-id ; DHCP snooping enabled vlan
346+
intf = interface ; front panel physical port or port channel
347+
ipaddress = ipv4 address / ipv6 address ; ipv4/ipv6 address
348+
lease_time = time in seconds ; time allotted by DHCP server, NA for static entry
349+
type = "static"/"dynamic/tentative" ; static, dynamic or tentative
348350

349351

350352
### 3.2.3 Counters DB
@@ -353,21 +355,22 @@ DHCP_SNOOPING_BINDING_GLOBAL_TABLE
353355

354356
The following counters will be added to capture statistics. This section is TBD.
355357

356-
Error receiving from DHCP snooping socket
357-
DHCP message too big
358-
Error sending from DHCP snooping socket
359-
Illegal source IP address in snooped packet
360-
Number of DHCP messages intercepted
361-
Number of DHCP messages processed
362-
Number of DHCP messages filtered
363-
Number of DHCP messages forwarded
364-
Number of DHCP message tx failures
365-
Rx REL or DECL from client not in bindings db
366-
Number of bindings added to bindings table
367-
Number of bindings removed from bindings table
368-
Number of DHCP messages dropped as static binding exists
369-
Packets discarded on unsupported outgoing interface
370-
Packets dropped due to no outgoing interface
358+
Error receiving from DHCP snooping socket
359+
DHCP message too big
360+
Error sending from DHCP snooping socket
361+
Illegal source IP address in snooped packet
362+
Illegal source MAC in snooped packet
363+
Number of DHCP messages intercepted
364+
Number of DHCP messages processed
365+
Number of DHCP messages filtered
366+
Number of DHCP messages forwarded
367+
Number of DHCP message tx failures
368+
Rx REL or DECL from client not in bindings db
369+
Number of bindings added to bindings table
370+
Number of bindings removed from bindings table
371+
Number of DHCP messages dropped as static binding exists
372+
Packets discarded on unsupported outgoing interface
373+
Packets dropped due to no outgoing interface
371374

372375
## 3.3 COPP
373376

@@ -456,19 +459,19 @@ This command is executed in config mode.
456459
To bind a static IPv4 address to a Layer 2 interface
457460
sonic(config)#[no] ip source binding *IP-address* *MAC-address* vlan *vlan-id* {interface <interface name>}
458461
459-
To clear all IP DHCP Snooping binding entries
462+
To clear all dynamic IP DHCP Snooping binding entries
460463
sonic(config)# clear ip dhcp snooping binding
461464
462-
To clear a specific IP DHCP Snooping binding entry
465+
To clear a specific dynamic IP DHCP Snooping binding entry
463466
sonic(config)# clear ip dhcp snooping binding *IP-address* *MAC-address* vlan *vlan-id* {interface <interface name>}
464467

465468
To bind a static IPv6 address to a Layer 2 interface
466469
sonic(config)#[no] ipv6 source binding *IP-address* *MAC-address* vlan *vlan-id* {interface <interface name>}
467470
468-
To clear all IPv6 DHCP Snooping binding entries
471+
To clear all dynamic IPv6 DHCP Snooping binding entries
469472
sonic(config)# clear ipv6 dhcp snooping binding
470473
471-
To clear a specific IPv6 DHCP Snooping binding entry
474+
To clear a specific dynamic IPv6 DHCP Snooping binding entry
472475
sonic(config)# clear ipv6 dhcp snooping binding *IP-address* *MAC-address* vlan *vlan-id* {interface <interface name>}
473476

474477
##### 3.7.1.1.5 Configure an interface as trusted
@@ -501,6 +504,10 @@ This command is executed in interface mode. This command can be applied on a ran
501504
To display DHCPv6 Snooping statistics
502505
sonic# show ipv6 dhcp snooping statistics
503506

507+
DHCP Snooping statistics can be cleared with the following commands
508+
sonic# clear ip dhcp snooping statistics
509+
sonic# clear ipv6 dhcp snooping statistics
510+
504511
For example,
505512

506513
console#show ip dhcp snooping
@@ -576,9 +583,16 @@ Go back to [Beginning of the document](#dhcp-snooping).
576583
DHCP Snoopoing feature allows 1024 Static entries to be configured. A total of 8K clients are supported (4K for DHCPv4 and 4K for DHCPv6). Beyond the limit, the DHCP Snooping DB is not updated and the DHCP packets are dropped.
577584

578585
Go back to [Beginning of the document](#dhcp-snooping).
579-
# 8 Unit Test
580586

581-
##8.1 CLI Test cases
587+
# 8 Future Enhancements, Limitations
588+
589+
1. DHCP Snooping is not supported for clients/servers connected to MCLAG. DHCP Snooping binding entries are not currently synced between the MCLAG peers and hence DHCP messages may not be filtered if ingress is on a peer on which the binding was not created.
590+
591+
Go back to [Beginning of the document](#dhcp-snooping).
592+
593+
# 9 Unit Test
594+
595+
##9.1 CLI Test cases
582596

583597
1. Verify CLI to enable DHCPv4 Snooping globally
584598
2. Verify CLI to enable DHCPv4 Snooping per VLAN
@@ -612,9 +626,11 @@ Go back to [Beginning of the document](#dhcp-snooping).
612626
30. Verify CLI to enable debug logs for DHCP Snooping
613627
31. Verify CLI to enable DHCP Snooping debug logs per VLAN
614628
32. Verify CLI to enable DHCP Snooping debug logs per interface
629+
33. Verify CLI to configure trust mode for a range of interfaces, for DHCP4
630+
34. Verify CLI to configure trust mode for a range of interfaces, for DHCP6
615631

616632

617-
##8.2 Functionality test cases
633+
##9.2 Functionality test cases
618634

619635
1. Verify that DHCP functionality is not impacted if DHCP Snooping is not enabled globally.
620636
2. Verify that once DHCP Snooping functionality is enabled globally, the DHCP messages received in VLANs that are not enabled for snooping are discarded.
@@ -647,9 +663,12 @@ Go back to [Beginning of the document](#dhcp-snooping).
647663
29. Verify that the VLAN on which DHCP snooping is enabled, cannot be deleted.
648664
30. Verify that trust/untrust configuration on a port is retained after a port shut/no-shut operation.
649665
31. Verify that a port can be set to 'trust' only if the VLAN to which it belongs has DHCP snooping enabled.
666+
32. Verify that DHCP Snooping dynamic binding entries are retained across warm boot
667+
33. Verify that DHCP Snooping dynamic binding entries lease time is updated with the time taken for warm boot operation.
668+
34. Verify that DHCP Snooping dynamic binding entires whose lease expired during the warm boot operation do not appear after warm boot is complete.
650669

651670
Go back to [Beginning of the document](#dhcp-snooping).
652-
# 9 Internal Design Information
671+
# 10 Internal Design Information
653672
![DHCP snooping high level architecture](ds_packet_flow.png)
654673

655674
Go back to [Beginning of the document](#dhcp-snooping).

0 commit comments

Comments
 (0)