#1 2016-09-15 09:12:35

delfer
Trusted Member
Registered: 2016-09-15
Posts: 5

IPv6 /64 block not routed to VPS

InceptionHosting
MiniVPS128 - NETHERLANDS

By this plan I have /64 block of IPv6 addresses.
But I can't use them.
Trying:

~# ping6 2001:4860:4860::8888 -c 1
     PING 2001:4860:4860::8888(2001:4860:4860::8888) 56 data bytes
     64 bytes from 2001:4860:4860::8888: icmp_seq=1 ttl=55 time=13.7 ms
     --- 2001:4860:4860::8888 ping statistics ---
     1 packets transmitted, 1 received, 0% packet loss, time 0ms
     rtt min/avg/max/mdev = 13.719/13.719/13.719/0.000 ms
~# ifconfig venet0 add 2001:db8:1234:5678::5/64
~# ping6 2001:4860:4860::8888 -c 1
     PING 2001:4860:4860::8888(2001:4860:4860::8888) 56 data bytes
     --- 2001:4860:4860::8888 ping statistics ---
     1 packets transmitted, 0 received, 100% packet loss, time 0ms

Adding any of IPv6 in assigned block breaks networking. Packet sent but not routed back.

BUT,
If I add the same IPv6 through SolusVM (Network->Manage->Add) - its works!
I do not want to add 18446744073709551616 (/64 block) IPs manually.

(2001:db8:1234:5678::5/64  here only for example, of course)

Where is the problem? Limited support in SolusVM?

Offline

#2 2016-09-15 12:42:23

Simonindia
Moderator and your buddy
From: India
Registered: 2015-06-05
Posts: 604

Re: IPv6 /64 block not routed to VPS

Dude Are you going to use every single Ipv6 address in the /64 block if so good luck (Houston we have a problem) smile


Just trying my best to help. ♥ |
----------------------------------------------------------------------------------
“Remember to always be yourself. Unless you suck.” -Joss Whedon“Do what you can, with what you have, where you are.”-Theodore Roosevelt

Offline

#3 2016-09-15 13:03:41

delfer
Trusted Member
Registered: 2016-09-15
Posts: 5

Re: IPv6 /64 block not routed to VPS

If you want discuss about "why" we can do it in other topic or via PM.
In short: I don't need every IP, just any IP in any time. For example assign to VPN client to improve privacy.

Offline

#4 2016-09-15 13:52:46

AnthonySmith
Low End Boss
From: ~/
Registered: 2013-02-13
Posts: 3,895
Website

Re: IPv6 /64 block not routed to VPS

They have to be assigned through solusvm, this was they are allocated in your container config and authorized for use.

If you want to be able to dynamically add any IPv6 you want within your range dynamically then you need to get yourself a dedicated server with a /64 routed at the switch port.


https://upto32.com retro gaming and nostalgia forum that does not take itself to seriously smile

Offline

#5 2016-09-15 15:19:08

delfer
Trusted Member
Registered: 2016-09-15
Posts: 5

Re: IPv6 /64 block not routed to VPS

How can I give IPv6 to my VPN client if it always assign to VPS interface when add it through SolusVM?
How many IP's can be assigned through SolusVM? 100?
Why they give /64 block instead of /121 (128 IPs)?
/64 block must have for SLAAC, CGA, IPsec, ILNP, ND, SEND, privacy extensions [RFC4941],  SHIM6, etc. But only when all subnet routed to interface. Not one IP.

Offline

#6 2016-09-15 18:03:31

AnthonySmith
Low End Boss
From: ~/
Registered: 2013-02-13
Posts: 3,895
Website

Re: IPv6 /64 block not routed to VPS

I don't know the specifics of your VPN server/client, you can have more than 100 (not sure why you would want to), with solusvm/OpenVZ they are not routed, you just have a /64 pool you can allocate from.

I think probably the KVM LHC product would have been more suitable for you.


https://upto32.com retro gaming and nostalgia forum that does not take itself to seriously smile

Offline

#7 2016-09-15 19:27:40

delfer
Trusted Member
Registered: 2016-09-15
Posts: 5

Re: IPv6 /64 block not routed to VPS

Backtogeek, thank for your reply.

SolusVM assigns IPv6 addresses to users by randomly handing out individual IPv6 addresses out of a larger range. Not an actual block; SolusVM requires you to give a set range of addresses from which to generate random ones. This allows the SolusVM Administrator or Reseller to assign up to 200 individual random addresses to an actual VPS.
....
With SolusVM not assigning /64 blocks to end users they not only not get all the features of IPv6.

https://www.mpkossen.com/2014/04/the-ma … mentation/

Found solution:
1. Choose 200 addresses you want to use
2. Add addresses through SolusVM to make it routable
3. Remove this IPs from inside VPS to make it assignable
4. Use it as you want (assign to VPN client or proxy users)

Offline

#8 2016-09-15 19:40:36

AnthonySmith
Low End Boss
From: ~/
Registered: 2013-02-13
Posts: 3,895
Website

Re: IPv6 /64 block not routed to VPS

nice one,

just be aware every time you reboot you will have to remove the IP's as they will be added again.


https://upto32.com retro gaming and nostalgia forum that does not take itself to seriously smile

Offline

#9 2016-09-28 15:41:31

delfer
Trusted Member
Registered: 2016-09-15
Posts: 5

Re: IPv6 /64 block not routed to VPS

/etc/network/if-up.d/ipv6normalizer (Debian 7)

#!/bin/bash

DEV='venet0'

IPS=$( ip -6 addr show dev $DEV | grep inet6 | awk '{print $2}' )
PRIMARY=$( printf "$IPS" | head -n 1 | awk -F'/' '{print $1"/128"}')

for IP in $IPS ; do
    if [ "$IP" != "$PRIMARY" ]
    then
        echo "Removing $IP"
        ip -6 addr del $IP dev $DEV
    fi
done

if [[  $PRIMARY == *":"* ]]
then
    echo "Add $PRIMARY"
    if [[ $IPS != *"$PRIMARY"* ]]
    then
        ip -6 addr add $PRIMARY dev $DEV
        route -A inet6 add default dev $DEV
    fi
else
    echo "No IPv6"
    exit 1;
fi

Last edited by delfer (2016-09-28 16:30:23)

Offline

Board footer

Powered by FluxBB