background image

11 

 

Configuring dynamic IPv6 address 
assignment 

Introduction 

The following example describes the basic procedure to configure an interface as a DHCPv6 server 
for dynamic IPv6 address assignment.

 

Network configuration 

As shown in

 Figure 4

Switch A and Switch B are gateway devices for internal hosts. Configure the 

network to meet the following requirements: 

 

Switch A and Switch B are connected through Ethernet interfaces. The interfaces of each 
switch operate in different VLAN and have IPv6 addresses. 

 

VLAN-interface 1 and VLAN-interface 3 operate in DHCPv6 server mode to assign IPv6 
addresses to hosts. 

 

Switch A and Switch B have IPv6 static routes to ensure network connectivity. 

Figure 4 Network diagram 

 

 

Procedure 

1. 

Configure Switch A. 

# Create VLAN 1 and assign GigabitEthernet 1/0/2 to VLAN 1. 

<SwitchA> system-view 

[SwitchA] vlan 1 

[SwitchA-vlan1] port gigabitethernet 1/0/2 

[SwitchA-vlan1] quit 

# Create VLAN 2 and assign GigabitEthernet 1/0/1 to VLAN 2. 

[SwitchA] vlan 2 

[SwitchA-vlan2] port gigabitethernet 1/0/1 

[SwitchA-vlan2] quit 

# Specify an IPv6 global unicast address for VLAN-interface 2. 

[SwitchA] interface vlan-interface 2 

[SwitchA-Vlan-interface2] ipv6 address 3001::1/64 

[SwitchA-Vlan-interface2] quit 

# Specify an IPv6 global unicast address for VLAN-interface 1 and disable RA message 
suppression on VLAN-interface 1. 

[SwitchA] interface vlan-interface 1 

[SwitchA-Vlan-interface1] ipv6 address 2001::1/64 

Switch A

Switch B

Vlan-int2
3001::1/64

Vlan-int2

3001::2/64

Vlan-int1

2001::1/64

GE1/0/2

GE1/0/1

GE1/0/1

Host A

Host B

Vlan-int3
4001::1/64

GE1/0/2

Содержание DHCP

Страница 1: ...oduced or transmitted in any form or by any means without prior written consent of New H3C Technologies Co Ltd Except for the trademarks of New H3C Technologies Co Ltd any trademarks that may be menti...

Страница 2: ...nfiguration 5 Procedure 5 Verifying the configuration 7 Configuration files 7 Related documentation 8 Configuring DHCP snooping 9 Introduction 9 Network configuration 9 Procedure 9 Verifying the confi...

Страница 3: ...The IP addresses of VLAN interface 5 VLAN interface 6 and VLAN interface 7 on the switch are 192 168 5 254 24 192 168 6 254 24 and 192 168 7 254 24 respectively For the hosts in subnet 192 168 5 0 24...

Страница 4: ...cific IP addresses such as DNS server IP addresses from dynamic IP address assignment Switch dhcp server forbidden ip 192 168 5 100 Switch dhcp server forbidden ip 192 168 6 100 Switch dhcp server for...

Страница 5: ...2021 Auto C 662e 3030 3033 2d45 7568 6572 1e The output shows that the DHCP server can assign IP addresses and other network settings to the clients on subnets 192 168 5 0 24 192 168 6 0 24 and 192 16...

Страница 6: ...igabitEthernet1 0 5 port link mode bridge port access vlan 5 interface GigabitEthernet1 0 6 port link mode bridge port access vlan 6 interface GigabitEthernet1 0 7 port link mode bridge port access vl...

Страница 7: ...network to meet the following requirements The DHCP clients run on subnets 192 168 5 0 24 and 192 168 6 0 24 and the DHCP server IP address is 192 168 7 100 24 Switch A acts as the DHCP relay agent f...

Страница 8: ...ddress to VLAN 5 VLAN 6 and VLAN 7 respectively SwitchA interface vlan interface 5 SwitchA Vlan interface5 ip address 192 168 5 1 255 255 255 0 SwitchA Vlan interface5 quit SwitchA interface vlan inte...

Страница 9: ...rt access vlan 5 interface GigabitEthernet1 0 3 port link mode bridge port access vlan 6 Switch A dhcp enable vlan 5 to 7 interface Vlan interface5 ip address 192 168 5 1 255 255 255 0 dhcp select rel...

Страница 10: ...rnet1 0 2 port link mode bridge port access vlan 7 Related documentation DHCP configuration in the Layer 3 IP services configuration guide for the device DHCP commands in the Layer 3 IP services comma...

Страница 11: ...erver The DHCP snooping device records clients IP to MAC bindings by reading DHCP ACK messages received from the trusted port and the DHCPREQUEST messages Figure 3 Network diagram Procedure Enable glo...

Страница 12: ...k the DHCP snooping entry recorded for the client Configuration files dhcp snooping enable interface GigabitEthernet1 0 1 port link mode bridge dhcp snooping trust interface Ten GigabitEthernet1 0 2 p...

Страница 13: ...connectivity Figure 4 Network diagram Procedure 1 Configure Switch A Create VLAN 1 and assign GigabitEthernet 1 0 2 to VLAN 1 SwitchA system view SwitchA vlan 1 SwitchA vlan1 port gigabitethernet 1 0...

Страница 14: ...the next hop of the route is 3001 2 SwitchA ipv6 route static 4001 64 3001 2 Save the configuration SwitchA save force 2 Configure Switch B Create VLAN 2 and assign GigabitEthernet 1 0 1 to VLAN 2 Swi...

Страница 15: ...n View the IPv6 addresses assigned by the DHCPv6 server on Switch A SwitchA display ipv6 dhcp server ip in use Pool 1 IPv6 address Type Lease expiration 2001 2 Auto C Sep 30 11 45 07 2021 View informa...

Страница 16: ...ver apply pool 1 allow hint rapid commit ipv6 address 2001 1 64 ipv6 nd autoconfig managed address flag undo ipv6 nd ra halt interface Vlan interface2 ipv6 address 3001 1 64 interface GigabitEthernet1...

Страница 17: ...a halt interface GigabitEthernet1 0 1 port link mode bridge port access vlan 2 interface GigabitEthernet1 0 2 port link mode bridge port access vlan 3 ipv6 route static 2001 64 3001 1 Related document...

Отзывы: