Setting up an IPv6 tunnel (was: Re: static IP & DHCP problems on LAN)

Karl Auer kauer at biplane.com.au
Wed Mar 13 00:43:51 UTC 2013


On Tue, 2013-03-12 at 16:24 +0000, Colin Law wrote:
> On 12 March 2013 16:08, Karl Auer <kauer at biplane.com.au> wrote:
> > That is how the tunneling works with singleton tunnels. If you get a
> > prefixed tunnel, then you can run a router advertiser in your network
> > advertising the prefix (or some part of it) and your whole network will
> > autoconfigure itself with IPv6 addresses. It is seriously cool the first
> > time this happens.
> 
> Would I not need an ipv6 aware router to do this?

Yes and no. What you are doing is turning a Linux box into a router. You
install and run a program called radvd on the same host as the tunnel,
configuring it with the prefixes you want to advertise. Hosts
autoconfigure themselves based on those prefixes, and route (first hop)
through the radvd host to the IPv6 Internet across the tunnel.

Your CPE (your router/modem, such as your Netgear) is not involved in
IPv6 at all. It's forwarding IPv4 packets that *contain* IPv6 packets,
but it doesn't know anything about that content.

radvd is not needed for a singleton tunnel, so you can start by getting
just one host onto the IPv6 Internet, then move on to experiment with
prefixes. Or you can experiment with radvd *without* a tunnel, and just
get IPv6 happening on your network, without IPv6 Internet access. Works
a treat.

> Probably neither am I.  In the previous thread the suggestion was that
> by using ipv6 tunnelling one could avoid the requirement for fixed ip
> addresses on the LAN.  However in order to communicate between
> machines on the LAN it still seems that fixed ipv4 addresses makes
> life easier.  I was enquiring if ipv6 would somehow provide an
> alternative.

No, not really. Using a tunnel (or at least a TSP-style tunnel) means
that you don't need a static address on the outside interface of your
CPE, and once the tunnel is up, you end up with static IPv6 addresses on
your hosts, making them directly addressable from the Internet. That
makes it much easier to communicate from the outside Internet into your
network - no more port forwarding etc.

> To use ipv6 /between/ machines on the LAN however, would I need an
> ipv6 aware router?

See above - you don't need your CPE to be IPv6 aware, you can just have
a tunnel set up to get a prefix, and radvd to advertise that prefix, and
then all your hosts will start doing IPv6 by themselves. If you want to
use *names* to refer to them, then you need to put DNS into the mix. If
you want to automate the DNS, you need to add DHCP into the mix (or set
up the hosts to do DDNS themselves). The last two steps are essentially
identical for v4 and v6.

If your CPE *can* do the tunnel thing and the router advertising thing
itself, then so much the better (my little Mikrotik RB951-2n does it
like a champ), but it is not hard to put the tunnel endpoint on just
about any host in your network.

Seriously - just do it. It's far easier than you think.

Regards, K.

-- 
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Karl Auer (kauer at biplane.com.au)
http://www.biplane.com.au/kauer
http://www.biplane.com.au/blog

GPG fingerprint: B862 FB15 FE96 4961 BC62 1A40 6239 1208 9865 5F9A
Old fingerprint: AE1D 4868 6420 AD9A A698 5251 1699 7B78 4EEE 6017






More information about the ubuntu-users mailing list