400
Configuration procedure
# Enable IPv6SG on FortyGigE 1/1/1.
<Switch> system-view
[Switch] interface fortygige 1/1/1
[Switch-FortyGigE1/1/1] ipv6 verify source ip-address mac-address
# On FortyGigE 1/1/1, configure a static IPv6SG binding for the host.
[Switch-FortyGigE1/1/1] ipv6 source binding ip-address 2001::1 mac-address 0001-0202-0202
[Switch-FortyGigE1/1/1] quit
Verifying the configuration
# Verify that the static IPv6SG binding is configured successfully on the switch.
[Switch] display ipv6 source binding static
Total entries found: 1
IPv6 Address MAC Address Interface VLAN Type
2001::1 0001-0202-0202 FGE1/1/1 N/A Static
Dynamic IPv6SG using DHCPv6 snooping configuration
example
Network requirements
As shown in
, the host (the DHCPv6 client) obtains an IP address from the DHCPv6 server.
Perform the following tasks:
•
Enable DHCPv6 snooping on the switch to make sure the DHCPv6 client obtains an IPv6
address from the authorized DHCPv6 server. To generate a DHCPv6 snooping entry for the
DHCPv6 client, enable recording of client information in DHCPv6 snooping entries.
•
Enable dynamic IPv6SG on FortyGigE 1/1/1 to filter incoming packets by using the IPv6SG
bindings generated based on DHCPv6 snooping entries. Only packets from the DHCPv6 client
are allowed to pass.
Figure 121 Network diagram
Configuration procedure
1.
Configure DHCPv6 snooping:
# Enable DHCPv6 snooping globally.
<Switch> system-view
[Switch] ipv6 dhcp snooping enable
# Configure FortyGigE 1/1/2 as a trusted interface.
[Switch] interface fortygige 1/1/2
[Switch-FortyGigE1/1/2] ipv6 dhcp snooping trust
[Switch-FortyGigE1/1/2] quit
2.
Enable IPv6SG:
# Enable IPv6SG on FortyGigE 1/1/1 and verify the source IP address and MAC address for
dynamic IPv6SG.
[Switch] interface fortygige 1/1/1