To set up Ipv6 on your server, you need the IPv6 information from your control panel:
Attention: Please only use IPv6 fe80::1 as gateway!
Ubuntu 20.04 (netplan):
Example:
# /etc/netplan/config.yaml
network:
version: 2
renderer: networkd
ethernets:
eth0: #Interface-Name
addresses:
- <IPv4 Adresse>/32 #Weitere wie im Beispiel möglich
- <IPv6 Adresse>/64 # Eine Adresse aus Ihrem /64 IPv6 Subnetz
gateway6: fe80::1
nameservers:
search: [ fuchsia.fastwebserver.de ]
addresses:
- "62.141.32.5" # Resolver 1
- "62.141.32.4" # Resolver 2
- "62.141.32.3" # Resolver 3
routes:
- to: 0.0.0.0/0
via: <IPv4 Gateway> #Ipv4 Gateway
on-link: true
Please note that Netplan only works if the spacing is correct, only spaces, not tabs, are allowed.
After the configuration has been adjusted, "sudo netplan apply" must be run again to save the changes.
Debian/Ubuntu 16.04:
Log in to the server as user root and open the network configuration with:
nano /etc/network/interfaces
There you add the following lines:
iface enp1s0f0 inet6 static
address <Eine IP aus Ihrem /64 Subnetz>
netmask 64
gateway fe80::1
*** Important ***
Please change the name of the device (eth0) if necessary. This is already in the configuration. You can find an example in the screenshot:
Save with CTRL + O and close nano with CTRL + X
It is best to restart the entire server. If this is not possible, you can also restart the network with the following command:
service networking restart
CentOS:
Log in to the server as user root and open the network configuration:
nano /etc/sysconfig/network-scripts/ifcfg-eth0
*** wichtig: Der Name des Devices eth0 kann abweichend sein, bitte überprüfen Sie dies mit "ip addr".***
There you can compare all the preset settings with those below and adjust them if necessary. All missing lines must be added and others that start with IPV6 can be removed.
IPV6INIT=yes
IPV6ADDR=<IPV6 Adresse><Prefix z.B. /64>
IPV6_DEFAULTGW= fe80::1
IPV6_DEFAULTDEV=<Interface z.B. enp5s0 oder eth0>
Save with CTRL + O, close with CTRL + X
It is best to restart the entire server afterwards, or if that is not possible, at least the network:
service network restart
The ifconfig command can be used to check the configuration.
Windows:
Log in to the server as user Administrator.
Please press START in the bottom left of your taskbar. There you will find the option "Run". Enter cmd.
A black window with white text will open (also called a command prompt or Windows shell). Please enter the following commands there:
netsh interface ipv6 add address store=persistent
netsh interface ipv6 add route ::/0 fe80::1 store=persistent
z.B.
netsh interface ipv6 add address store=persistent
netsh interface ipv6 add route ::/0 fe80::1 store=persistent
You can see the result with "ipconfig -all".
The test:
To test whether the IP address is correctly accessible you can proceed as follows
1. Ping the configured IP address on your server. If the server cannot reach the address configured on it, something is wrong. You can ping the IP v6 address using the console command: ping -6 IP address
2. Ping the IP address of the gateway from the server as this is usually outside your own network. This way you can see if there is a problem with the routing
3. Ping an external address e.g. 2a00:1450:4001:814::200e This is an address from Google that was set up specifically for these test purposes
4. Try to reach your server from outside via IPv6 If your home computer does not have an IPv6 address, you can use an online ping service such as www.subnetonline.com/pages/ipv6-network-tools/online-ipv6-ping.php