All rights reserved.BSCI 2 Học viện mạng Bách Khoa - www.bkacad.com Objectives Explain the need for IPv6 address space.. All rights reserved.BSCI 4 Học viện mạng Bách Khoa - www.bkac
Trang 1BSCI Module 8 Lessons 1 and 2
Explaining IPv6
IPv6 Addressing
Trang 2© 2008 Cisco Systems, Inc All rights reserved.
BSCI
2
Học viện mạng Bách Khoa - www.bkacad.com
Objectives
Explain the need for IPv6 address space
Explain how IPv6 deals with the limitations of IPv4
Describe the features of IPv6 addressing
Describe the structure of IPv6 headers in terms of
format and extension headers
Show how an IPv6 address is represented
Describe the three address types used in IPv6
Trang 4© 2008 Cisco Systems, Inc All rights reserved.
BSCI
4
Học viện mạng Bách Khoa - www.bkacad.com
Why Do We Need a Larger Address
Space?
Internet population
– Approximately 973 million users in November 2005
– Emerging population and geopolitical and address space
– 1 billion automobiles forecast for 2008
– Internet access in planes – Example: Lufthansa
Consumer devices
– Sony mandated that all its products be IPv6-enabled by 2005
– Billions of home and industrial appliances
Trang 5IP Address Allocation History
In 1981, IPv4 Protocol was published In 1985, about 1/16
of the total IPv4 address space was in use By mid-2001,
about 2/3 of the total IPv4 address space was in use
Trang 6© 2008 Cisco Systems, Inc All rights reserved.
BSCI
6
Học viện mạng Bách Khoa - www.bkacad.com
IPv6 Advanced Features
Larger address space
Global reachability and
No broadcasts
No checksums
Extension headers
Flow labels
Trang 7IPv6 Advanced Features (Cont.)
Mobility and security
Trang 8© 2008 Cisco Systems, Inc All rights reserved.
BSCI
8
Học viện mạng Bách Khoa - www.bkacad.com
IPv4
32 bits or 4 bytes long
• 4,200,000,000 possible addressable nodes
IPv6
128 bits or 16 bytes: four times the bits of IPv4
• 3.4 * 10 38 possible addressable nodes
• 340,282,366,920,938,463,374,607,432,768,211,456
• 5 * 10 28 addresses per person
Larger Address Space
Trang 9Larger Address Space Enables Address
Trang 10© 2008 Cisco Systems, Inc All rights reserved.
2 How many bits are included in an IPv6 address?
3 How will IPv6 enable smaller routing tables in Internet
routers?
4 Why is NAT not a requirement for IPv6?
Trang 11Addressing
Trang 12© 2008 Cisco Systems, Inc All rights reserved.
BSCI
12
Học viện mạng Bách Khoa - www.bkacad.com
Simple and Efficient Header
A simpler and more efficient header means:
64-bit aligned fields and fewer fields
Hardware-based, efficient processing
Improved routing efficiency and performance
Faster forwarding rate with better scalability
Trang 13MTU Issues
Minimum link MTU for IPv6 is 1280 octets
(vs 68 octets for IPv4)
–On links with MTU < 1280, link-specific fragmentation and reassembly must be used
Implementations are expected to perform path MTU
discovery to send packets bigger than 1280
Trang 14© 2008 Cisco Systems, Inc All rights reserved.
BSCI
14
Học viện mạng Bách Khoa - www.bkacad.com
IPv4 and IPv6 Header Comparison
Fragment Offset Flags
Total Length
Type of Service IHL
Padding Options
Destination Address Source Address
Header Checksum Protocol
Flow Label
Traffic Class
Trang 15IPv6 Extension Headers
Simpler and more efficient header means:
IPv6 has extension headers
IPv6 enables faster forwarding rate and end nodes
processing
Trang 16© 2008 Cisco Systems, Inc All rights reserved.
BSCI
16
Học viện mạng Bách Khoa - www.bkacad.com
IPv6 Address Representation
x:x:x:x:x:x:x:x, where x is a 16-bit hexadecimal field
Leading zeros in a field are optional:
–2031 :0: 130F :0:0:9C0: 876A:130B
Successive fields of 0 can be represented as ::, but only
once per address
Examples:
2031:0000:130F:0000:0000:09C0:876A:130B 2031:0:130f :: 9c0:876a:130b
FF01:0:0:0:0:0:0:1 >>> FF01::1 0:0:0:0:0:0:0:1 >>> ::1
0:0:0:0:0:0:0:0 >>> ::
Trang 17IPv6—Addressing Model
Addresses are assigned to interfaces
–Change from IPv4 mode:
Interface ―expected‖ to have multiple addresses
Addresses have scope
–Link Local –Unique Local –Global
Addresses have lifetime
–Valid and preferred lifetime
Link Local Unique Local
Global
Trang 18© 2008 Cisco Systems, Inc All rights reserved.
BSCI
18
IPv6 Address Types
Học viện mạng Bách Khoa - www.bkacad.com
Trang 19IPv6 Address Types
Unicast
– Address is for a single interface.
– IPv6 has several types (for example, global and IPv4 mapped).
Multicast
– One-to-many
– Enables more efficient use of the network
– Uses a larger address range
Anycast
– One-to-nearest (allocated from unicast address space).
– Multiple devices share the same address.
– Source devices send packets to anycast address.
– Routers decide on closest device to reach that destination.
– Suitable for load balancing and content delivery services.
Trang 20© 2008 Cisco Systems, Inc All rights reserved.
BSCI
20
Link-Local Address
The unicast link-local address is scoped and is used only
between nodes connected on the same local link The local address is used by several IPv6 mechanisms, such as Neighbor Discovery Protocol (NDP).
link- When an IPv6 stack is enabled on a node, one link-local address
is automatically assigned to each interface of the node at boot time.
Học viện mạng Bách Khoa - www.bkacad.com
Trang 21Site-Local Address
A site-local address is another unicast scoped
address to be used only within a site Site-localaddresses are not enabled by default on nodes likelink-local addresses, meaning that they must beassigned
Trang 22© 2008 Cisco Systems, Inc All rights reserved.
BSCI
22
Aggregatable Global Unicast Address
Aggregatable global unicast addresses are IPv6
addresses used for the generic IPv6 traffic on the IPv6Internet
Each aggregatable global unicast IPv6 address has
three parts as below:
Học viện mạng Bách Khoa - www.bkacad.com
Trang 23Unicast Prefixes
Trang 24© 2008 Cisco Systems, Inc All rights reserved.
BSCI
24
Multicast Address
Multicast is a technique in which a source node sends a
single packet to multiple destinations simultaneously (one-to-many)
Học viện mạng Bách Khoa - www.bkacad.com
Trang 25Multicast Address
Trang 26© 2008 Cisco Systems, Inc All rights reserved.
BSCI
26
Multicast Assigned Address
Học viện mạng Bách Khoa - www.bkacad.com
Trang 27Solicited-Node Multicast Address
The second type of multicast addressing is solicited-node
multicast addressing For each unicast and anycast address configured on an interface of a node or router, a corresponding solicited-node multicast address is automatically enabled The solicited-node multicast address is scoped to the local link.
The solicited-node multicast address consists of the prefix FF02:
:1:FF00:0000/104 and the low-order 24-bit of the unicast or anycast address.
Trang 28© 2008 Cisco Systems, Inc All rights reserved.
BSCI
28
Anycast Address
Unicast is a method used by a source node to send a
packet to one destination (one-to-one), multicast is used for one-to-many communication, and anycast
is used for one-to-nearest communication
Anycast addresses use aggregatable global unicast
addresses They can also use site-local or link-localaddresses Note that it is impossible to distinguish ananycast address from a unicast address
Học viện mạng Bách Khoa - www.bkacad.com
Trang 29Loopback Address
Similar to the IPv4 protocol , each device has one
loopback address, which is used by the node itself
Trang 30© 2008 Cisco Systems, Inc All rights reserved.
BSCI
30
Unspecified Address
An unspecified address is a unicast address not
assigned to any interface It indicates the absence of anaddress and is used for special purposes
Học viện mạng Bách Khoa - www.bkacad.com
Trang 31Required IPv6 Addresses for Nodes
As soon as the node is IPv6-enabled, i t has one
link-local address per interface, one loopback address, and
al l -nodes multicast addresses FF01: :1 and FF02: :1
Trang 32© 2008 Cisco Systems, Inc All rights reserved.
BSCI
32
Required IPv6 Addresses for Routers
Học viện mạng Bách Khoa - www.bkacad.com
Trang 33 IPv6 is a powerful enhancement to IPv4 Features that
offer functional improvement include a larger address space, simplified header, and mobility and security
IPv6 increases the number of address bits by a factor
of four, from 32 to 128
The IPv6 header has 40 octets and is simpler and more
efficient than the IPv4 header
IPv6 addresses use 16-bit hexadecimal number fields
separated by colons (:) to represent the 128-bit addressing format
The three types of IPv6 addresses are unicast,
multicast, and anycast
Trang 34© 2008 Cisco Systems, Inc All rights reserved Cisco Confidential
BSCI Module 8 Lesson 3
Dynamic IPv6 Address
Trang 35 Explain how Ethernet MAC addresses can be used to
generate a 64-bit interface ID for the host
Explain how IPv6 improves multicast
Describe how IPv6 simplifies mobile IP connections
Trang 36© 2008 Cisco Systems, Inc All rights reserved.
BSCI
36
Học viện mạng Bách Khoa - www.bkacad.com
Aggregatable Global Unicast Addresses
Aggregatable Global Unicast Addresses Are:
Addresses for generic use of IPv6
Structured as a hierarchy to keep the aggregation
001
64 Bits
3 45 Bits 16 Bits
Provider Site Host
Global Routing Prefix Subnet Interface ID
Trang 37IPv6 Interface ID
Cisco uses the extended universal identifier (EUI)-64
format to do stateless autoconfiguration
This format expands the 48-bit MAC address to 64 bits
by inserting ―FFFE‖ into the middle 16 bits
To make sure that the chosen address is from a unique
Ethernet MAC address, the universal/local (U/L bit) is set to 1 for global scope (0 for local scope)
Trang 38© 2008 Cisco Systems, Inc All rights reserved.
BSCI
38
Học viện mạng Bách Khoa - www.bkacad.com
MAC Address to EUI-64
Trang 39Link-Local Address
devices (similar to ARP but at Layer 3)
Remaining 54 bits
Trang 40© 2008 Cisco Systems, Inc All rights reserved.
Trang 41Examples of Permanent Multicast
Addresses
Trang 42© 2008 Cisco Systems, Inc All rights reserved.
BSCI
42
Học viện mạng Bách Khoa - www.bkacad.com
Solicited-Node Multicast Address
Used in neighbor solicitation messages
Multicast address with a link-local scope
Solicited-node multicast consists of prefix + lower 24
bits from unicast, FF02::1:FF:
Trang 43R1#sh ipv6 int e0
Ethernet0 is up, line protocol is up
IPv6 is enabled, link-local address is FE80::200:CFF:FE3A:8B18
No global unicast address is configured
Joined group address(es):
FF02::1
FF02::2
FF02::1:FF 3A:8B18
MTU is 1500 bytes
ICMP error messages limited to one every 100 milliseconds
ICMP redirects are enabled
ND DAD is enabled, number of DAD attempts: 1
ND reachable time is 30000 milliseconds
ND advertised reachable time is 0 milliseconds
ND advertised retransmit interval is 0 milliseconds
ND router advertisements are sent every 200 seconds
ND router advertisements live for 1800 seconds
Hosts use stateless autoconfig for addresses.
R1#
Router Interface
Solicited-Node Multicast Address
Trang 44© 2008 Cisco Systems, Inc All rights reserved.
BSCI
44
Học viện mạng Bách Khoa - www.bkacad.com
Anycast
An IPv6 anycast address is a global unicast address that
is assigned to more than one interface
packet to one destination (one-to-one), multicast is used
anycast address of the nearest node member of the
anycast group
Trang 45 Internet Control Message Protocol for IPv6 (ICMPv6)
Trang 46© 2008 Cisco Systems, Inc All rights reserved.
BSCI
46
(ICMPv6)
ICMP for IPv6 (ICMPv6), as defined in RFC 2463, handles
messages supported by ICMP for IPv4 (ICMPv4) and has additional messages for the specific operation of the IPv6 protocol
ICMPv6 handles the same basic errors and informational
messages as ICMPv4 such as Destination Unreachable, Packet Too Big, Time Exceeded, Echo Request, and Echo Reply.
Học viện mạng Bách Khoa - www.bkacad.com
Trang 47Internet Control Message Protocol for
IPv6 (ICMPv6)
In IPv6, several mechanisms and functional i ties of
the protocol use ICMPv6 messages:
– Replacement of the Address Resolution Protocol(ARP) A mechanism used on local-link scope toreplace ARP in IPv4
Trang 48© 2008 Cisco Systems, Inc All rights reserved.
BSCI
48
Path MTU Discovery (PMTUD) for IPv6
The main goal of PMTUD is finding out the MTU value
along a path when a packet is sent to a destination to
avoid fragmentation
As defined in RFC 1981, Path MTU Discovery for IP
version 6, PMTUD for IPv6 uses ICMPv6 error message Type 2, Packet Too Big.
Học viện mạng Bách Khoa - www.bkacad.com
Trang 49Neighbor Discovery Protocol (NDP)
Neighbor Discovery Protocol (NDP), as defined in
RFC 2461, Neighbor Discovery for IP Version 6 (IPv6), is a key protocol of IPv6
Trang 50© 2008 Cisco Systems, Inc All rights reserved.
BSCI
50
Replacement of ARP Protocol
In IPv6, the determination of nodes’ link-layer
addresses uses a combination of neighbor solicitation
advertisement messages (ICMPv6 Type 136), and
:1:FFxx:xxxx)
Học viện mạng Bách Khoa - www.bkacad.com
Trang 51Stateless Autoconfiguration
As defined in RFC 2462, IPv6 Stateless Address
Autoconfiguration, stateless autoconfiguration is one of the most interesting and useful new feature
of IPv6
This section describes the mechanisms involved in
stateless autoconfiguration Mechanisms are asfollows:
– Prefix advertisement— Advertises prefixes and parameters
on a local l ink The prefix advertisement information is used by IPv6 nodes to configure thei r IPv6 addresses.
–DAD— Ensures that each IPv6 address configured on an interface using stateless autoconfiguration is unique on the l ink local scope.
–Prefix renumbering— Advertises modi fied prefixes or new prefixes and parameters on the local l ink to renumber a prefix
Trang 52© 2008 Cisco Systems, Inc All rights reserved.
BSCI
52
Prefix Advertisement
Prefix advertisement is the initial mechanism
involved in stateless autoconfiguration. The prefixadvertisement mechanism uses router advertisementmessages (ICMPv6 Type 134) and all -nodes multicastaddress FF02: :1 Router advertisement messages aresent periodically on the local link to the all -nodes multicast address
Học viện mạng Bách Khoa - www.bkacad.com
Trang 53Prefix Advertisement
Trang 54© 2008 Cisco Systems, Inc All rights reserved.
BSCI
54
Requesting Router Advertisement Using Router Solicitation
When nodes boot, any node can send a router solicitation
message (ICMPv6 Type 133) to the all -routers multicast address FF02: :2 on the local link When the router solicitation message is received, a router on the local link responds with a router advertisement message (ICMP Type 134) using the al l - nodes multicast address FF02: :1.
Học viện mạng Bách Khoa - www.bkacad.com
Trang 55 DAD uses neighbor solicitation messages (ICMPv6
Type 135) and solicited-node multicast addresses toperform this task
Trang 56© 2008 Cisco Systems, Inc All rights reserved.
BSCI
56
How Prefix Renumbering Works
Prefix renumbering is performed by routers already
advertising prefixes on local links This mechanismuses the same ICMPv6 messages and multicastaddresses as the prefix advertisement mechanism
Học viện mạng Bách Khoa - www.bkacad.com
Trang 57Router Redirection
Router redirection is an NDP mechanism in IPv6
Routers use ICMPv6 redirection messages to informnodes on the l ink that a better router exists on the l ink
to forward packets
Trang 58© 2008 Cisco Systems, Inc All rights reserved.
Trang 59Stateless Autoconfiguration
A router sends network information to all the nodes on the local
link
A host can autoconfigure itself by appending its IPv6 interface
identifier (64-bit format) to the local link prefix (64 bits)
The result is a full 128-bit address that is usable and guaranteed to