当前位置:网站首页>Tencent cloud CVM starts IPv6

Tencent cloud CVM starts IPv6

2022-06-24 02:54:00 K8s Getting Started tutorial

One article can be understood in Tencent cloud CVM Upper opening IPv6, just 7 Step .

precondition

at present IPv6/IPv4 Double stack VPC The function is under internal test , If necessary , Please submit Internal test application .

Second batch , Just apply for , Will be automatically approved .

1. by VPC Distribute IPv6 CIDR

stay Private networks The menu , Choose a network , edit IPv6 CIDR, by VPC Allocate one IPv6 Network segment .

Click... In the pop-up window obtain IPv6 CIDR

2. Assign... To subnets IPv6 CIDR

Choose the above VPC A subnet in , Click on obtain IPv6 CIDR

3. CVM To configure IPv6 Address

If the ECS is not allocated at the time of purchase IPv6 Address , Under the operation bar of the corresponding ECS instance , choice 【 more 】>【IP/ network card 】>【 management IPv6 Address 】, Assign to the primary network card IPv6 Address .

4. For Cloud Server IPv6 The address is open to the public network

Under the directory on the left , choice 【IP With the network card 】>【 Elastic public network IPv6】, Click on 【 apply 】.

5. To configure CVM Operating system IPv6

According to operating system version , Reference documents To configure CVM Operating system IPv6, Select the corresponding method to configure .

Here are CentOS 7 Configuration example for .

vim /etc/sysconfig/network-scripts/ifcfg-eth0

Add a new line of configuration DHCPV6C=yes, It can automatically get IPv6 Address .

Next , Add default IPv6 Static routing

vim /etc/sysconfig/network-scripts/route6-eth0

Add a new line of configuration default dev eth0 via fe80::feee:ffff:feff:ffff

Restart the network .

systemctl restart network

see IPv6 Whether the address is configured successfully .

# ifconfig eth0
eth0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 10.11.0.7  netmask 255.255.255.0  broadcast 10.12.0.255
        inet6 2402:4e00:1111:2222:0:3333:4444:6666  prefixlen 128  scopeid 0x0<global>
        inet6 fe80::5054:ff:ee3a:dbb  prefixlen 64  scopeid 0x20<link>
        ether 12:54:00:3a:0d:bb  txqueuelen 1000  (Ethernet)
        RX packets 32022 bytes 6859648 (3.8 GiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 618586  bytes 6421714 (8.0 GiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

6. To configure IPv6 Security group rules for

Security group exit policy release .

The source address is ::/0

7. Test connectivity

from cvm ping external ipv6 website , confirm IPv6 The network can go out .

# ping6 ipv6.ipw.cn
PING ipv6.ipw.cn(2402:4e00:1013:e500:0:940e:29d7:3443 (2402:4e00:1013:e500:0:940e:29d7:3443)) 56 data bytes
64 bytes from 2402:4e00:1013:e500:0:940e:29d7:3443 (2402:4e00:1013:e500:0:940e:29d7:3443): icmp_seq=1 ttl=55 time=30.7 ms
64 bytes from 2402:4e00:1013:e500:0:940e:29d7:3443 (2402:4e00:1013:e500:0:940e:29d7:3443): icmp_seq=2 ttl=55 time=30.7 ms
64 bytes from 2402:4e00:1013:e500:0:940e:29d7:3443 (2402:4e00:1013:e500:0:940e:29d7:3443): icmp_seq=3 ttl=55 time=30.7 ms
64 bytes from 2402:4e00:1013:e500:0:940e:29d7:3443 (2402:4e00:1013:e500:0:940e:29d7:3443): icmp_seq=4 ttl=55 time=30.8 ms
64 bytes from 2402:4e00:1013:e500:0:940e:29d7:3443 (2402:4e00:1013:e500:0:940e:29d7:3443): icmp_seq=5 ttl=55 time=30.8 ms

Get local IPv6 Address

# curl ipv6.ipw.cn
240e:1f:1::1

Of course , Or online IPv6 Ping Testing tools Inspection .

Besides , adopt IPv6 Address query tool You can query the corresponding IPv6 The geographical location of the address .

adopt IPv6 Website speed measurement tool , verification IPv6 Website access speed .

adopt IPv6 Website detection tool , Website confirmation IPv6 Is it open normally .

reference

原网站

版权声明
本文为[K8s Getting Started tutorial]所创,转载请带上原文链接,感谢
https://yzsam.com/2021/10/20211024144915429o.html