7.6.1 IPv6 Protocol Review
7.6.1 IPv6 Protocol Review
In this lesson we're going to spend some time looking at IPv6. In order to
effectively troubleshoot IPv6 issues, you've got to have a really solid understanding
of how IPv6 is supposed to operate when it's functioning normally.
We've talked about IPv6 in great detail in other places in this course, so what we're
going to do here is simply focus on thedifferences between IPv6 and IPv4.
If you were to look at that in binary, FFFF would be composed ofsixteen 1s, a value
of 0 would be sixteen 0s. Any hexadecimal number in between would be a
combination of 0s and 1s, just like with a standard IPv4 address.
An IPv6 address is actually composed of two different parts, much the same way
that an IPv4 address is composed of two parts. Remember, with an IPv4 address,
we have a network portion of the address and we have a node portion of the
address, and this is defined by the subnet mask that's assigned to the IPv4 address.
It works in a very similar way with IPv6 addresses, but there are some differences.
Prefix 1:49-2:05
With IPv6 addresses, the prefix composes the first 64 bits of the address. The prefix
is equivalent to the network address of an IPv4 address. The prefix includes both
the network as well as the subnet address.
Interface ID 2:06-2:47
The last 64 bits, over here, is called the interface ID and it's equivalent to the node
address in an IPv4 address. In IPv6, the interface ID, is a unique address that's
assigned to a particularnetwork interface on a host.
One of the key things to remember with IPv6, however, is thefact that usually the
prefix will almost always be 64 bits long.That's not the case with IPv4, where the
length of a subnet mask can vary quite a bit. In IPv6 it's almost always 64 bits
long. In essence, remember that the first half of the address is network, the
prefix, while the last half of the address is the interface ID, or the node address.
Let's talk about global unicast addressing first. Global unicast addresses are
very similar to public IPv4 addresses. With IPv6, a given organization will use a
registered, globally unique prefix that all devices in their network will use. This
prefix is uniquethroughout the entire Internet.
Therefore, the global unicast addresses that are assigned to individual interfaces
within the network will be globally unique as well--unique throughout the entire
Internet.
The global routing prefix is assigned to an organization by anISP, and it's usually 48
bits long. Remember earlier, however, we said that the prefix on the IPv6 address is
almost always 64 bits long.
Yet we're saying here that the prefix that you get from the ISP is only 48 bits. That's
OK because what we do is use the remaining 16 bits in the prefix for subnetting,
and this is really beneficialbecause it allows an organization to define a very large
number of subnets within the organization's networks. You can create up to 2
^16 subnets within your organization, and that is a lot of subnets.
When you're designing an IPv6 network, because you have so many subnets to
work with, you shouldn't be stingy with them.When you're designing your IPv6
network, you should create separate IPv6 subnets for network segments that are
separated by routers, for your VLANs, as well as for your point-to-point WAN links.
As you can probably guess, all subnet IDs within the same organization must begin
with the same global routing prefix, but then will be uniquely identified using a
different value in the subnet portion of the prefix.
Unique Local Addresses 4:52-6:44
In addition to global unicast addresses, with IPv6 we also have the concept of
unique local addresses. Unique local addresses are similar to private IPv4
addresses, and they're normally used for networks that do not cross a public
network.
Because unique local addresses are not registered, they cannotbe used on a public
network without address translation. If you were using IPv4 private IP addresses,
you'd have to use networkaddress translation to translate them into registered IP
addresses. The same concept applies to unique local IPv6 addresses.
Unique local addresses use a special prefix. It begins with FC00,and it's seven bits
long. However, currently the eighth bit is always set to 1 to indicate that the address
is local, and not global. Thus any IPv6 addresses that you see that begin with FC or
FD are defined as unique local addresses.
Following the prefix, the next 40 bits are used for the global ID.This is where unique
local addresses are interesting. The global ID is generated randomly. The idea is
that we want to create a high probability of uniqueness on the entire Internet.
We begin a unique local address with FC00 or FD00. Then we have 40 additional
bits that are randomly generated to create the global ID. Then we have the last 16
bits in the prefix that we can use for subnetting, just as with global unicast
addresses. Of course, the remaining 64 bits are used for the interface ID, justas
with global unicast addressing.
A lot of folks get unique local and link-local addresses confusedbecause neither one
of these are used on a public network. The key thing to remember is that a unique
local address is routablewithin your organization. It won't be routable on the
Internet, but it is routable within your organization, a lot like a private IPv4 address.
A link-local address, however, is not routable at all. Link-local addresses are used
for automatic address configuration.They're used for neighbor discovery, and
they're also used for subnets that don't have any routers, so we don't need IP
addresses that are routable.
Link-local addresses begin with FE80, and this prefix is 10 bits long. It includes any
addresses actually beginning with FE8, FE9, FEA, or FEB. If you see an IPv6 address
that begins with any of these hexadecimal numbers, you automatically know
that those are link-local addresses.
Here's a key thing you need to remember: all IPv6 hosts have to have at least one
link-local address defined. Even if you're using global unicast addresses for your
IPv6 host, each IPv6 host will also have at least one link-local address assigned to it.
There's another very important thing you need to remember about NDP, and that is
the fact that it is used by your IPv6 host to discover the IPv6 and MAC addresses of
other interfaces on the network. Essentially, what NDP does is replace ARP, that
we're used to using on IPv4 networks. With IPv6 we don't use ARP anymore. NDP is
used instead.
The key thing to remember about NDP is the fact that it does not provide clients
with DNS server addressing information, nor can it provide any other IP
configuration information. The only thing that it can provide is the prefix and
the default gateway router address. That's it.
DHCPv6 11:23-11:39
Another option for IPv6 addressing is to use DHCP, just like we do with an IPv4
network. In order to do this with IPv6, we needto have an updated version of
DHCP. It's called DHCPv6.DHCPv6 can operate in two different modes that you see
here.
Obviously, you can't use stateless DHCPv6 all by itself. Usually what happens is we
implement stateless DHCPv6 in conjunction with some other addressing method,
most commonly stateless autoconfiguration.
The host then sends a neighbor solicitation message addressedto its own link-local
address that it just generated. The reason it does this is it wants to see if some
other host on the network is already using that address. We don't want to end
up with an address conflict.
Basically, what's happened is you have two hosts on the network that have the
same MAC address, and that's not good. You've got the resolve that before you can
continue.
If, on the other hand, that address is not in use, which should be the case, it doesn't
receive any NA messages from any other hosts, then the process will continue. The
next thing that happens is that the host will wait for an RA message from a router.
It does this so it can learn what the network prefix is. What it's doing is waiting for
the router to get around to sending RAmessages with the appropriate networking
information in it.
If that RA message is not received, then the client's going to take matters into its
own hands and it's going to send a Router Solicitation message (RS) out. That router
solicitation message isgoing to be addressed to all routers on the subnet using a
multicast address.
The router on that subnet should receive that multicast, and it should respond back
with an RA message with the appropriate addressing information. If the client does
not receive an RAmessage from a router, then it will attempt to use stateful DHCPv6
in order to get configuration information.
If, on the other hand, a router does respond with an RA message, then the host will
have some information that it needs in order to configure IPv6 on it. The RA
message should contain how the IPv6 address is to be configured.
There are several different possible combinations. The RA message could tell the
host that it needs to obtain the interfaceID, subnet prefix, default gateway, and any
other IP configuration information from a DHCPv6 server.
If this is the case, then the client will send out a DHCPv6 request message and try to
contact a DHCPv6 server to get an IP address.
On the other hand, the RA message could also say that statelessautoconfiguration
is to be used. In this case, the client's going to get the subnet prefix and default
gateway address from the RAmessage itself. Then it will try to set its interface ID
automatically. It can also then try to get the DNS server's IP address from a DHCPv6
server.
Summary 17:15-17:32
That's it for this lesson. In this lesson we talked about the IPv6 protocol. We talked
about how IPv6 addresses are constructed.We talked about how IPv6 addresses
can be assigned tonetwork hosts, network routers. Then we ended this lesson
bytalking about how IPv6 routing can be enabled on our network routers.