11 IPv6 Basics - 1609740899328
11 IPv6 Basics - 1609740899328
Page 1 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
Foreword
⚫ In the 1980s, the Internet Engineering Task Force (IETF) released RFC 791 – Internet
Protocol, which marks the standardization of IPv4. In the following decades, IPv4 has
become one of the most popular protocols. Numerous people have developed
various applications based on IPv4 and made various supplements and
enhancements to IPv4, enabling the Internet to flourish.
⚫ However, with the expansion of the Internet and the development of new
technologies such as 5G and Internet of Things (IoT), IPv4 faces more and more
challenges. It is imperative to replace IPv4 with IPv6.
⚫ This course describes the reasons for IPv4-to-IPv6 transition and basic IPv6
knowledge.
Page 2 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
Objectives
⚫ On completion of this course, you will be able to:
▫ Summarize the advantages of IPv6 over IPv4.
▫ Describe the method and basic procedure for configuring IPv6 addresses.
▫ Configure IPv6 addresses and IPv6 static routes.
Page 3 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
Contents
1. IPv6 Overview
Page 4 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
IPv4 Status
⚫ On February 3, 2011, the Internet Assigned Numbers Authority (IANA) announced even allocation of its
last 4.68 million IPv4 addresses to five Regional Internet Registries (RIRs) around the world. The IANA
thereafter had no available IPv4 address.
?
RIPE: announced IPv4 ARIN: announced IPv4
IPv6
address exhaustion address exhaustion
Page 5 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
Why IPv6?
IPv4 IPv6
...
Page 6 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
IPv6 Advantages
Nearly infinite address The 128-bit address length provides numerous addresses, meeting the requirements of emerging services such as
space the IoT and facilitating service evolution and expansion.
Hierarchical address IPv6 addresses are allocated more properly than IPv4 addresses, facilitating route aggregation (reducing the size
structure of IPv6 routing tables) and fast route query.
Plug-and-play IPv6 supports stateless address autoconfiguration (SLAAC), simplifying terminal access.
Simplified packet The simplified packet header improves forwarding efficiency. New applications can be supported using extension
header headers, which facilitate the forwarding processing of network devices and reduce investment costs.
IPsec, source address authentication, and other security features ensure E2E security, preventing NAT from
Security features damaging the integrity of E2E communication.
Enhanced QoS A Flow Label field is additionally defined and can be used to allocate a specific resource for a special service and
features data flow.
Page 7 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
Basic IPv6 Header
⚫ An IPv6 header consists of a mandatory basic IPv6 header and optional extension headers.
⚫ The basic header provides basic information for packet forwarding and is parsed by all devices on a
forwarding path.
IPv4 packet header (20–60 bytes) Basic IPv6 header (40 bytes)
Destination Address
Destination Address
Options Padding
Name/Location
Deleted Reserved New
changed
Page 9 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
IPv6 Extension Header
Traffic • Extension Header Length: 8 bits long. This
Version Flow Label
Class field indicates the extension header length
excluding the length of the Next Header field.
Next 40 • Extension Header Data: variable length. This
Payload Length Hop Limit
Header bytes field indicates the payload of the extension
headers and is a combination of a series of
Source Address (128 bits) options and padding fields.
Destination Address (128 bits)
Basic IPv6 Header
Next Header Extension Header Length Next Header=0 (Hop-by-Hop Options Header)
Variable
length IPv6 Hop-by-Hop Options Header
Extension Header Data Next Header=51 (Authentication Header)
IPv6 Authentication Header
Next Header Extension Header Length Variable Next Header=6 (TCP)
Extension Header Data length
TCP Data Segment
... IPv6 packet example
Data
Page 10 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
IPv6 Packet Processing Mechanism
Basic IPv6 Header Basic IPv6 Header Basic IPv6 Header
Next Header=0 (Hop-by-Hop Next Header=0 (Hop-by-Hop Options Next Header=0 (Hop-by-Hop
Options Header) Header) Options Header)
IPv6 Hop-by-Hop Options Header IPv6 Hop-by-Hop Options Header IPv6 Hop-by-Hop Options Header
Next Header=51 (Authentication Next Header=51 (Authentication Next Header=51 (Authentication
Header) Header) Header)
IPv6 Authentication Header IPv6 Authentication Header IPv6 Authentication Header
Next Header=6 (TCP) Next Header=6 (TCP) Next Header=6 (TCP)
Page 12 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
IPv6 Address
⚫ The length of an IPv6 address is 128 bits. Colons are generally used to divide the IPv6 address into
eight segments. Each segment contains 16 bits and is expressed in hexadecimal notation.
• Similar to an IPv4 address, an IPv6 address is expressed in the format of IPv6 address/mask length.
▫ Example: 2001:0DB8:2345:CD30:1230:4567:89AB:CDEF/64
Page 13 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
IPv6 Address Abbreviation Specifications
⚫ For convenience, IPv6 can be abbreviated according to the following rules.
Abbreviation Specifications Abbreviation Examples
2001 : 0DB8 : 0000 : 0000 : 0008 : 0800 : 200C : 417A Before 0000:0000:0000:0000:0000:0000:0000:0001
The leading 0s in each 16-bit segment can be omitted. However, if all After ::1
bits in a 16-bit segment are 0s, at least one 0 must be reserved. The
tailing 0s cannot be omitted.
Before 2001:0DB8:0000:0000:FB00:1400:5000:45FF
After 2001:DB8::FB00:1400:5000:45FF
2001 : DB8 : 0 : 0 : 8 : 800 : 200C : 417A
If one or more consecutive 16-bit segments contain only 0s, a double Before 2001:0DB8:0000:0000:0000:2A2A:0000:0001
colon (::) can be used to represent them, but only one :: is allowed in After 2001:DB8::2A2A:0:1
an entire IPv6 address.
Before 2001:0DB8:0000:1234:FB00:0000:5000:45FF
2001 : DB8 :: 8 : 800 : 200C : 417A
After 2001:DB8::1234:FB00:0:5000:45FF
If an abbreviated IPv6 address contains two double colons (::), the IPv6
address cannot be restored to the original one. or 2001:DB8:0:1234:FB00::5000:45FF
Page 14 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
IPv6 Address Classification
⚫ IPv6 addresses are classified into unicast, multicast, and anycast addresses according
to the IPv6 address prefix. No broadcast addresses
IPv6 are defined in IPv6.
addresses
Page 15 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
IPv6 Unicast IPv6 Multicast IPv6 Anycast
Address Address Address
▫ Interface ID: consists of (128 – n) bits and is parallel to the host ID of an IPv4 address.
⚫ Common IPv6 unicast addresses, such as GUAs and LLAs, require that the network
prefix and interface ID be 64 bits.
Page 16 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
IPv6 Unicast IPv6 Multicast IPv6 Anycast
Address Address Address
⚫ EUI-64 is most commonly used. It converts the MAC address of an interface into an IPv6 interface ID.
EUI-64 ID
(binary) 00111110-10010010-10000010-11111111-11111110-01001001-01111110-10011101
Page 17 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
IPv6 Unicast IPv6 Multicast IPv6 Anycast
Address Address Address
Page 18 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
IPv6 Unicast IPv6 Multicast IPv6 Anycast
Address Address Address
Generated using a
pseudo-random algorithm
• ULAs use the FC00::/7 address segment, among
which, only the FD00::/8 address segment is currently
used. FC00::/8 is reserved for future expansion.
• Although a ULA is valid only in a limited range, it
also has a globally unique prefix (generated using a
pseudo-random algorithm, low conflict probability).
FD00:1AC0:872E::1/64 FD00:1AC0:872E::2/64 FD00:2BE1:2320::1/64
Page 19 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
IPv6 Unicast IPv6 Multicast IPv6 Anycast
Address Address Address
IPv6
10 bit 54 bit 64 bit
Internet
1111 1110 10 0 Interface ID
Fixed at 0
Page 20 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
IPv6 Unicast IPv6 Multicast IPv6 Anycast
Address Address Address
⚫ An IPv6 multicast address can be used only as the destination address of IPv6 packets.
Multicast
source
8 bits 4 bits 4 bits 80 bits 32 bits Multicast
11111111 Flags Scope Reserved (must be 0) Group ID Network
Page 21 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
IPv6 Unicast IPv6 Multicast IPv6 Anycast
Address Address Address
64 bits 64 bits
IPv6 unicast or
anycast address IPv6 Address Prefix Interface ID
24 bits
copied
Corresponding
FF02 0000 0000 0000 0000 0001 FF
solicited-node
multicast address 104 bits (fixed prefix) 24 bits
Page 22 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
IPv6 Unicast IPv6 Multicast IPv6 Anycast
Address Address Address
Page 23 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
Contents
1. IPv6 Overview
Page 24 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
IPv6 Addresses of Hosts and Routers
⚫ The unicast IPv6 addresses and multicast addresses of hosts and routers are typically as follows:
Network
LLA of the network adapter FE80::2E0:FCFF:FE35:7287 LLA of the network adapter FE80::2E0:FCFF:FE99:1285
GUA assigned by an
GUA assigned by an 2001::2
2001::1 administrator
administrator
Loopback address ::1
Loopback address ::1
Multicast addresses of all
FF01::1 and FF02::1
Multicast addresses of all nodes
FF01::1 and FF02::1
nodes Multicast addresses of all
FF01::2 and FF02::2
Solicited-node multicast routers
address corresponding to each FF02::1:FF35:7287 Solicited-node multicast
unicast address of the network FF02::1:FF00:1 address corresponding to each FF02::1:FF99:1285
adapter unicast address of the network FF02::1:FF00:2
adapter
Page 25 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
Service Process of IPv6 Unicast Addresses
⚫ Before sending IPv6 packets, an interface undergoes address configuration, DAD, and address
resolution. During this process, the Neighbor Discovery Protocol (NDP) plays an important role.
Similar to ARP requests in IPv4,
GUAs and LLAs are the most common ICMPv6 messages are used to
IPv6 unicast addresses on an DAD is similar to gratuitous ARP in IPv4 and is
used to detect address conflicts. generate the mappings between IPv6
interface. Multiple IPv6 addresses can addresses and data link layer
be configured on one interface. addresses (usually MAC addresses).
IPv6
Address Address data
DAD
configuration resolution forwarding
GUA LLA
Manual Manual
configuration configuration
Page 26 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
NDP
⚫ NDP is defined in RFC 2461, which was replaced by RFC 4861.
⚫ NDP uses ICMPv6 messages to implement its functions.
ICMPv6 messages used by NDP
Page 27 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
Dynamic Address Address
DAD
Configuration Resolution
DHCPv6 interaction
• Through DHCPv6 message exchange, the DHCPv6 server automatically configures IPv6 addresses/prefixes and other
network configuration parameters (such as DNS, NIS, and SNTP server addresses).
ICMPv6 RA
(My interface address prefix is 2000::/64.)
• The PC generates a unicast address based on the address prefix in the RA and the locally generated 64-bit interface
ID (for example, using EUI-64).
• Only IPv6 addresses can be obtained. Parameters such as NIS and SNTP server parameters cannot be obtained.
DHCPv6 or manual configuration is required to obtain other configuration information.
Page 28 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
Dynamic Address Address
DAD
Configuration Resolution
DAD
⚫ Regardless of how an IPv6 unicast address is configured, a host or router:
▫ Performs DAD through ICMPv6 messages.
ICMPv6 NS ICMPv6 NA
PC R1
1 2
New online Source 5489-98C8-1111 Source 5489-9850-2222 Already online
device Destination 3333-FF00-FFFF Destination 3333-0000-0001 device
Source :: Source 2001::FFFF
Destination FF02::1:FF00:FFFF Destination FF02::1
Target: 2001::FFFF
Target: 2001::FFFF
MAC 5489-9850-2222
3 [DUPLICATE]
Page 30 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
Dynamic Address Address
DAD
Configuration Resolution
Address Resolution
⚫ IPv6 uses ICMPv6 NS and NA messages to replace the address resolution function of ARP in IPv4.
2001::1/64 2001::2/64
5489-98C8-1111 5489-9850-2222
Requests the MAC address
corresponding to 2001::2/64.
PC 1 2 R1
Responds
Page 31 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
Contents
1. IPv6 Overview
Page 32 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
Basic IPv6 Configurations (1)
1. Enable IPv6.
[Huawei] ipv6
Enable the device to send and receive IPv6 unicast packets, including local IPv6 packets.
[Huawei-GigabitEthernet0/0/0] ipv6 enable
Enable IPv6 on the interface in the interface view.
2. Configure an LLA for the interface.
[Huawei-GigabitEthernet0/0/0] ipv6 address ipv6-address link-local
Page 33 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
Basic IPv6 Configurations (2)
4. Configure an IPv6 static route.
By default, a Huawei router's interfaces do not send ICMPv6 RA messages. In this situation, other devices on
the links connected to the interfaces cannot perform SLAAC.
To perform SLAAC, you need to manually enable the function of sending RA messages.
Page 34 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
Example: Configuring a Small IPv6 Network (1)
R3 1. Enable IPv6 globally and on related interfaces of R1, R2,
GE 0/0/0
Using DHCPv6 R3, and R4, and enable the interfaces to automatically
2002::1/64 generate LLAs. The following uses R1 configurations as an
GE 0/0/0
example.
GE 1/0/0
R2 2001::2/64 [R1]ipv6
GE 0/0/0
2001::1/64
[R1]interface GigabitEthernet 0/0/0
GE 0/0/1 R1 [R1-GigabitEthernet0/0/0]ipv6 enable
2003::1/64
[R1-GigabitEthernet0/0/0]ipv6 address auto link-local
GE 0/0/0
SLAAC
R4 2. Configure static IPv6 GUAs on the related interfaces of
IPv6 network
• Configuration Requirements
R1 and R2.
[R1]interface GigabitEthernet 0/0/0
▫ Connect R1 and R2 through interfaces with static IPv6
[R1-GigabitEthernet0/0/0]ipv6 address 2001::1 64
addresses.
▫ Configure R2 as a DHCPv6 server to assign a GUA to
GE 0/0/0 of R3. [R2]interface GigabitEthernet 1/0/0
[R2-GigabitEthernet1/0/0]ipv6 address 2001::2 64
▫ Enable R2 to send RA messages, and configure GE [R2-GigabitEthernet1/0/0]interface GigabitEthernet 0/0/0
0/0/0 of R4 to automatically perform SLAAC based on [R2-GigabitEthernet0/0/0]ipv6 address 2002::1 64
the RA messages sent by R2. [R2-GigabitEthernet0/0/0]interface GigabitEthernet 0/0/1
▫ Configure static routes to implement mutual access [R2-GigabitEthernet0/0/1]ipv6 address 2003::1 64
between the devices.
Page 35 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
Example: Configuring a Small IPv6 Network (2)
R3
GE 0/0/0 3. Configure R2 as a DHCPv6 server. Configure the related
Using DHCPv6
2002::1/64 interface of R3 to obtain a GUA using DHCPv6.
GE 0/0/0
Page 36 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
Example: Configuring a Small IPv6 Network (3)
R3
GE 0/0/0 4. Enable R2 to advertise RA messages. Enable R4 to
Using DHCPv6 obtain an address through SLAAC based on the RA
2002::1/64
GE 0/0/0 messages sent by R2.
GE 1/0/0
R2 2001::2/64
[R2]interface GigabitEthernet 0/0/1
GE 0/0/0
GE 0/0/1 2001::1/64 [R2-GigabitEthernet0/0/1]undo ipv6 nd ra halt
R1
2003::1/64
GE 0/0/0
SLAAC [R4]interface GigabitEthernet 0/0/0
R4
IPv6 network [R4-GigabitEthernet0/0/0]ipv6 address auto global
• Configuration Requirements
▫ Connect R1 and R2 through interfaces with static IPv6
addresses.
▫ Configure R2 as a DHCPv6 server to assign a GUA to
GE 0/0/0 of R3.
▫ Enable R2 to send RA messages, and configure GE
0/0/0 of R4 to automatically perform SLAAC based on
the RA messages sent by R2.
▫ Configure static routes to implement mutual access
between the devices.
Page 37 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
Example: Configuring a Small IPv6 Network (4)
R3
GE 0/0/0 5. Configure static routes on R4.
Using DHCPv6
2002::1/64
GE 0/0/0 [R4]ipv6 route-static 2001:: 64 2003::1
[R4]ipv6 route-static 2002:: 64 2003::1
GE 1/0/0
R2 2001::2/64 GE 0/0/0
GE 0/0/1 2001::1/64 6. Configure an aggregated static route on R1.
R1
2003::1/64
GE 0/0/0 [R1]ipv6 route-static 2002:: 15 2001::2
SLAAC
R4
IPv6 network
• Configuration Requirements 7. Configure a default route on R3.
▫ Connect R1 and R2 through interfaces with static IPv6
addresses. [R3]ipv6 route-static :: 0 2002::1
▫ Configure R2 as a DHCPv6 server to assign a GUA to
GE 0/0/0 of R3.
▫ Enable R2 to send RA messages, and configure GE
0/0/0 of R4 to automatically perform SLAAC based on
the RA messages sent by R2.
▫ Configure static routes to implement mutual access
between the devices.
Page 38 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
Quiz
1. What is the most abbreviated form of the IPv6 address
2001:0DB8:0000:0000:032A:0000:0000:2D70?
Page 39 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
Summary
A fixed 40-byte basic packet A basic header containing the Options field to
Packet format
header+variable-length extension headers support extended features
Address type Unicast, multicast, and anycast Unicast, multicast, and broadcast
Address
Static, DHCP, and SLAAC Static and DHCP
configuration
Address
ICMPv6 ARP
resolution
Page 40 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.
Thank You
www.huawei.com
Page 41 Copyright © 2020 Huawei Technologies Co., Ltd. All rights reserved.