내 로컬 네트워크는 간단합니다.
sudo ifconfig
enp3s0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 192.168.31.52 netmask 255.255.255.0 broadcast 192.168.31.255
inet6 fe80::e23f:49ff:fe57:4bd1 prefixlen 64 scopeid 0x20<link>
ether txqueuelen 1000 (Ethernet)
RX packets 934205 bytes 918638128 (876.0 MiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 557104 bytes 69517532 (66.2 MiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536
inet 127.0.0.1 netmask 255.0.0.0
inet6 ::1 prefixlen 128 scopeid 0x10<host>
loop txqueuelen 1 (Local Loopback)
RX packets 2773 bytes 4761793 (4.5 MiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 2773 bytes 4761793 (4.5 MiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
ssh -vv -6 2001:19f0:5401:1cda:5400:02ff:fe8c:056f%enp3s0
OpenSSH_7.4p1 Debian-10+deb9u7, OpenSSL 1.0.2u 20 Dec 2019
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 19: Applying options for *
debug2: resolving "2001:19f0:5401:1cda:5400:02ff:fe8c:056f%enp3s0" port 22
ssh: Could not resolve hostname 2001:19f0:5401:1cda:5400:02ff:fe8c:056f%enp3s0: Name or service not known
sudo ip -6 addr add 2001:19f0:5401:1cda:5400:02ff:fe8c:056f/128 dev enp3s0
ssh -vv -6 2001:19f0:5401:1cda:5400:02ff:fe8c:056f%enp3s0
OpenSSH_7.4p1 Debian-10+deb9u7, OpenSSL 1.0.2u 20 Dec 2019
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 19: Applying options for *
debug2: resolving "2001:19f0:5401:1cda:5400:02ff:fe8c:056f%enp3s0" port 22
ssh: Could not resolve hostname 2001:19f0:5401:1cda:5400:02ff:fe8c:056f%enp3s0: Name or service not known
답변1
짧은 답변:
공용 IPv6을 정의해야 합니다.
긴 답변:
2001:0db8:0001:0001::0/64
귀하가 공용 IP(실제로는 공용 IPV6 네트워크)를 가지고 있다고 가정하고 귀하의 ISP가 귀하에게 IP를 제공했다고 가정합니다 .
이제 시도해 보세요.
sudo ip -6 addr add 2001:0db8:0001:0001::0022/128 dev enp3s0
로컬호스트에서. (교체 값 및 네트워크 인터페이스)
"내부적으로" 테스트할 수는 없다는 점에 유의하세요. (인터넷 제공업체가 2개인 경우에는 저장할 수 없습니다.) 인터넷에서 온라인 테스트 ipv6 도구를 사용할 수 있습니다.
다음 명령을 사용하여 ipv6 연결을 확인할 수 있습니다.
ping -I enp3s0 ipv6.google.com