I have the following situation: I configured a FreeBSD 9.1 machine as the endpoint of a heartbeat SixXS tunnel on a gif0
interface. It works so far, and I can ping6 via IPv6.
I assigned to another interface lagg0
which is an aggregated interface a static IPv6 out of the assigned IPv6 subnet which is connected to the LAN. Now I would like to advertise this network prefix to my LAN using the rtadvd
deamon.
This is its /etc/rtadvd.conf
file:
lagg0:\
:addr="xxxx:yyyy:zzzz:aaaa::":prefixlen#64:tc=ether:
with xxxx:yyyy:zzzz:aaaa::/64
being the network prefix. When I now add clients to the network, they take the network prefix and generate their autoconf and temporary adresses. That works great.
However what they are missing is the correct IPv6 default route. In the routing table the default route for IPv6 is the fe80::
link-local adress of the router.
Now no packets are routed to the internet. If I add the default route manually to the host it works.
My questions
I thought that the router advertisement should configure the right default route on the clients. Am I missing something here? Why does it advertise its link-local adress instead of the right one?
The link local address should work just fine, and is indeed the address used by
rtadvd
.I'm using 6to4, but it's essentially the same configuration. In my case all I do is:
This just creates the connection, your tunnel should sever the same purpose.
At this point
ping6 ipv6.google.com
works from my router.Now routing is enabled, even with link local addresses, if I manually configure clients to use the router as their DG IPv6 works. But we want some level of auto-configuration... so
/etc/rtadvd.conf
contains:The only thing left is to add the configuration to my
rc.conf
file:The clients do have a default route of the fec0:: range, but it works perfectly. A
tcpdump
shows the clients sending from their global IPv6 address to the fec0 address.For anyone reading this wanting to do 6to4 the above "internal" addresses are for 192.168.0.1, which isn't routable on the Internet. You need to calculate your own internal IPv6 address based on your external IPv4 address.