<div id="docs-body">
 <div class="section">
  <div class="titlepage">
   <div>
    <div>
     <h4 class="title">
      <a name="show-replicas">
      </a>
      15.7.7.36 SHOW REPLICAS Statement
     </h4>
    </div>
   </div>
  </div>
  <a class="indexterm" name="idm46045169370768">
  </a>
  <div class="copytoclipboard-wrapper">
   <pre class="programlisting one-line language-sql"><div class="docs-select-all right" id="sa67801168"><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 keyword">SHOW</span> <span class="token keyword">REPLICAS</span></code></pre>
  </div>
  <p>
   Displays a list of replicas currently registered with the
        source.
   <code class="literal">
    SHOW REPLICAS
   </code>
   requires the
   <a class="link" href="privileges-provided.html#priv_replication-slave">
    <code class="literal">
     REPLICATION SLAVE
    </code>
   </a>
   privilege.
  </p>
  <p>
   <code class="literal">
    SHOW REPLICAS
   </code>
   should be executed on a server
        that acts as a replication source. The statement displays
        information about servers that are or have been connected as
        replicas, with each row of the result corresponding to one
        replica server, as shown here:
  </p>
  <div class="copytoclipboard-wrapper">
   <pre class="programlisting language-sql"><div class="docs-select-all right" id="sa58843368"><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">SHOW</span> <span class="token keyword">REPLICAS</span><span class="token punctuation">;</span>
<span class="token output"><span class="token punctuation">+</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">+</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">+</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">+</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">+</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">+</span></span>
<span class="token output"><span class="token punctuation">|</span> Server_id  <span class="token punctuation">|</span> Host      <span class="token punctuation">|</span> Port <span class="token punctuation">|</span> Source_id <span class="token punctuation">|</span> Replica_UUID                         <span class="token punctuation">|</span></span>
<span class="token output"><span class="token punctuation">+</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">+</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">+</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">+</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">+</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">+</span></span>
<span class="token output"><span class="token punctuation">|</span>         10 <span class="token punctuation">|</span> iconnect2 <span class="token punctuation">|</span> 3306 <span class="token punctuation">|</span>         3 <span class="token punctuation">|</span> 14cb6624<span class="token punctuation">-</span>7f93<span class="token punctuation">-</span>11e0<span class="token punctuation">-</span>b2c0<span class="token punctuation">-</span>c80aa9429562 <span class="token punctuation">|</span></span>
<span class="token output"><span class="token punctuation">|</span>         21 <span class="token punctuation">|</span> athena    <span class="token punctuation">|</span> 3306 <span class="token punctuation">|</span>         3 <span class="token punctuation">|</span> 07af4990<span class="token punctuation">-</span>f41f<span class="token punctuation">-</span>11df<span class="token punctuation">-</span>a566<span class="token punctuation">-</span>7ac56fdaf645 <span class="token punctuation">|</span></span>
<span class="token output"><span class="token punctuation">+</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">+</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">+</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">+</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">+</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">-</span><span class="token punctuation">+</span></span></code></pre>
  </div>
  <div class="itemizedlist">
   <ul class="itemizedlist" style="list-style-type: disc; ">
    <li class="listitem">
     <p>
      <code class="literal">
       Server_id
      </code>
      : The unique server ID of the
            replica server, as configured in the replica server's
            option file, or on the command line with
      <a class="link" href="replication-options.html#sysvar_server_id">
       <code class="option">
        --server-id=
        <em class="replaceable">
         <code>
          value
         </code>
        </em>
       </code>
      </a>
      .
     </p>
    </li>
    <li class="listitem">
     <p>
      <code class="literal">
       Host
      </code>
      : The host name of the replica
            server, as specified on the replica with the
      <a class="link" href="replication-options-replica.html#sysvar_report_host">
       <code class="option">
        --report-host
       </code>
      </a>
      option. This
            can differ from the machine name as configured in the
            operating system.
     </p>
    </li>
    <li class="listitem">
     <p>
      <code class="literal">
       User
      </code>
      : The replica server user name, as
            specified on the replica with the
      <a class="link" href="replication-options-replica.html#sysvar_report_user">
       <code class="option">
        --report-user
       </code>
      </a>
      option.
            Statement output includes this column only if the source
            server is started with the
      <a class="link" href="replication-options-source.html#option_mysqld_show-replica-auth-info">
       <code class="option">
        --show-replica-auth-info
       </code>
      </a>
      option.
     </p>
    </li>
    <li class="listitem">
     <p>
      <code class="literal">
       Password
      </code>
      : The replica server password, as
            specified on the replica with the
      <a class="link" href="replication-options-replica.html#sysvar_report_password">
       <code class="option">
        --report-password
       </code>
      </a>
      option.
            Statement output includes this column only if the source
            server is started with the
      <a class="link" href="replication-options-source.html#option_mysqld_show-replica-auth-info">
       <code class="option">
        --show-replica-auth-info
       </code>
      </a>
      option.
     </p>
    </li>
    <li class="listitem">
     <p>
      <code class="literal">
       Port
      </code>
      : The port on the source to which the
            replica server is listening, as specified on the replica
            with the
      <a class="link" href="replication-options-replica.html#sysvar_report_port">
       <code class="option">
        --report-port
       </code>
      </a>
      option.
     </p>
     <p>
      A zero in this column means that the replica port
            (
      <a class="link" href="replication-options-replica.html#sysvar_report_port">
       <code class="option">
        --report-port
       </code>
      </a>
      ) was not set.
     </p>
    </li>
    <li class="listitem">
     <p>
      <code class="literal">
       Source_id
      </code>
      : The unique server ID of the
            source server that the replica server is replicating from.
            This is the server ID of the server on which
      <code class="literal">
       SHOW
            REPLICAS
      </code>
      is executed, so this same value is listed
            for each row in the result.
     </p>
    </li>
    <li class="listitem">
     <p>
      <a class="indexterm" name="idm46045169340224">
      </a>
      <code class="literal">
       Replica_UUID
      </code>
      : The globally unique ID of
            this replica, as generated on the replica and found in the
            replica's
      <code class="filename">
       auto.cnf
      </code>
      file.
     </p>
    </li>
   </ul>
  </div>
 </div>
 <br/>
</div>
