I am doing a presentation on IPv6, at my company’s TechFest. This is a day event with keynote speakers, and break out sessions. The purpose of TechFest is to give the developers and engineers a break from their day to day activity and get a view of what’s going on around the company and in the industry.
In this article, I’m copy/pasting my slide deck, and stripping out the company specific information, making this a generic Introduction to IPv6.
The Agenda for Today:
What is IPv6? (~10 minutes)
DNS (~10 minutes)
Getting Started (~10 minutes)
Web Application Development (~10 Minutes)
First Session – What is IPv6?
Quick History of IPv6
Early ’90s – forecasted that IPv4 would run out
Mid 90s – IPv6 specification arrived
IPv6 surge, then, late 2002: Dotcom meltdown
IP consumption rate dropped to 16 million per year
Appeared we had decades left
Since 2005 – rate jump to 160 million per year
When will IPv4 be depleted?
Run by APNIC Chief Scientist, Geoff Huston
Projected IANA Unallocated Address Pool Exhaustion: 22-Apr-2011
Projected RIR Unallocated Address Pool Exhaustion: 12-Jul-2012
Are you ready!?
Represented by a 128-bit integer!
2^128 = 3.4 x 10^38 (340 undecillion)
4 billion ^ 4
IPv6 Features – More Than Just Larger Address Space
New Header Format
Large Address Space
Hierarchical Addressing and Routing Infrastructure
Stateless and Stateful Address Configuration
Built in Security
Better Support for Prioritized Delivery
New Protocol for Neighboring Node Interaction
Extensibility – Extension headers
IPv6 Address Syntax
Divided along 16-bit boundaries.
There are eight 16-bit blocks, example:
0010000000000001 0000110110111000 0000000000000000 0010111100111011 0000001010101010 0000000011111111 1111111000101000 1001110001011010
Each block converted to hexadecimal, delimited with colons.
Bitmasks used, like in IPv4, up to /128.
Dotted decimal representation of network prefixes (aka 255.255.255.0) are NOT used in IPv6.
/8 =~ 16 million
/16 = 65,536
/24 = 256
/32 = 1 IP
/16 =~ 5 undecillion
/32 =~ 79 nonillion
/48 =~ 1 octillion
/64 =~ 18 quintillion
/96 =~ 4 billion
/112 =~ 65 thousand
/128 = 1 IP
IPv6 Short Notation
Short notation – drop preceding 0s and use :: once only for a string of zeros.
For example:ipv6.google.com = 2001:4860:0000:2001:0000:0000:0000:0068 = 2001:4860:0:2001::68
Short notation is the most common way to display an IPv6 address – and expected.
IPv4-mapped address notation
::FFFF:0:0/96 is reserved to store IPv4 addresses in IPv6 format.
Often displayed as ::ffff:192.0.2.128
Example use: ssh root@::ffff:192.0.2.128
This is how IPv6 talks to IPv4
IPv6 Unicast Addresses
Global – 2000::/3. (2000 – 27FF). The assigned subnets from the registries, like ARIN.
Link Local – FE80::/64. Self assigned. Never routes outside of local network.
:: (like the IPv4 0.0.0.0 address)
::1(like the IPv4 127.0.0.1 address)
Next Session – IPv6 DNS
DNS – Changes to Support IPv6
RFC 1886, entitled IPv6 DNS Extensions
AAAA (pronounced quad-A) – like A records, but to story IPv6 IPs
Reverse DNS – New Reverse Resolution Hierarchy (rDNS)
Changes To Query Types And Resolution Procedure
DNS Software, IPv6
Currently, most DNS servers support AAAA and IP6.ARPA (reverse DNS)
BIND 9 and 8
(But, not all support IPv6 Network stack!)
A and AAAA Records
[snip of bind zone file]
IN A 184.108.40.206
IN AAAA 2607:f208:0:100::102
ns1 IN A 220.127.116.11
ns1 IN AAAA 2607:f208:0:100::102
www IN A 18.104.22.168
www IN AAAA 2607:f208:0:100::102
ftp IN A 22.214.171.124
ftp IN AAAA 2607:f208:0:100::102
mail IN A 126.96.36.199
mail IN AAAA 2607:f208:0:100::102
Notice that it’s common to setup an A and a AAAA record for each service that you provide.
Be weary of running services on dual stack, though. Example: smtp and RBL blacklists. IPv6 is uncharted territory.
DNS, IPv6, Problem of Name Space Fragmentation
Name servers may run on 3 network stacks.
IPv6 only (common in the future)
IPv4 only (common today)
Dual-Stack (Ideal – this is where we want to be)
Imagine I’m an IPv4-only caching name server.
Doesn’t mean I can’t response with AAAA records, just that I don’t have access to the IPv6 Internet.
What if an authoritative name server for a zone is only available over IPv6? I can’t get to it!
DNS root servers and IPv6
On Feb 4 2008, 6 of 13 root name servers were updated with IPv6 Addresses.
Why is this important? (Hint: See “Problem of Name Space Fragmentation” above)
IPv6 DNS – Glue Records (Host Summary)
Glue records for domain Name Servers
Glue records are required when name servers for a domain is self-serving.
Example: if ns1.ipv6poc.com is the name server for ipv6poc.com – its self serving, therefore registrar must store the ip with the nameserver record.
Registrars should allow for both IPv4 and IPv6 glue records.
Go Daddy has added IPv6 Support for this. It’s available in Domain Center, under the “Host Summary” section of a domain. Way to go Go Daddy!
Next Session – Getting Started
How can you get started on IPv6 today?
Think of the Internet as having these network stacks:
Dual stack (both IPv4 and IPv6) – you want this
6to4 (pseudo IPv6) – yuck, yuck, yuck – can only reach other 6to4 addresses. Disregard.
If your ISP doesn’t offer dual stack, what can you do?
IPv6 Tunnel Brokers
Go6.net – Gateway6 – easiest way to connect your laptop or desktop.
Hurricane Electric (HE) – professional, good forum support, my favorite. www.tunnelbroker.net
SixXS – Exercise caution with SixXS, which is a small company that doesn’t have the most professional reputation.
Linksys WRT54G v2
Firmware source code released to satisfy the obligations of the GNU GPL.
Can load openwrt, a Linux based firmware that supports IPv6.
Only works on version 4.0 and below. Recommend 2.0 or 2.1.
Works with HE – turn your home network into an IPv6 network.
In the future
SOHO routers that support IPv6 out of the box.
/56 at home, provided by ISP – approx. 2 years out for Cox. ComCast in 3-6 months!
We have a dedicated hosting server with IPv6 routed to it.
Glue Record for ipv6poc.com
BIND on v4 and v6, with A and AAAA records
Apache on dual stack – www.ipv6poc.com will show your v4 or v6 IP.
Next Session – Web Application Development
IPv6 Application Programming Dilemmas
IPv6 Network Stack
Dealing with IPv6 addresses within your application
The Integrated v4/v6 Dual Stack
Linux systems, Vista, and Windows Server ’08 have integrated v4/v6 stacks.
The OS will do the underlying plumbing – will synthesize an IPv4-mapped address when needed.
IIS/Apache and PHP/.NET
IIS and Apache can listen on IPv4, IPv6, or dual stack. Work done by the OS, IIS and Apache take advantage.
Socket connections to IPv6 destinations considerations:
Does the library you’re using support IPv6 addresses?
If you use a hostname, does the library know how to query DNS for AAAA records?
IPv6 Port Separator Notation Issue
You’re used to “:” as the v4 port separator10.0.0.1:80
Commonly Accepted v6 Notation is to enclose the IP in braces[2001:4860:0:2001::68]:80
May be used in an HTTP address like thishttp://[2001:4860:0:2001::68]:80/
Your log parsing programs, i.e. regular expressions, may need to be adjusted.
When parsing log files, you may start seeing IPv4 addresses appear as IPv4-Mapped Addresses, like this: ::ffff:192.0.2.128
Again, parsing/regex may need to be adjusted for this.
The IPv6 Data Type Dilemma
IPv4 – 32-bit integer will store any IPv4 IP.
IPv6 – Typically there are not any 128-bit data types in our programming languages capable of natively storing an IPv6.
Audience Participation with Storing IPv6
What’s the best way to store IPv6 addresses?
What considerations are there when picking a method?
IPv6 Compatible Database Systems
PostgreSQL – compatible with IPv6 network stack. Has IPv6 compatible data types and built in functions.
MS SQL Server 2005 with SNI, the new SQL Server network library, supports IPv6 network stack. No native IPv6 compatible data types or methods.
Oracle – Some early talk in 2003 about supporting IPv6, then some talk during 10g days about having it in 11g, that didn’t happen either. No network stack, no data types.
MySQL – server and client not compatible with IPv6 network stack. No natively compatible data types. (slated in part in version 6.0, coming later)
Suggested Course Of Action
Transit – route global IPv6 addresses to networks
AAAA for DNS
DNS on IPv6 – dual stack
www.[your_domain].com – dual stack