There is an official guide regarding ipv6 configuration using Ubuntu’s netplan. It seems it skips one crucial thing tho - and that is default route. The route step is mentioned in non-persistent and file interfaces sections (the ip -6 route add
part). In order to fully get v6 working on their VPS I had to add the route via routes
declaration in netplan yaml configuration (Ubuntu LTS 18.04).
# /etc/netplan/51-cloud-init-ipv6.yaml
netplan:
network:
version: 2
ethernets:
ens3: # you main eth device
dhcp6: false
match:
name: ens3 # same ^
addresses:
# ipv6 address can be obtained from their web ui
# netmask offered by ovh on their VPSes weirdly is not mentioned explicitly anywhere
- "YOUR_IPV6/128"
gateway6: "IPv6_GATEWAY" # v6 gateway can be obtained from their web ui panel
routes:
- to: "IPv6_GATEWAY" # same as above ^
scope: link # this should work just fine on modern (v0.98+) netplan
Run netplan apply
after introducing changes and try ping v6 host or simply execute some http request:
curl -v -6 google.com