Alibaba Cloud CentOS how to add IPV6 support

  
 

Alibaba Cloud ECS disables IPV6 support by default. First, you need to enable the system's IPV6 function.

Modify the /etc/sysconfig/network file to make NETWORKING_IPV6=yes delete /etc/modprobe.d/disable_ipv6. Conf

To register an account with tunnelbroker.net and create a Regular Tunnel, you need to fill in the public IP registration of the server and go to the Example Configurations to find the automatically generated script. Here we choose Linux-route2, don't worry. Take the reminder under the

Notes page

NOTE: When behind a firewall appliance that passes protocol 41, use the IPv4 address you get from your appliance’s DHCP service instead of the IPv4 endpoint you provided to our broker. Here you need to use the intranet IP, not the public IP

so the code we want to execute should be like this modprobe ipv6ip tunnel add he-ipv6 mode sit remote 0.0 .0.0 local <your intranet IP> ttl 255ip link set he-ipv6 upip addr add 00:00:00:00::2/64 dev he-ipv6ip route add ::/0 dev he-ipv6ip -f inet6 Addr

Execution completed After you can see this he-ipv6 in ifconfig, just ping6 an address test to see if it is smooth

Note that he-ipv6 will disappear after restarting the server, you need to add this code Go to self-starting, for example /etc/rc.d/rc.local.

In addition, I also noticed a problem. I don't know if it is a case. Alibaba Cloud ECS CentOS has no write permission in the /etc and /usr/bin directories. It is very strange setting, but the default PATH is /usr/The location of local/bin is higher than /usr/bin, so the files placed in /usr/local/bin will "overwrite" the original files of the system, but many automated scripts will not run, even many programs. Can not compile normally. PS: I just want to upgrade the CURL version.

Copyright © Windows knowledge All Rights Reserved