Sophie

Sophie

distrib > Mageia > 7 > armv7hl > by-pkgid > 2b917e0437961edec048f1d15e2d7449 > files > 5879

php-manual-en-7.2.11-1.mga7.noarch.rpm

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
 <head>
  <meta http-equiv="content-type" content="text/html; charset=UTF-8">
  <title>Set system resource limits</title>

 </head>
 <body><div class="manualnavbar" style="text-align: center;">
 <div class="prev" style="text-align: left; float: left;"><a href="function.posix-setpgid.html">posix_setpgid</a></div>
 <div class="next" style="text-align: right; float: right;"><a href="function.posix-setsid.html">posix_setsid</a></div>
 <div class="up"><a href="ref.posix.html">POSIX Functions</a></div>
 <div class="home"><a href="index.html">PHP Manual</a></div>
</div><hr /><div id="function.posix-setrlimit" class="refentry">
 <div class="refnamediv">
  <h1 class="refname">posix_setrlimit</h1>
  <p class="verinfo">(PHP 7)</p><p class="refpurpose"><span class="refname">posix_setrlimit</span> &mdash; <span class="dc-title">Set system resource limits</span></p>

 </div>
 
 <div class="refsect1 description" id="refsect1-function.posix-setrlimit-description">
  <h3 class="title">Description</h3>
  <div class="methodsynopsis dc-description">
   <span class="type">bool</span> <span class="methodname"><strong>posix_setrlimit</strong></span>
    ( <span class="methodparam"><span class="type">int</span> <code class="parameter">$resource</code></span>
   , <span class="methodparam"><span class="type">int</span> <code class="parameter">$softlimit</code></span>
   , <span class="methodparam"><span class="type">int</span> <code class="parameter">$hardlimit</code></span>
   )</div>

  <p class="para rdfs-comment">
   <span class="function"><strong>posix_setrlimit()</strong></span> sets the soft and hard limits for a
   given system resource.
  </p>
  
<p class="para">
  Each resource has an associated soft and hard limit.  The soft
  limit is the value that the kernel enforces for the corresponding
  resource.  The hard limit acts as a ceiling for the soft limit.
  An unprivileged process may only set its soft limit to a value
  from 0 to the hard limit, and irreversibly lower its hard limit.
</p>

 </div>


 <div class="refsect1 parameters" id="refsect1-function.posix-setrlimit-parameters">
  <h3 class="title">Parameters</h3>
  <p class="para">
   <dl>

    
     <dt>
<code class="parameter">resource</code></dt>

     <dd>

      <p class="para">
       The
       <a href="posix.constants.setrlimit.html" class="link">resource limit constant</a>
       corresponding to the limit that is being set.
      </p>
     </dd>

    
    
     <dt>
<code class="parameter">softlimit</code></dt>

     <dd>

      <p class="para">
       The soft limit, in whatever unit the resource limit requires, or
       <strong><code>POSIX_RLIMIT_INFINITY</code></strong>.
      </p>
     </dd>

    
    
     <dt>
<code class="parameter">hardlimit</code></dt>

     <dd>

      <p class="para">
       The hard limit, in whatever unit the resource limit requires, or
       <strong><code>POSIX_RLIMIT_INFINITY</code></strong>.
      </p>
     </dd>

    
   </dl>

  </p>
 </div>


 <div class="refsect1 returnvalues" id="refsect1-function.posix-setrlimit-returnvalues">
  <h3 class="title">Return Values</h3>
  <p class="para">
   Returns <strong><code>TRUE</code></strong> on success or <strong><code>FALSE</code></strong> on failure.
  </p>
 </div>


 <div class="refsect1 seealso" id="refsect1-function.posix-setrlimit-seealso">
  <h3 class="title">See Also</h3>
  <p class="para">
   <ul class="simplelist">
    <li class="member">man page SETRLIMIT(2)</li>
    <li class="member"><span class="function"><a href="function.posix-getrlimit.html" class="function" rel="rdfs-seeAlso">posix_getrlimit()</a> - Return info about system resource limits</span></li>
   </ul>
  </p>
 </div>


</div><hr /><div class="manualnavbar" style="text-align: center;">
 <div class="prev" style="text-align: left; float: left;"><a href="function.posix-setpgid.html">posix_setpgid</a></div>
 <div class="next" style="text-align: right; float: right;"><a href="function.posix-setsid.html">posix_setsid</a></div>
 <div class="up"><a href="ref.posix.html">POSIX Functions</a></div>
 <div class="home"><a href="index.html">PHP Manual</a></div>
</div></body></html>