我有一台已经运行静态 ipv6 多年的 imac;我正在致力于向客户部署 ipv6,并将测试路由器的 lan 端插入 imac 上的 usb 以太网接口,该接口正确地从测试路由器获取委派地址,并从中获取链路本地默认路由:
en5: flags=8863<UP,BROADCAST,SMART,RUNNING,SIMPLEX,MULTICAST> mtu 1500
options=4<VLAN_MTU>
ether d0:37:45:b8:f3:64
inet 192.168.1.10 netmask 0xffffff00 broadcast 192.168.1.255
inet6 fe80::1427:aee3:e9e5:138%en5 prefixlen 64 secured scopeid 0xf
inet6 2607:f678:2fff::843:5ec6:8b74:9785 prefixlen 64 autoconf secured
netstat -rn:
...
Internet6:
Destination Gateway Flags Netif Expire
default 2607:f678:1::1 UGSc en0
default fe80::%utun0 UGcI utun0
default fe80::4a77:46ff:fef9:5bb3%en5 UGcI en5
...
当我删除真正的默认路由(en0)时,ipv6 访问立即获得“没有到主机的路由”(即不是来自上游,而是第一跳):
# traceroute6 google.com
connect: No route to host
网关可 ping 通:
# ping6 fe80::4a77:46ff:fef9:5bb3%en5
PING6(56=40+8+8 bytes) fe80::1427:aee3:e9e5:138%en5 --> fe80::4a77:46ff:fef9:5bb3%en5
16 bytes from fe80::4a77:46ff:fef9:5bb3%en5, icmp_seq=0 hlim=64 time=0.708 ms
16 bytes from fe80::4a77:46ff:fef9:5bb3%en5, icmp_seq=1 hlim=64 time=0.638 ms
^C
我尝试删除 utun0 路由以防它试图使用该路由,但是得到:
# route delete -inet6 default fe80::%utun0
route: writing to routing socket: not in table
delete net default: gateway fe80::%utun0: not in table
我不确定这里缺少什么......