You need to enable JavaScript to run this app.
Elastic Compute Service

Elastic Compute Service

Copy page
Download PDF
IPv6 address
Configuring private IPv6 addresses for ECS instances
Copy page
Download PDF
Configuring private IPv6 addresses for ECS instances
Applicable scenarios​
After you assign an IPv6 address to the primary or secondary network interface of an ECS instance, the ECS image may not be able to identify the IPv6 address. You need to log in to the ECS instance and configure the IPv6 address manually.​
Prerequisites​
  • You have assigned IPv6 addresses to primary or secondary network interfaces associated with the ECS instance. Otherwise, assign an IPv6 address first. For more information, refer to Assigning IPv6 addresses.​
  • If ECS images cannot recognize the secondary private IPv6 address, log in to the ECS instance and execute the command for viewing IP addresses for the private IPv6 address of the secondary network interface.​
tip​
Commands for viewing IP addresses:​
  • Linux: Execute the ip address show command in the command line.​
  • Windows: Execute the ipconfig command in the command line.​
Procedure​
​
CentOS
Ubuntu
Debian/veLinux
Windows
​
Steps for CentOS 7.9:​
  1. Log in to an ECS instance via remote connection. For more information, refer to Logging in to instances.​
  1. Execute the following command to open the configuration file for the network interface.​
  • ​
    vi /etc/sysconfig/network-scripts/ifcfg-eth1​
    ​
tip​
eth1 is the newly configured network interface.​
  1. Press the i to enter edit mode. Confirm whether the file contains the following content. If not, input the following content:​
  • ​
    DHCPV6C=yes​
    IPV6INIT=yes​
    ​
  1. Press Esc to exit the edit mode, input :wq and press Enter.​
  1. Execute reboot command to restart the ECS instance.​
  1. Execute ip address show command to view the configuration updates.​
  • As shown in the following figure, the IPv6 address of the secondary network interface is identified.​
  • ​​​
​
​
Last updated: 2026.06.18 17:49:50