d7c3f88004
Change-Id: I78e99862dbf16829342d4e618f09e5d75b6debdf
72 lines
4.0 KiB
XML
72 lines
4.0 KiB
XML
<section xmlns="http://docbook.org/ns/docbook" xmlns:xi="http://www.w3.org/2001/XInclude"
|
|
xmlns:xlink="http://www.w3.org/1999/xlink" version="5.0"
|
|
xml:id="section_configuring-compute-to-use-ipv6-addresses">
|
|
<title>Configure Compute to use IPv6 addresses</title>
|
|
<para>If you are using OpenStack Compute with
|
|
<systemitem>nova-network</systemitem>, you can put Compute into dual-stack
|
|
mode, so that it uses both IPv4 and IPv6 addresses for communication. In
|
|
dual-stack mode, instances can acquire their IPv6 global unicast address
|
|
by using a stateless address auto-configuration mechanism [RFC 4862/2462].
|
|
IPv4/IPv6 dual-stack mode works with both <literal>VlanManager</literal>
|
|
and <literal>FlatDHCPManager</literal> networking modes.
|
|
</para>
|
|
<para>In <literal>VlanManager</literal> networking mode, each project uses a
|
|
different 64-bit global routing prefix. In
|
|
<literal>FlatDHCPManager</literal> mode, all instances use one 64-bit
|
|
global routing prefix.
|
|
</para>
|
|
<para>This configuration was tested with virtual machine images that have an
|
|
IPv6 stateless address auto-configuration capability. This capability is
|
|
required for any VM to run with an IPv6 address. You must use an EUI-64
|
|
address for stateless address auto-configuration. Each node that executes
|
|
a <literal>nova-*</literal> service must have
|
|
<literal>python-netaddr</literal> and <literal>radvd</literal> installed.
|
|
</para>
|
|
<procedure>
|
|
<title>Switch into IPv4/IPv6 dual-stack mode</title>
|
|
<step>
|
|
<para>For every node running a <literal>nova-*</literal> service,
|
|
install <systemitem>python-netaddr</systemitem>:
|
|
</para>
|
|
<screen><prompt>#</prompt> <userinput>apt-get install python-netaddr</userinput></screen>
|
|
</step>
|
|
<step>
|
|
<para>For every node running <literal>nova-network</literal>, install
|
|
<literal>radvd</literal> and configure IPv6 networking:
|
|
</para>
|
|
<screen><prompt>#</prompt> <userinput>apt-get install radvd</userinput>
|
|
<prompt>#</prompt> <userinput>echo 1 > /proc/sys/net/ipv6/conf/all/forwarding</userinput>
|
|
<prompt>#</prompt> <userinput>echo 0 > /proc/sys/net/ipv6/conf/all/accept_ra</userinput></screen>
|
|
</step>
|
|
<step>
|
|
<para>On all nodes, edit the <filename>nova.conf</filename> file and
|
|
specify <literal>use_ipv6 = True</literal>.</para>
|
|
</step>
|
|
<step>
|
|
<para>Restart all <literal>nova-*</literal> services.</para>
|
|
</step>
|
|
</procedure>
|
|
<note>
|
|
<para>You can add a fixed range for IPv6 addresses to the <command>nova network-create</command>
|
|
command. Specify <option>public</option> or <option>private</option> after the
|
|
<parameter>network-create</parameter> parameter.
|
|
</para>
|
|
<screen><prompt>$</prompt> <userinput>nova network-create public --fixed-range-v4 <replaceable>FIXED_RANGE_V4</replaceable> --vlan <replaceable>VLAN_ID</replaceable> --vpn <replaceable>VPN_START</replaceable> --fixed-range-v6 <replaceable>FIXED_RANGE_V6</replaceable></userinput></screen>
|
|
<para>You can set the IPv6 global routing prefix by using the
|
|
<parameter>--fixed_range_v6</parameter> parameter. The default value for
|
|
the parameter is <literal>fd00::/48</literal>.
|
|
</para>
|
|
<para>When you use <literal>FlatDHCPManager</literal>, the command
|
|
uses the original <parameter>--fixed_range_v6</parameter> value. For
|
|
example:
|
|
</para>
|
|
<screen><prompt>$</prompt> <userinput>nova network-create public --fixed-range-v4 10.0.2.0/24 --fixed-range-v6 fd00:1::/48</userinput></screen>
|
|
<para>When you use <literal>VlanManager</literal>, the command increments
|
|
the subnet ID to create subnet prefixes. Guest VMs use this prefix to
|
|
generate their IPv6 global unicast address. For example:
|
|
</para>
|
|
<screen><prompt>$</prompt> <userinput>nova network-create public --fixed-range-v4 10.0.1.0/24 --vlan 100 --vpn 1000 --fixed-range-v6 fd00:1::/48</userinput></screen>
|
|
</note>
|
|
<xi:include href="../../common/tables/nova-ipv6.xml"/>
|
|
</section>
|