<div id="docs-body">
 <div class="section">
  <div class="titlepage">
   <div>
    <div>
     <h3 class="title">
      <a name="ipv6-support">
      </a>
      7.1.13 IPv6 Support
     </h3>
    </div>
   </div>
  </div>
  <div class="toc">
   <dl class="toc">
    <dt>
     <span class="section">
      <a href="ipv6-system-support.html">
       7.1.13.1 Verifying System Support for IPv6
      </a>
     </span>
    </dt>
    <dt>
     <span class="section">
      <a href="ipv6-server-config.html">
       7.1.13.2 Configuring the MySQL Server to Permit IPv6 Connections
      </a>
     </span>
    </dt>
    <dt>
     <span class="section">
      <a href="ipv6-local-connections.html">
       7.1.13.3 Connecting Using the IPv6 Local Host Address
      </a>
     </span>
    </dt>
    <dt>
     <span class="section">
      <a href="ipv6-remote-connections.html">
       7.1.13.4 Connecting Using IPv6 Nonlocal Host Addresses
      </a>
     </span>
    </dt>
    <dt>
     <span class="section">
      <a href="ipv6-brokers.html">
       7.1.13.5 Obtaining an IPv6 Address from a Broker
      </a>
     </span>
    </dt>
   </dl>
  </div>
  <p>
   Support for IPv6 in MySQL includes these capabilities:
  </p>
  <div class="itemizedlist">
   <ul class="itemizedlist" style="list-style-type: disc; ">
    <li class="listitem">
     <p>
      MySQL Server can accept TCP/IP connections from clients
          connecting over IPv6. For example, this command connects over
          IPv6 to the MySQL server on the local host:
     </p>
     <div class="copytoclipboard-wrapper">
      <pre class="programlisting one-line language-terminal"><div class="docs-select-all right" id="sa12589945"><div class="copy-help left">Press ⌘+C to copy</div> <div class="right"><button class="clipboard-btn" title="Copy to Clipboard"><span class="icon-clipboard"></span></button></div></div><code class="language-terminal"><span class="token prompt">$&gt; </span><span class="token command">mysql</span> <span class="token property">-h</span> <span class="token punctuation">:</span><span class="token punctuation">:</span>1</code></pre>
     </div>
     <p>
      To use this capability, two things must be true:
     </p>
     <div class="itemizedlist">
      <ul class="itemizedlist" style="list-style-type: circle; ">
       <li class="listitem">
        <p>
         Your system must be configured to support IPv6. See
         <a class="xref" href="ipv6-system-support.html" title="7.1.13.1 Verifying System Support for IPv6">
          Section 7.1.13.1, “Verifying System Support for IPv6”
         </a>
         .
        </p>
       </li>
       <li class="listitem">
        <p>
         The default MySQL server configuration permits IPv6
              connections in addition to IPv4 connections. To change the
              default configuration, start the server with the
         <a class="link" href="server-system-variables.html#sysvar_bind_address">
          <code class="literal">
           bind_address
          </code>
         </a>
         system
              variable set to an appropriate value. See
         <a class="xref" href="server-system-variables.html" title="7.1.8 Server System Variables">
          Section 7.1.8, “Server System Variables”
         </a>
         .
        </p>
       </li>
      </ul>
     </div>
    </li>
    <li class="listitem">
     <p>
      MySQL account names permit IPv6 addresses to enable DBAs to
          specify privileges for clients that connect to the server over
          IPv6. See
      <a class="xref" href="account-names.html" title="8.2.4 Specifying Account Names">
       Section 8.2.4, “Specifying Account Names”
      </a>
      . IPv6 addresses can
          be specified in account names in statements such as
      <a class="link" href="create-user.html" title="15.7.1.3 CREATE USER Statement">
       <code class="literal">
        CREATE USER
       </code>
      </a>
      ,
      <a class="link" href="grant.html" title="15.7.1.6 GRANT Statement">
       <code class="literal">
        GRANT
       </code>
      </a>
      , and
      <a class="link" href="revoke.html" title="15.7.1.8 REVOKE Statement">
       <code class="literal">
        REVOKE
       </code>
      </a>
      . For example:
     </p>
     <div class="copytoclipboard-wrapper">
      <pre class="programlisting language-sql"><div class="docs-select-all right" id="sa42384473"><div class="copy-help left">Press ⌘+C to copy</div> <div class="right"><button class="clipboard-btn" title="Copy to Clipboard"><span class="icon-clipboard"></span></button></div></div><code class="language-sql"><span class="token prompt">mysql&gt;</span> <span class="token keyword">CREATE</span> <span class="token keyword">USER</span> <span class="token string">'bill'</span>@<span class="token string">'::1'</span> <span class="token keyword">IDENTIFIED</span> <span class="token keyword">BY</span> <span class="token string">'secret'</span><span class="token punctuation">;</span>
<span class="token prompt">mysql&gt;</span> <span class="token keyword">GRANT</span> <span class="token keyword">SELECT</span> <span class="token keyword">ON</span> mydb<span class="token punctuation">.</span><span class="token operator">*</span> <span class="token keyword">TO</span> <span class="token string">'bill'</span>@<span class="token string">'::1'</span><span class="token punctuation">;</span></code></pre>
     </div>
    </li>
    <li class="listitem">
     <p>
      IPv6 functions enable conversion between string and internal
          format IPv6 address formats, and checking whether values
          represent valid IPv6 addresses. For example,
      <a class="link" href="miscellaneous-functions.html#function_inet6-aton">
       <code class="literal">
        INET6_ATON()
       </code>
      </a>
      and
      <a class="link" href="miscellaneous-functions.html#function_inet6-ntoa">
       <code class="literal">
        INET6_NTOA()
       </code>
      </a>
      are similar to
      <a class="link" href="miscellaneous-functions.html#function_inet-aton">
       <code class="literal">
        INET_ATON()
       </code>
      </a>
      and
      <a class="link" href="miscellaneous-functions.html#function_inet-ntoa">
       <code class="literal">
        INET_NTOA()
       </code>
      </a>
      , but handle IPv6
          addresses in addition to IPv4 addresses. See
      <a class="xref" href="miscellaneous-functions.html" title="14.23 Miscellaneous Functions">
       Section 14.23, “Miscellaneous Functions”
      </a>
      .
     </p>
    </li>
    <li class="listitem">
     <p>
      Group Replication group members can use IPv6 addresses for
          communications within the group. A group can contain a mix of
          members using IPv6 and members using IPv4. See
      <a class="xref" href="group-replication-ipv6.html" title="20.5.5 Support For IPv6 And For Mixed IPv6 And IPv4 Groups">
       Section 20.5.5, “Support For IPv6 And For Mixed IPv6 And IPv4 Groups”
      </a>
      .
     </p>
    </li>
   </ul>
  </div>
  <p>
   The following sections describe how to set up MySQL so that
      clients can connect to the server over IPv6.
  </p>
 </div>
 <br/>
</div>
