小樱 发表于 2015/1/11 22:16

Configuring IPv6 on your VPS 在服务器上部署IPV6网络设置

所有这些例子IPv6子网 2001:DB8:1000::/64. 你需要分配子网更新它们.

我们将使用 2001:DB8:1000::100 为主体的IP地址分配。我们也将使用 2001:19f0:4009:2001::1234 为我们配置二级IP地址。添加辅助IP是没有必要的,但显示你使用,如果你想有更多的IPv6地址。

Windows:
netsh interface ipv6 set global randomizeidentifiers=disabled
netsh interface ipv6 add address interface="Local Area Connection" address="2001:DB8:1000::100/64"
netsh interface ipv6 add address interface="Local Area Connection" address="2001:19f0:4009:2001::1234/64"


CentOS:
In /etc/sysconfig/network-scripts/ifcfg-eth0 add the following lines:
IPV6INIT="yes"
IPV6ADDR="2001:DB8:1000::100/64"
IPV6_AUTOCONF="no"
IPV6ADDR_SECONDARIES="2001:19f0:4009:2001::1234/64"


Debian/Ubuntu:
In /etc/network/interfaces add the following lines:
iface eth0 inet6 static
address 2001:DB8:1000::100
netmask 64
up /sbin/ip -6 addr add dev eth0 2001:19f0:4009:2001::1234


FreeBSD:
In /etc/rc.conf add the following lines:
rtsold_enable="YES"
ipv6_activate_all_interfaces="YES"
rtsold_flags="-aF"
ifconfig_vtnet0_ipv6="inet6 2001:DB8:1000::100 prefixlen 64"
ifconfig_vtnet0_alias0="inet6 2001:19f0:4009:2001::1234 prefixlen 64"

devicenull September 2014
One very important note for any Linux based system:

If you have IP forwarding enabled (if you're using your server as a VPN or similar), you'll need to add the following to /etc/sysctl.conf:

net.ipv6.conf.all.accept_ra=2
net.ipv6.conf.eth0.accept_ra=2


The default settings here (which is 1), prevents IPv6 from working properly when IP forwarding is enabled. You can check if IP forwarding is enabled by running 'sysctl sysctl net.ipv4.ip_forward'


比小新还帅 发表于 2015/1/11 22:16

沉醉在眼中 发表于 2015/1/11 22:16

页: [1]
查看完整版本: Configuring IPv6 on your VPS 在服务器上部署IPV6网络设置