- Joined
- May 16, 2014
- Messages
- 20
- Points
- 1
We are providing /48 IPv6 subnets with dedicated servers. Here we have described how to set up an IPv6 address on a Linux server.
Centos Server
Centos Server
- Make sure that IPv6 is not disabled in the server configuration. So you need to check the sysctl file and add the entries below:
# vi /etc/sysctl.conf
net.ipv6.conf.default.disable_ipv6 = 0
net.ipv6.conf.all.disable_ipv6 = 0 - Then we need to enable the IPv6 in the network file as well:
# vi /etc/sysconfig/network
NETWORKING_IPV6=yes - Add the entries in the active ethernet file, here I am doing it on eth0:
# vi /etc/sysconfig/network-scripts/ifcfg-eth0
Append the following lines in that file, make sure that IPv4 entries are not getting removed:
IPV6INIT=yes
IPV6ADDR=IPv6 IP-Address
IPV6_DEFAULTGW=IPv6 Gateway Address - Restart the network service:
# /etc/init.d/network/restart
Debian/Ubuntu Server
1. Access the Network interfaces file and add the following entries:
# sudo nano /etc/network/interfaces
auto eth0
iface eth0 inet6 static
address <IPv6 IP-Address>
netmask 48
gateway <IPv6 Gateway Address>
# sudo /etc/init.d/networking restart
or
# sudo systemctl restart networking