我已经买了一个新的专用服务器,有2个IPv4地址和一个/ 56 IPv6子网。 当我在专用服务器上ping我的域名时,我收到一条消息。 但是当我从外面ping平无事。
所以我去testing通过IPv6.nl等事情,一切都很好,除了连接到我的networking服务器。 testing无法到达我的服务器。 我试图打开我的防火墙的端口,但似乎没有工作。
我的主机名是cp.hshweb.eu,运行在专用服务器(CentOS6.6)上,为虚拟主机安装了Odin plesk。 我可以采取哪些措施,并尝试使用IPv6从外部访问我们的服务器?
当我重置networking时,我得到这个消息:
[root@cp network-scripts]# service network restart Shutting down interface eth0: [ OK ] Shutting down loopback interface: [ OK ] Bringing up loopback interface: [ OK ] Bringing up interface eth0: Determining IP information for eth0... done. RTNETLINK answers: File exists RTNETLINK answers: File exists RTNETLINK answers: File exists RTNETLINK answers: File exists RTNETLINK answers: File exists RTNETLINK answers: File exists Determining if ip address 85.214.148.249 is already in use for device eth0... [ OK ]
ip addr show给出了这个:
[root@cp ~]# ip addr show 1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00 inet 127.0.0.1/8 scope host lo inet6 ::1/128 scope host valid_lft forever preferred_lft forever 2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP qlen 1000 link/ether 40:61:86:ee:be:3f brd ff:ff:ff:ff:ff:ff inet 85.214.208.177/32 brd 85.214.208.177 scope global eth0 inet 85.214.148.249/32 brd 85.214.148.249 scope global eth0:1 inet6 2a01:238:4317:d800:cafe:dead:beef:0/128 scope global valid_lft forever preferred_lft forever inet6 2a01:238:4317:d800::feed/128 scope global valid_lft forever preferred_lft forever inet6 2a01:238:4317:d800::/56 scope global valid_lft forever preferred_lft forever inet6 2a01:238:4317:d800:0:bad:a55:cafe/128 scope global valid_lft forever preferred_lft forever inet6 2a01:238:4317:d800:d108:898c:628f:a199/128 scope global valid_lft forever preferred_lft forever inet6 fe80::4261:86ff:feee:be3f/64 scope link valid_lft forever preferred_lft forever 3: eth1: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN qlen 1000 link/ether 40:61:86:ee:be:40 brd ff:ff:ff:ff:ff:ff
这是我的ifcfg-eth0文件:
DEVICE="eth0" BOOTPROTO="dhcp" DHCPV6C="no" IPV6INIT="yes" IPV6_AUTOCONF="no" IPV6_ROUTER="yes" NM_CONTROLLED="no" ONBOOT="yes" HWADDR=40:61:86:EE:BE:3F IPV6ADDR="2a01:238:4317:d800:d108:898c:628f:a199/128" IPV6ADDR_SECONDARIES="2a01:238:4317:d800:0:bad:a55:cafe/128 2a01:238:4317:d800::/56 2a01:238:4317:d800::feed/128 2a01:238:4317:d800:cafe:dead:beef:0/128 2a01:238:4317:d800:d108:898c:628f:a199/128 2a01:238:4317:d800::feed/128 2a01:238:4317:d800:0:bad:a55:cafe/128 2a01:238:4317:d800:cafe:dead:beef:0/128 2a01:238:4317:d800:d108:898c:628f:a199/128 2a01:238:4317:d800::/0" IPV6_DEFAULTGW=2a01:238:4317:d800::1 IPV6FORWARDING=yes
而我的networkingconfiguration是:
HOSTNAME=cp.domain.tld NETWORKING=yes NETWORKING_IPV6=yes IPV6_DEFAULTDEV=eth0 IPV6FORWARDING=yes IPV6_AUTOCONF=no IPV6_AUTOTUNNEL=no IPV6_DEFAULTGW=2a01:238:4317:d800::1
ip-6路由:
[root@cp ~]# ip -6 route ::/96 via :: dev sit0 metric 256 mtu 1480 advmss 1420 hoplimit 4294967295 unreachable ::/96 dev lo metric 1024 error -101 mtu 65536 advmss 65476 hoplimit 4294967295 unreachable ::ffff:0.0.0.0/96 dev lo metric 1024 error -101 mtu 65536 advmss 65476 hoplimit 4294967295 unreachable 2002:a00::/24 dev lo metric 1024 error -101 mtu 65536 advmss 65476 hoplimit 4294967295 unreachable 2002:7f00::/24 dev lo metric 1024 error -101 mtu 65536 advmss 65476 hoplimit 4294967295 unreachable 2002:a9fe::/32 dev lo metric 1024 error -101 mtu 65536 advmss 65476 hoplimit 4294967295 unreachable 2002:ac10::/28 dev lo metric 1024 error -101 mtu 65536 advmss 65476 hoplimit 4294967295 unreachable 2002:c0a8::/32 dev lo metric 1024 error -101 mtu 65536 advmss 65476 hoplimit 4294967295 unreachable 2002:e000::/19 dev lo metric 1024 error -101 mtu 65536 advmss 65476 hoplimit 4294967295 2a01:238:4317:d800::feed dev eth0 proto kernel metric 256 mtu 1500 advmss 1440 hoplimit 4294967295 2a01:238:4317:d800:0:bad:a55:cafe dev eth0 proto kernel metric 256 mtu 1500 advmss 1440 hoplimit 4294967295 2a01:238:4317:d800:cafe:dead:beef:0 dev eth0 proto kernel metric 256 mtu 1500 advmss 1440 hoplimit 4294967295 2a01:238:4317:d800:d108:898c:628f:a199 dev eth0 proto kernel metric 256 mtu 1500 advmss 1440 hoplimit 4294967295 2a01:238:4317:d800::/56 dev eth0 proto kernel metric 256 mtu 1500 advmss 1440 hoplimit 4294967295 unreachable 3ffe:ffff::/32 dev lo metric 1024 error -101 mtu 65536 advmss 65476 hoplimit 4294967295 fe80::/64 dev eth0 proto kernel metric 256 mtu 1500 advmss 1440 hoplimit 4294967295 default via 2a01:238:4317:d800::1 dev eth0 metric 1 mtu 1500 advmss 1440 hoplimit 4294967295
Ping到google返回:
[root@cp ~]# ping6 ipv6.google.com -c 6 PING ipv6.google.com(ham02s13-in-x07.1e100.net) 56 data bytes From 2a01:238:4317:d800:cafe:dead:beef:0 icmp_seq=2 Destination unreachable: Address unreachable From 2a01:238:4317:d800:cafe:dead:beef:0 icmp_seq=3 Destination unreachable: Address unreachable From 2a01:238:4317:d800:cafe:dead:beef:0 icmp_seq=4 Destination unreachable: Address unreachable From 2a01:238:4317:d800:cafe:dead:beef:0 icmp_seq=5 Destination unreachable: Address unreachable From 2a01:238:4317:d800:cafe:dead:beef:0 icmp_seq=6 Destination unreachable: Address unreachable --- ipv6.google.com ping statistics --- 6 packets transmitted, 0 received, +5 errors, 100% packet loss, time 15001ms
最好的办法是检查您是否可以从服务器上与IPv6网站(如ipv6.google.com)交谈。 这将帮助您确定问题是本地configuration还是IPv6连接 – 如果可以Ping远程IPv6站点,问题可能是您的防火墙或HTTP守护进程,但是如果您不能,则是连接。
你有一个路由地址。 所以,这可能是您的主机或您的过境提供商的问题,或其他地方的路由问题。
在撰写本文的时候,我不能从我的HE.net隧道ping你的服务器。
鉴于更新的信息,还有一些我记得我遗漏了。 如果你已经明确地configuration了地址(也就是说不是由RA自动configuration的),看起来好像是因为地址是助记符,而我在你的静态configuration中看到它,它可能不知道它的网关configuration。 configuration的方式取决于你的分配,但是应该在你configurationIP的地方旁边。
对于你的,你只需要添加一行ifcfg-eth0:
IPV6_DEFAULTGW=2a01:238:4317:d800::1
如果是别的东西,请用正确的网关replace该地址。 检查您是否也可以使用ping6来ping通该网关。
比较起来,它看起来像你的发行版本不会为你configuration的静态地址添加一个本地networking路由(也就是说,它找不到网关)。 因此,您需要将其添加到/etc/sysconfig/network-scripts/route6-eth0 :
2a01:238:4317:d800::/56 dev eth0