How to setup IPv6 on KVM VPS from unihost.com (for Linux CentOS 5.x/6.x).
To setup IPv6 do the following steps:
Edit /etc/sysconfig/network. file using text editor (vi, vim, nano, mcedit etc.). Add or change the lines:
HOSTNAME=localhost.localdomain NETWORKING=yes NETWORKING_IPV6=yes
If this line was already created make sure it reads above.
Edit /etc/sysconfig/network-scripts/ifcfg-ethX file: “X” –
the ID of the network interface (usually “0”). Add the following lines to the file:
IPV6INIT=yes IPV6ADDR=IPv6_Address (how can I find a list of IPv6 addresses allocated to my VPS, see Appendix 1) IPV6DEFAULTGW=Gateway_IPv6_Address (the gateway addresses for each of our servers are specified in Appendix 2)
Make sure the file reads bellow:
DEVICE=eth0 BOOTPROTO=dhcp NM_CONTROLLED=no ONBOOT=yes TYPE=Ethernet IPV6INIT=yes IPV6ADDR=IPv6_Address (how can I find a list of IPv6 addresses allocated to my VPS, see Appendix 1) IPV6_DEFAULTGW=Gateway_IPv6_Address (the gateway addresses for each of our servers are specified in Appendix 2)
Restart the network:
service network restart
Or
/etc/init.d/network restart
After restart run the command:
route -A inet6 add default gw Gateway_IPv6_Address (the gateway addresses for each of our servers are specified in Appendix 2)
Appendix №1
To see a list of available IPv6 addresses allocated to your VPS, log into the VPS control panel (https://vps.unihost.com) and go to “Network” tab:
Appendix №2
IPv6 gateway addresses to specify a route by default:
solus012s.unihost.com: 2a01:4f8:192:2b3::2 / 64 solus014s.unihost.com: 2a01:4f8:200:21a9::2 / 64 solus016s.unihost.com: 2a01:4f8:201:528b::2/ 64 solus017s.unihost.com: 2a01:4f8:202:500d::2 / 64 solus018s.unihost.com: 2a01:4f8:211:a48::2 / 64 solus019s.unihost.com: 2a01:4f8:211:208e::2 / 64 solus020s.unihost.com: 2a01:4f8:131:3f5::2 / 64
The name of your server is specified in the Node line