<div id="docs-body">
 <div class="section">
  <div class="titlepage">
   <div>
    <div>
     <h4 class="title">
      <a name="performance-schema-persisted-variables-table">
      </a>
      29.12.14.1 Performance Schema persisted_variables Table
     </h4>
    </div>
   </div>
  </div>
  <a class="indexterm" name="idm46045070128864">
  </a>
  <a class="indexterm" name="idm46045070127776">
  </a>
  <p>
   The
   <a class="link" href="performance-schema-persisted-variables-table.html" title="29.12.14.1 Performance Schema persisted_variables Table">
    <code class="literal">
     persisted_variables
    </code>
   </a>
   table
          provides an SQL interface to the
   <code class="filename">
    mysqld-auto.cnf
   </code>
   file that stores
          persisted global system variable settings, enabling the file
          contents to be inspected at runtime using
   <a class="link" href="select.html" title="15.2.13 SELECT Statement">
    <code class="literal">
     SELECT
    </code>
   </a>
   statements. Variables
          are persisted using
   <a class="link" href="set-variable.html" title="15.7.6.1 SET Syntax for Variable Assignment">
    <code class="literal">
     SET
          PERSIST
    </code>
   </a>
   or
   <code class="literal">
    PERSIST_ONLY
   </code>
   statements; see
   <a class="xref" href="set-variable.html" title="15.7.6.1 SET Syntax for Variable Assignment">
    Section 15.7.6.1, “SET Syntax for Variable Assignment”
   </a>
   . The table
          contains a row for each persisted system variable in the file.
          Variables not persisted do not appear in the table.
  </p>
  <p>
   The
   <a class="link" href="privileges-provided.html#priv_sensitive-variables-observer">
    <code class="literal">
     SENSITIVE_VARIABLES_OBSERVER
    </code>
   </a>
   privilege is required to view the values of sensitive system
          variables in this table.
  </p>
  <p>
   For information about persisted system variables, see
   <a class="xref" href="persisted-system-variables.html" title="7.1.9.3 Persisted System Variables">
    Section 7.1.9.3, “Persisted System Variables”
   </a>
   .
  </p>
  <p>
   Suppose that
   <code class="filename">
    mysqld-auto.cnf
   </code>
   looks like
          this (slightly reformatted):
  </p>
  <div class="copytoclipboard-wrapper">
   <pre class="programlisting language-json"><div class="docs-select-all right" id="sa56997257"><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-json"><span class="token punctuation">{</span>
  <span class="token property">"Version"</span><span class="token operator">:</span> <span class="token number">1</span><span class="token punctuation">,</span>
  <span class="token property">"mysql_server"</span><span class="token operator">:</span> <span class="token punctuation">{</span>
    <span class="token property">"max_connections"</span><span class="token operator">:</span> <span class="token punctuation">{</span>
      <span class="token property">"Value"</span><span class="token operator">:</span> <span class="token string">"1000"</span><span class="token punctuation">,</span>
      <span class="token property">"Metadata"</span><span class="token operator">:</span> <span class="token punctuation">{</span>
        <span class="token property">"Timestamp"</span><span class="token operator">:</span> <span class="token number">1.519921706e+15</span><span class="token punctuation">,</span>
        <span class="token property">"User"</span><span class="token operator">:</span> <span class="token string">"root"</span><span class="token punctuation">,</span>
        <span class="token property">"Host"</span><span class="token operator">:</span> <span class="token string">"localhost"</span>
      <span class="token punctuation">}</span>
    <span class="token punctuation">}</span><span class="token punctuation">,</span>
    <span class="token property">"autocommit"</span><span class="token operator">:</span> <span class="token punctuation">{</span>
      <span class="token property">"Value"</span><span class="token operator">:</span> <span class="token string">"ON"</span><span class="token punctuation">,</span>
      <span class="token property">"Metadata"</span><span class="token operator">:</span> <span class="token punctuation">{</span>
        <span class="token property">"Timestamp"</span><span class="token operator">:</span> <span class="token number">1.519921707e+15</span><span class="token punctuation">,</span>
        <span class="token property">"User"</span><span class="token operator">:</span> <span class="token string">"root"</span><span class="token punctuation">,</span>
        <span class="token property">"Host"</span><span class="token operator">:</span> <span class="token string">"localhost"</span>
      <span class="token punctuation">}</span>
    <span class="token punctuation">}</span>
  <span class="token punctuation">}</span>
<span class="token punctuation">}</span></code></pre>
  </div>
  <p>
   Then
   <a class="link" href="performance-schema-persisted-variables-table.html" title="29.12.14.1 Performance Schema persisted_variables Table">
    <code class="literal">
     persisted_variables
    </code>
   </a>
   has
          these contents:
  </p>
  <div class="copytoclipboard-wrapper">
   <pre class="programlisting language-sql"><div class="docs-select-all right" id="sa87815541"><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">SELECT</span> <span class="token operator">*</span> <span class="token keyword">FROM</span> performance_schema<span class="token punctuation">.</span>persisted_variables<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>
<span class="token output"><span class="token punctuation">|</span> VARIABLE_NAME   <span class="token punctuation">|</span> VARIABLE_VALUE <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>
<span class="token output"><span class="token punctuation">|</span> autocommit      <span class="token punctuation">|</span> ON             <span class="token punctuation">|</span></span>
<span class="token output"><span class="token punctuation">|</span> max_connections <span class="token punctuation">|</span> 1000           <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></code></pre>
  </div>
  <p>
   The
   <a class="link" href="performance-schema-persisted-variables-table.html" title="29.12.14.1 Performance Schema persisted_variables Table">
    <code class="literal">
     persisted_variables
    </code>
   </a>
   table has
          these columns:
  </p>
  <div class="itemizedlist">
   <ul class="itemizedlist" style="list-style-type: disc; ">
    <li class="listitem">
     <p>
      <code class="literal">
       VARIABLE_NAME
      </code>
     </p>
     <p>
      The variable name listed in
      <code class="filename">
       mysqld-auto.cnf
      </code>
      .
     </p>
    </li>
    <li class="listitem">
     <p>
      <code class="literal">
       VARIABLE_VALUE
      </code>
     </p>
     <p>
      The value listed for the variable in
      <code class="filename">
       mysqld-auto.cnf
      </code>
      .
     </p>
    </li>
   </ul>
  </div>
  <p>
   <a class="link" href="performance-schema-persisted-variables-table.html" title="29.12.14.1 Performance Schema persisted_variables Table">
    <code class="literal">
     persisted_variables
    </code>
   </a>
   has these
          indexes:
  </p>
  <div class="itemizedlist">
   <ul class="itemizedlist" style="list-style-type: disc; ">
    <li class="listitem">
     <p>
      Primary key on (
      <code class="literal">
       VARIABLE_NAME
      </code>
      )
     </p>
    </li>
   </ul>
  </div>
  <p>
   <a class="link" href="truncate-table.html" title="15.1.37 TRUNCATE TABLE Statement">
    <code class="literal">
     TRUNCATE TABLE
    </code>
   </a>
   is not permitted
          for the
   <a class="link" href="performance-schema-persisted-variables-table.html" title="29.12.14.1 Performance Schema persisted_variables Table">
    <code class="literal">
     persisted_variables
    </code>
   </a>
   table.
  </p>
 </div>
 <br/>
</div>
