Adding IPv6 Addresses to Your Linux Server

We initially assign 16 Internet Protocol version 6 (IPv6) addresses to your Linux server. If you need additional IPv6 addresses, you must configure your server to recognize them.

To Add IPv6 Addresses to Your Linux Server

  1. Connect to your server via SSH (more info).
  2. Switch to the root user (more info).
  3. Edit the /etc/sysconfig/network-scripts/ifcfg-lo network configuration file. This is an example of pre-allocated addresses:
    IPV6ADDR_SECONDARIES="FD60:DAD1:0101:0C00:8DD0:0000:0000:0001/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:0002/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:0003/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:0004/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:0005/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:0006/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:0007/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:0008/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:0009/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:000A/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:000B/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:000C/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:000D/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:000E/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:000F/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:0010/128"
  4. Append additional addresses to the end of the list. For example, to add three IP addresses, add the following three lines:

    FD60:DAD1:0101:0C00:8DD0:0000:0000:0011/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:0012/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:0013/128

    The resulting configuration file displays:

    IPV6ADDR_SECONDARIES="FD60:DAD1:0101:0C00:8DD0:0000:0000:0001/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:0002/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:0003/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:0004/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:0005/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:0006/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:0007/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:0008/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:0009/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:000A/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:000B/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:000C/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:000D/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:000E/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:000F/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:0010/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:0011/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:0012/128 \
    FD60:DAD1:0101:0C00:8DD0:0000:0000:0013/128"

    Note: The back-slash puts each entry on its own line. The last entry has a quotation mark at the end. Place any new entries inside the quotation mark.

  5. To restart the network, run the following command:
    /etc/init.d/network restart
  6. Optional: To view the configured IPv6 addresses, run the following command:
    ip -6 addr show lo

Was dit artikel nuttig?
Hartelijk dank voor je feedback. Gebruik het supporttelefoonnummer of de bovenstaande chatoptie als je een vertegenwoordiger van de afdeling Klantenondersteuning wilt spreken.
Fijn dat we konden helpen! Kunnen we nog iets voor je doen?
Dat spijt ons. Vertel ons wat je verwarrend vond of waarom je probleem niet is opgelost via de geboden oplossing.