OVH Community, your new community space.

IPv6 Clarification


NeddySeagoon
24-12-2013, 21:14
village_i_diot,

What does
Code:
traceroute -6
each way tell you?
Maybe the OVH routing is broken?

Code:
traceroute -6 2001:41d0:2:c17::2
traceroute to 2001:41d0:2:c17::2 (2001:41d0:2:c17::2), 30 hops max, 80 byte packets
 1  vss-9b-6k.fr.eu (2001:41d0:8:b9ff:ff:ff:ff:fd)  4.746 ms * *
 2  rbx-g1-a9.fr.eu (2001:41d0::19d)  3.020 ms  3.028 ms  5.087 ms
 3  vss-1b-6k.fr.eu (2001:41d0::f22)  0.659 ms * vss-1-6k.fr.eu (2001:41d0::921)  0.640 ms
 4  2001:41d0:2:c17::2 (2001:41d0:2:c17::2)  0.596 ms  0.605 ms  0.602 ms
That's from my kimi at inet6 2001:41d0:8:b970::2. I can't test your other box as you obscured the IP.
Feel free to use that as a test target if you wish.

Looks like I missed the last post on a page on its own.

village_i_diot
23-12-2013, 20:28
Latest update ISPconfig 3 edits the interfaces file when you add a new IP to the control panel. All well and good but when it adds the IPv6 to the interfaces file it does so like :

iface eth0:4 inet static
address 2001:41d0:2:c17::d11
netmask 255.255.255.0
network 250.32.0.0
broadcast 250.32.0.255
gateway ip.v4.XX.254

Which fails so you need to add the IPv6's that you plan to use to ispconfig3 and then manually correct the interfaces file.

village_i_diot
19-12-2013, 19:40
Strange but true, I tried a couple of sites online that offer ping6 and traceroute6 tests and they worked. so it appears the problem is just between the kimi and the mSP.


Edit : Kimi to mSP is also working now. Thank you so much for your help.

village_i_diot
19-12-2013, 19:36
OK I feel really stupid at the moment as it is probably so simple and I'm making a meal of it

This is what I have

/etc/network/interfaces

Code:
# The loopback network interface
auto lo
iface lo inet loopback

# The primary network interface
auto eth0

iface eth0 inet6 static
address 2001:41d0:2:XXX::1
netmask 56
gateway 2001:41d0:2:Xff:ff:ff:ff:ff

iface eth0 inet static
        address 127.0.0.1
        netmask 255.255.255.0
        network 127.0.0.0
        broadcast 127.0.0.255
        gateway 94.23.11.254


auto eth0:0
iface eth0:0 inet static
        address 94.23.YY.YY
        netmask 255.255.255.0
        network 94.23.11.0
        broadcast 94.23.11.255
        gateway 94.23.11.254

auto eth0:1
iface eth0:1 inet static
        address 178.32.ZZ.ZZ
        netmask 255.255.255.0
        network 178.32.49.0
        broadcast 178.32.49.255
        gateway 94.23.11.254
Code:
 ip -6 neigh ls dev eth0
2001:41d0:2:cff:ff:ff:ff:ff lladdr 00:05:73:a0:00:00 router REACHABLE

 ip -6 route show
2001:41d0:2:c00::/56 dev eth0  proto kernel  metric 256
fe80::/64 dev eth0  proto kernel  metric 256
default via 2001:41d0:2:cff:ff:ff:ff:ff dev eth0  metric 1

 ifconfig
eth0      Link encap:Ethernet  HWaddr 08:60:6e:e5:b9:51
          inet addr:127.0.0.1  Bcast:127.0.0.255  Mask:255.255.255.0
          inet6 addr: 2001:41d0:2:XXX::1/56 Scope:Global
          inet6 addr: fe80::a60:6eff:fee5:b951/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:15837 errors:0 dropped:2 overruns:0 frame:0
          TX packets:18313 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:3559893 (3.3 MiB)  TX bytes:12264790 (11.6 MiB)

eth0:0    Link encap:Ethernet  HWaddr 08:60:6e:e5:b9:51
          inet addr:94.23.YY.YY  Bcast:94.23.11.255  Mask:255.255.255.0
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1

eth0:1    Link encap:Ethernet  HWaddr 08:60:6e:e5:b9:51
          inet addr:178.32.ZZ,ZZ  Bcast:178.32.49.255  Mask:255.255.255.0
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1

lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:65536  Metric:1
          RX packets:4886 errors:0 dropped:0 overruns:0 frame:0
          TX packets:4886 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:889439 (868.5 KiB)  TX bytes:889439 (868.5 KiB)
On the server it all apears to be ok, I can ping6 it's own IPv6 address, I can ping6 the 'gateway' address and I can ping6 external addresses such as ipv6.google.com

The problem I am having is my kimi can't ping6 this server's IPv6 yet the Kimi can ping6 other addresses and this server can ping6 my Kimi

What am I missing?

Thanks

NeddySeagoon
18-12-2013, 21:53
village_i_diot,

On my kimi
Code:
$ ip -6 neigh ls dev eth0 
fe80::da24:bdff:fe90:b0c0 lladdr d8:24:bd:90:b0:c0 router REACHABLE
fe80::264:40ff:fe3a:fac0 lladdr 00:64:40:3a:fa:c0 router REACHABLE
2001:41d0:8:b9ff:ff:ff:ff:fd lladdr 00:64:40:3a:fa:c0 router REACHABLE
Notice that the Link Layer Address (lladdr) of two ot the routers is the same. That means they are the same router.
I have no idea what the other router is.

You can use the router fe80:: address as your default route once you know it.

village_i_diot
18-12-2013, 20:27
Quote Originally Posted by NeddySeagoon
village_i_diot,

Why do you have 127/8 assigned to eth0?
That's the loopback address and it belongs to the loopback interface called lo
IPv6 also has a loopback address allocated to lo, its written as ::1
This is the first time I have looked at setting IP's in detail as I've not had the need before, a learning curve, and the eth0 was already assigned the 127/8 when I first looked. I just assumed it was because my two public IP addresses had be assigned to eth0:0 and eth0:1
Quote Originally Posted by NeddySeagoon
I have never used ifconfig with IPv6, I've always used iproute2.
You will need to a a route to the IRv6 router and here is where the wheel comes off.
2001:41d0:2:0cff:ff:ff:ff:ff is not in your /64, its in a /56 that you have 1/256 of. (Your /64)
So cheat, change
Code:
netmask 64
to
Code:
netmask 56
Lastly, 2001:41d0:2:0cff:ff:ff:ff:ff may not be the address of your router either but OVH won't admit that.
You may need to send router discover messages to find out where your IPv6 gateway really is.

As you are going to use /56 to describe your /64 be very very sure that you the the 8 bits that don't belong to you correct.
I'll leave you to google router discovery messages, since I don't remember the command
.
Thanks for your help, I will get googling.

NeddySeagoon
18-12-2013, 20:07
village_i_diot,

Why do you have 127/8 assigned to eth0?
That's the loopback address and it belongs to the loopback interface called lo
IPv6 also has a loopback address allocated to lo, its written as ::1

I have never used ifconfig with IPv6, I've always used iproute2.
You will need to a a route to the IRv6 router and here is where the wheel comes off.
2001:41d0:2:0cff:ff:ff:ff:ff is not in your /64, its in a /56 that you have 1/256 of. (Your /64)
So cheat, change
Code:
netmask 64
to
Code:
netmask 56
Lastly, 2001:41d0:2:0cff:ff:ff:ff:ff may not be the address of your router either but OVH won't admit that.
You may need to send router discover messages to find out where your IPv6 gateway really is.

As you are going to use /56 to describe your /64 be very very sure that you the the 8 bits that don't belong to you correct.
I'll leave you to google router discovery messages, since I don't remember the command
.

village_i_diot
18-12-2013, 12:08
It appears I am getting somewhere

In my interfaces file I had the following

Code:
auto eth0

iface eth0 inet static
        address 127.0.0.1
        netmask 255.255.255.0
        network 127.0.0.0
        broadcast 127.0.0.255
        gateway 94.23.11.254

iface eth0 inet6 static
address 2001:41D0:2:0c17::2
netmask 64
the IPv6 doesn't get added but if I change it so the inet6 is added first, it is added although I get a different error when restarting the network
Code:
service networking restart
Running /etc/init.d/networking restart is deprecated because it may not enable again some interfaces ... (warning).
Reconfiguring network interfaces...SIOCSIFADDR: File exists
Failed to bring up eth0.
done.

~# ifconfig eth0
eth0      Link encap:Ethernet  HWaddr 08:60:6e:e5:b9:51
          inet addr:127.0.0.1  Bcast:127.0.0.255  Mask:255.255.255.0
          inet6 addr: 2001:41d0:2:c17::2/64 Scope:Global
          inet6 addr: fe80::a60:6eff:fee5:b951/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:85673 errors:0 dropped:10 overruns:0 frame:0
          TX packets:97778 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:15870528 (15.1 MiB)  TX bytes:74344524 (70.9 MiB)
So now from this machine I can ping6 the new IPv6 address but when I try to ping6 it from my kimi it just times out. I am assuming this must be a gateway issue so I tried using the route command to add the default gateway but it still returns an error

Code:
route -A inet6 add default gw 2001:41d0:2:0cff:ff:ff:ff:ff dev eth0

SIOCADDRT: No route to host

village_i_diot
18-12-2013, 11:52
Thank you both for your replies, I have studied what Neddy described and then read http://help.ovh.co.uk/Ipv4Ipv6#link9

Now I have added the following to the interfaces file as mentioned in the above link:
Code:
iface eth0 inet6 static
address 2001:41D0:2:0c17::2
netmask 64
but when I restart the network it 'fails to load eth:0'

Code:
 service networking restart
Running /etc/init.d/networking restart is deprecated because it may not enable again some interfaces ... (warning).
Reconfiguring network interfaces...SIOCADDRT: Network is unreachable
Failed to bring up eth0.
done.
When I run Ifconfig it shows :
Code:
eth0      Link encap:Ethernet  HWaddr 08:60:6e:e5:b9:51
          inet addr:127.0.0.1  Bcast:127.0.0.255  Mask:255.255.255.0
          inet6 addr: fe80::a60:6eff:fee5:b951/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:58906 errors:0 dropped:7 overruns:0 frame:0
          TX packets:66928 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:11553445 (11.0 MiB)  TX bytes:48897972 (46.6 MiB)

eth0:0    Link encap:Ethernet  HWaddr 08:60:6e:e5:b9:51
          inet addr:94.23.11.23  Bcast:94.23.11.255  Mask:255.255.255.0
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1

eth0:1    Link encap:Ethernet  HWaddr 08:60:6e:e5:b9:51
          inet addr:178.32.49.66  Bcast:178.32.49.255  Mask:255.255.255.0
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
So nothing has been added or taken away.

When I try using the route command to add the default gateway I get the same SIOCADDRT error as above.

Myatu
17-12-2013, 23:19
FWIW, you can use the full /64 range, including 2001...::1 (which is the reason why OVH has put the gateway on /56 - annoyingly so).

NeddySeagoon
17-12-2013, 22:25
Quote Originally Posted by village_i_diot
So here are my questions :

1. The Kimi as far as I am aware should only have the 1 IPv6 address, ie the /128, but ifconfig shows /64, does this mean that I have more than the one on the Kimi?

2. No public IPv6 appears to be added to my mSP, How do I do this? I assume adding it to my control panel (ispconfig3) doesn't add it to the network?

3. I understand that a /64 block is a lot of addresses, what is the range I can actually use ie the first one and last one?

Thanks
Kimis in 2012 have a /64, at the start of the "Great 2013 Debacle", a new range of Kimis was released with a /128
Look in the manager to see your IP block.

I'm a Gentoo guy, not debian but the idea is the same. You ssh in, get root, then edit a file in /etc/ somewhere to set up your IPv6 address and gateway. The conventions for IPv6 are muct the same as for iPv4. The lowest address is the network address, you must not assign it to a host.
Its a really bad idea to assign the router IP to one of your hosts too.
To put things into context, the entire IPv4 address space is the same as a /96 and you have a /64, which in 4G times bigger than the entire IPv4 address range. Feel free to use any and all of your /64 except the two I've mentioned.
The fe80: range is the equivelent of the IPv4 link-local (self assigned) address range.

A word of warning, the gateway may well not be where OVH have told you it is.

Here is a Gentoo sample
Code:
config_eth0="5.135.178.112/24 brd 5.135.178.255
             2001:41d0:8:b970::2/56"
routes_eth0="default via 5.135.178.254
             default via 2001:41d0:8:b9ff:ff:ff:ff:fd"
#The router (default gateway) for each IPv6 is always on IP:v:6:FF:FF:FF:FF:FF, except when it isn't
Even though I have a /64 I am using /56 above so that the router appears in the net range.
I'm just being very careful to get the top 8 bits outside my /64 right. Thats the 70 before the :: in my case.

Myatu
17-12-2013, 17:27
Quote Originally Posted by village_i_diot
1. The Kimi as far as I am aware should only have the 1 IPv6 address, ie the /128, but ifconfig shows /64, does this mean that I have more than the one on the Kimi?
It is supposed to be one, but looks that it has been setup with a /64 block instead. Possibly an error on OVH's side, or you're using a Kimsufi prior to that change.

Quote Originally Posted by village_i_diot
2. No public IPv6 appears to be added to my mSP, How do I do this? I assume adding it to my control panel (ispconfig3) doesn't add it to the network?
You'll have to look at your OVH Manager to find out what the IPv6 block is, and then add it to the system in the same way your Kimsufi has been configured. Someone will certainly correct me if wrong, but its likely that it can't be done through IPSconfig3 directly, due to the non-standard way of OVH using the IPv6 gateway, etc.


Quote Originally Posted by village_i_diot
3. I understand that a /64 block is a lot of addresses, what is the range I can actually use ie the first one and last one?
In case of 2001:41D0:1:XXXX::/64, it will be from:

2001:41D0:1:XXXX:0000:0000:0000:0001

to:

2001:41D0:1:XXXX:FFFF:FFFF:FFFF:FFFF

In other words, you have a choice of 18,446,744,073,709,551,616 IPv6 addresses.

village_i_diot
17-12-2013, 14:11
Please forgive the lack of understanding of networks here, I am after some info on IPv6 in simple terms.

I have an mSP running Debian which manager3 shows I have the IPv6 2001:41d0:2:XXXX::/64

When I run ifconfig on the server the only IPv6 shown is :
Code:
  inet6 addr: fe80::a60:6eff:fee5:b951/64 Scope:Link on eth0
I assume this is a private IPv6 address and the public has not been added to the machine

There is nothing relating to IPv6 in the /.etc/network/interfaces file

I also have an 2013 Kimi which manager3 shows I have the IPv6 2001:41d0:1:YYYY::1/128
When I run ifconfig on here it shows
Code:
         inet6 addr: fe80::3a60:77ff:fed5:c0e5/64 Scope:Link
          inet6 addr: 2001:41d0:1:YYYY::1/64 Scope:Global
Again I assume the fe80 address is private.

the IPv6 section of the /etc/network/interfaces is

Code:
iface eth0 inet6 static
        address 2001:41D0:1:XXXX::1
        netmask 64
        post-up /sbin/ip -f inet6 route add 2001:41D0:1:C9ff:ff:ff:ff:ff dev eth0
        post-up /sbin/ip -f inet6 route add default via 2001:41D0:1:C9ff:ff:ff:ff:ff
        pre-down /sbin/ip -f inet6 route del default via 2001:41D0:1:C9ff:ff:ff:ff:ff
        pre-down /sbin/ip -f inet6 route del 2001:41D0:1:C9ff:ff:ff:ff:ff dev eth0
So here are my questions :

1. The Kimi as far as I am aware should only have the 1 IPv6 address, ie the /128, but ifconfig shows /64, does this mean that I have more than the one on the Kimi?

2. No public IPv6 appears to be added to my mSP, How do I do this? I assume adding it to my control panel (ispconfig3) doesn't add it to the network?

3. I understand that a /64 block is a lot of addresses, what is the range I can actually use ie the first one and last one?

Thanks