编辑:通过切换互联网服务提供商来修复 ́\(°_o)/̊
我有一个恼人的问题,当我的网络上的一些机器会挂起时抬头看连接到某些 IPv6 地址,特别是来自 Google 的地址(但我在启用 IPv6 的网络上也看到了其他地址的问题)。
sadbox $ ping -6c1 -W10 fonts.googleapis.com
PING fonts.googleapis.com(arn09s11-in-x0a.1e100.net (2a00:1450:400f:807::200a)) 56 data bytes
--- fonts.googleapis.com ping statistics ---
1 packets transmitted, 0 received, 100% packet loss, time 0ms
sadbox $ ssh happybox
Last login: Wed Apr 25 10:28:48 2018 from 192.168.1.140
happybox $ ping -6c1 -W10 fonts.googleapis.com
PING fonts.googleapis.com(arn09s11-in-x0a.1e100.net (2a00:1450:400f:807::200a)) 56 data bytes
64 bytes from arn09s11-in-x0a.1e100.net (2a00:1450:400f:807::200a): icmp_seq=1 ttl=55 time=25.6 ms
--- fonts.googleapis.com ping statistics ---
1 packets transmitted, 1 received, 0% packet loss, time 0ms
rtt min/avg/max/mdev = 25.675/25.675/25.675/0.000 ms
host fonts.googleapis.com
两者对和nslookup fonts.googleapis.com
以及 输出的相关部分给出了完全相同的答案dig
。
有时,主机会正常连接sadbox
,有时,如果我等待足够长的时间,我会得到响应。
受影响的不仅仅是 ping,我注意到这一点是因为 Firefox 在某些网站上永远等待着 fonts.googleapis.com。
这http://test-ipv6.com/网站给出了满分sadbox
,我可以 ping 并连接到其他 IPv6 地址(例如 Sixxs.net)。
我所有的电脑都在运行Xubuntu 17.10,并且路由器正在运行LEDE 重启(17.01.4,r3560-79f57e422d)。
可能是什么问题?我该如何调试这样的东西?
编辑: 的内容sadbox:/etc/nsswitch.conf
,注释行已删除:
passwd: compat
group: compat
shadow: compat
hosts: files mdns4_minimal [NOTFOUND=return] dns mdns4
networks: files
protocols: db files
services: db files
ethers: db files
rpc: db files
netgroup: nis
并比较happybox
:
sadbox $ diff /etc/nsswitch.conf <(ssh -q happybox cat /etc/nsswitch.conf)
11c11
< hosts: files mdns4_minimal [NOTFOUND=return] dns mdns4
---
> hosts: files mdns4_minimal [NOTFOUND=return] dns myhostname
EDIT2:Ping 也挂在 IP 上,例如ping -6 2a00:1450:400f:807::200a
,所以这不是 DNS,而是 IPv6 传输问题(感谢 Patrick Mevzek!)。一旦我回到网络,我就会获得跟踪路由。
追踪路线:
从路由器本身来看,它工作正常:
sadbox $ ssh ruter traceroute6 fonts.googleapis.com
traceroute to fonts.googleapis.com (2a00:1450:400f:807::200a), 30 hops max, 16 byte packets
1 2a02:fe0:c900:1::1 (2a02:fe0:c900:1::1) 4.753 ms 5.894 ms 5.709 ms
2 2a02:fe0::a:47:a:13:4 (2a02:fe0::a:47:a:13:4) 5.944 ms 8.850 ms 14.108 ms
3 ae11-0.poh-pe1.stv.no.ip.tdc.net (2a02:228:41:100::127:0:9) 26.056 ms 15.009 ms 14.018 ms
4 stkm3nqp7.se.ip.tdc.net (2001:6c8:40::20) 22.371 ms 22.220 ms 21.974 ms
5 peer-as15169.stkm3nqp7.se.ip.tdc.net (2001:6c8:81:2000::9) 24.504 ms 25.047 ms 28.025 ms
6 2001:4860:0:1344::1 (2001:4860:0:1344::1) 26.118 ms 23.686 ms 24.075 ms
7 2001:4860:0:1::15cf (2001:4860:0:1::15cf) 22.793 ms 24.702 ms 23.859 ms
8 arn09s11-in-x0a.1e100.net (2a00:1450:400f:807::200a) 25.886 ms 35.837 ms 36.413 ms
另一台工作计算机给出的结果大致相同:
sadbox $ ssh happybox traceroute6 fonts.googleapis.com
traceroute to ���2>V (2a00:1450:400f:807::200a) from 2a02:fe0:c910:5120:8011:3799:6dc0:2b58, 30 hops max, 24 byte packets
1 2a02:fe0:c910:5120::1 (2a02:fe0:c910:5120::1) 1,123 ms 1,247 ms 3,537 ms
2 2a02:fe0:c900:1::1 (2a02:fe0:c900:1::1) 6,958 ms 9,566 ms 6,955 ms
3 2a02:fe0:0:a:47:a:13:4 (2a02:fe0:0:a:47:a:13:4) 9,985 ms 6,303 ms 8,719 ms
4 ae11-0.poh-pe1.stv.no.ip.tdc.net (2a02:228:41:100:0:127:0:9) 6,811 ms 6,304 ms 6,741 ms
5 stkm3nqp7.se.ip.tdc.net (2001:6c8:40::20) 25,882 ms 26,625 ms 27,079 ms
6 peer-as15169.stkm3nqp7.se.ip.tdc.net (2001:6c8:81:2000::9) 27,169 ms 28,319 ms 28,931 ms
7 2001:4860:0:1343::1 (2001:4860:0:1343::1) 46,643 ms 28,799 ms 25,976 ms
8 2001:4860:0:1::b23 (2001:4860:0:1::b23) 29,373 ms 37,344 ms 28,207 ms
9 arn09s11-in-x0a.1e100.net (2a00:1450:400f:807::200a) 27,72 ms 26,274 ms 27,764 ms
但从sadbox
不太好:
sadbox $ traceroute6 fonts.googleapis.com
traceroute to ���V (2a00:1450:400f:807::200a) from 2a02:fe0:c910:5120:95b:58:ab20:d31e, 30 hops max, 24 byte packets
1 2a02:fe0:c910:5120::1 (2a02:fe0:c910:5120::1) 4,095 ms 4,632 ms 1,558 ms
2 2a02:fe0:c900:1::1 (2a02:fe0:c900:1::1) 11,822 ms 15,528 ms 10,568 ms
3 2a02:fe0:0:a:47:a:13:2 (2a02:fe0:0:a:47:a:13:2) 8,823 ms 6,119 ms 10,068 ms
4 * * *
5 * * *
6 * * *
7 * * *
8 * * *
9 * * *
10 * * *
11 * * *
12 * * *
13 * * *
14 * * *
15 * * *
16 * * *
17 *
– 它一直给我星星(还有,那是怎么回事���V
?)。 A sudo traceroute -6 -T
fromsadbox
给出相同的结果。
IPv4traceroute -4
在所有机器上都能正常工作,包括sadbox
.
这是来自工作机器的 mtr:
sadbox $ ssh happybox mtr --report fonts.googleapis.com
Start: Tue May 1 20:41:57 2018
HOST: happybox Loss% Snt Last Avg Best Wrst StDev
1.|-- 2a02:fe0:c910:5120::1 0.0% 10 0.7 1.0 0.7 2.3 0.5
2.|-- 2a02:fe0:c900:1::1 0.0% 10 7.4 9.0 6.2 14.2 2.6
3.|-- 2a02:fe0:0:a:47:a:13:4 0.0% 10 7.4 8.0 5.6 11.9 1.9
4.|-- ae11-0.poh-pe1.stv.no.ip. 0.0% 10 7.8 8.2 6.2 10.9 1.3
5.|-- stkm3nqp7.se.ip.tdc.net 0.0% 10 29.3 26.8 24.8 29.4 1.6
6.|-- peer-as15169.stkm3nqp7.se 0.0% 10 25.9 40.6 24.6 135.7 34.8
7.|-- 2001:4860:0:1344::1 0.0% 10 63.9 35.4 26.1 63.9 13.8
8.|-- 2001:4860:0:1::15cf 0.0% 10 26.1 28.1 24.7 36.4 3.2
9.|-- arn09s11-in-x0a.1e100.net 0.0% 10 26.7 26.8 24.8 31.4 1.9
而穷人sadbox
仍然没有利润:
sadbox $ mtr --report fonts.googleapis.com
Start: Tue May 1 20:35:59 2018
HOST: sadbox Loss% Snt Last Avg Best Wrst StDev
1.|-- 2a02:fe0:c910:5120::1 0.0% 10 1.9 27.3 0.6 134.6 55.7
2.|-- 2a02:fe0:c900:1::1 0.0% 10 96.6 33.6 6.0 96.6 32.1
3.|-- 2a02:fe0:0:a:47:a:13:2 0.0% 10 7.8 8.0 6.4 14.0 2.1
4.|-- ??? 100.0 10 0.0 0.0 0.0 0.0 0.0