Sub topic 1
Why IPv6 Exists
Prerequisites
This chapter assumes basic IPv4 addressing, hexadecimal notation, CIDR prefix lengths, and the roles of switches, routers, and default gateways.
Why IPv6 Exists
IPv4 uses 32-bit addresses, providing about 4.3 billion possible values. The growth of the internet, cloud services, and connected devices made this space too small. IPv6 uses 128-bit addresses, providing a vastly larger address space.
IPv6 also reduces dependence on network address translation (NAT), supports automatic configuration, and uses multicast instead of broadcast. IPv4 and IPv6 commonly operate together through dual stack, tunneling, or translation.
Anatomy of an IPv6 Address
An IPv6 address contains eight groups of 16 bits. Each group is written as up to four hexadecimal digits and separated by colons:
2001:0db8:0000:0000:0000:ff00:0042:8329
The address has a network prefix and an interface identifier. The prefix identifies the network. The interface identifier identifies an interface on that network.
Writing and Compressing Addresses
You can remove leading zeros from any group:
2001:0db8:0000:0000:0000:ff00:0042:8329 becomes 2001:db8:0:0:0:ff00:42:8329.
A consecutive run of all-zero groups can become ::. Use this replacement only once:
2001:db8:0:0:0:ff00:42:8329 becomes 2001:db8::ff00:42:8329.
When expanding ::, insert enough zero groups to restore eight groups.
Prefixes and Prefix Length
A prefix length tells how many leading bits identify the network. For example, 2001:db8:1234:5::/64 has a 64-bit network prefix and a 64-bit interface portion. IPv6 networks commonly use /64 for host subnets. The prefix is not the same as the textual number of groups in every possible design, but /64 divides the address evenly.
Unicast, Multicast, and Anycast
| Type | Meaning | Common prefix or example |
|---|---|---|
| Unicast | One interface receives the packet | `2000::/3` global unicast |
| Multicast | A group of interfaces receives the packet | `ff00::/8` |
| Anycast | The nearest member of a shared address receives the packet | Assigned from unicast space |
IPv6 has no broadcast address. Multicast provides group delivery instead. Link-local addresses use fe80::/10, while unique local addresses use fc00::/7.
Exercise
How do you expand 2001:db8::1 to eight IPv6 groups?
Show answer
Expand it to 2001:0db8:0000:0000:0000:0000:0000:0001.