IPv6: The Programmer's View
Written by Harry Fairhead   
Friday, 03 June 2011

June 8th is IPv6 day and it's a good time to look a the challenges of changing the way the net works.


With hindsight it is obvious tht 32-bit addressing wasn't going to be sufficient to map all of the world's computing devices onto the Internet. However back in 1977, 2^32 or just over 4.2 billion addresses sounded like a big number and in many ways it still is but compared to the estimated world  population of around 7 billion it doesn't look adequate.

Of course the argument is that with the growth of the Internet of Things (IoT) you need many times the number of addresses that IPv4 offers. There is an argument that this isn't the case and IPv4 has more than enough addresses if they are all used efficiently but in the main this argument has been lost.

IPv6 uses 128 bit addresses and this provides over 340 billion, billion, billion, billion addresses, i.e. enough for each person on the planet to have a few billion IP addresses. Clearly there would have to be some major and radical change in the way that we  work to exhaust that supply.

However, things are not quite as simple as the huge number of addresses would suggest. The subnet size of an IPv6 allocation is fixed to 64 bits - that is the host address, i.e. the part that is routed on the public internet is also 64 bits. What this means it is that a local IPv6 network has more addresses that the entire IPv4 address space.


Come the great day we are all using IPv6 there are no problems of connectivity. Every server would have an IPv6 address which clients, with there own fixed IPv6 adrress looked up using DNS in the usual way. However, reaching this utopia is a long struggle.

The key points are that a server with only an IPv6 address cannot be accessed by an IPv4 using client. What will happen in the future is that the Internet will break up into small groups of IPv6 using machines. These groups will be connected together by the IPv4 infrastructure using tunnelling, i.e. IPv6 packets as payloads of IPv4 packets. 

What all this means is that servers with dual IPv4 and IPv6 addresses will be accessible to all.

Servers that only have IPv6 addresses will only be accessible to IPv6 enabled clients. However, IPv6 to IPv6 connections should work even if there is no physical path between the server and client that supports IPv6 all the way.

A server that has only an IPv4 address will also be accessible to all as iPv6 clients can access IPv4 servers.

You can see why there is little pressure for existing servers to switch to IPv6-only operation. Until there are a lot of IPv6 clients they would be effectively cut off from their user base.

At the moment tehre are only 0.28%  IPv6 natively connected Internet users. You can see an up-to-date chart of IPv6 usage at


You can see that there has been an upturn in the total support for IPv6 since about the start of 2010 which is when the news that we were running out of IPv4 addresses first started to make headlines. However even though they are increasing the figures aren't impressive.

IPv6 day

So wjhat is IPv6 day all about?

And what is the big "trial"?

To be honest it is mostly a publicity stunt and an awareness raising operation. Some websites that don't already offer an IPv6 connection will be turning one on for you to use - if you have IPv6 and most clients don't.

Sites like Google have been offering IPv6 access for some time so on the day there will effectively be no change.IPv6 users mostly continue to access the servers via IPv6 and the majority of us who only have IPv4 connectivity will continue to use the IPv4 servers.

If you would like to try to see if you have IPv6 connectivity before the big day see if you can access:


If you do have IPv6 access you might like to check that you can access the equivalent IPv4 site:


The completely crazy thing about IPv6 day is that on the next day most sites are planning to turn it off again! If IPv6 is to be the way to go then it should be left switched on so that we can all get used to it.

What next

The big question is what can we do to move to IPv6?

In most cases the answer is just sit and wait.

The fact of the matter is that most connections to the Internet are via ISPs or via hosting companies. In this case very little seems to be happening. Simply take a trip to your ISP or hosting companies website and try looking up IPv6 in the help or knowledge base and you wil most likely come away empty handed.

Most companies are simply not saying anything about IPv6 because their connection is IPv4 and they don't want to create an isolated IPv6 cluster in the middle of an IPv4 sea. This isn't unreasonable and for IPv6 action you are most likely going to have to wait until IPv6 spreads itself though the infrastructure.

Is it really necesary?

Obviously IPv6 is a good thing. As well as a bigger address space it also has lots of nice new features that will make the Internet better - but in the future.

What comes as a bit of a shock is that we have run out of IPv4 addresses not because of some technological barrier but because of missuse of resources.

The first thing to say is that many IP addresses are simply not used. Companies acquired large blocks of IP addresses and simply horded them as a scarce resource. 

Even if a company is using their IP addresses they problably don't need to. There are various technologies that allow IP addresses to be shared. The only type of machine that needs a fixed unsharable IP address is a server and there are even exceptions to this rule - for example multiple web sites can be hosted with the same IP address.

The best known technology for sharing IP addresses is dynamic allocation. In this case users are assigned an IP address only when they are connected. Of course more and more users are always connected so this is becoming and increasingly useless method of reusing addresses.

The best method of sharing IP addresses is to use NAT, Network Address Translation. This uses the 16-bit port number to extend the IP address. All of the users connected to the internet via a single NAT router can share the same fixed IP address and are identified by the port number they are allocated making it possible for around 32,000 users to share the same IP address. Currently NAT is mostly used in private networks that connect via a router and an ISP who allocates a single fixed or dynamic IP addrees. A huge number of IP addresses could be freedu by ISP adopting NAT to connect all fo their customers. Each customer could in turn run a NAT router and so support even more users.

In practice this works and you can even do things that you might think would need a fixed IP address such as use VPNs - as long as the other end has a fixed or known dynamic address. It is a little strange at first working with a NAT based ISP connection in that you simply don't have a public IP address at any time just the IP address that all fo the other clients use.

However, if you are not trying to run a server over the connection it works and you have the added advantage that you are safe from external attack because you have no public presence on the Internet - i.e. you are behind a perfect incoming firewall.

No doubt NAT-based ISP connections will be on the increase as it becomes harder to acquire any new IPv4 addresses. It is also obvious that few are going to voluntary give up IPv4 address that they own even if they no longer use them. However many might be induced to sell them on at a profit.

Such is the shadowy world of the Internet that has run out of workable addresses.

Roll on IPv6 and the utopia it represents where everything can have its own unique fixed IP address.

Last Updated ( Friday, 03 June 2011 )