mirror of
https://github.com/fofolee/uTools-Manuals.git
synced 2025-06-08 23:14:06 +08:00
15 lines
943 B
HTML
15 lines
943 B
HTML
<h1 id="swapoff">swapoff</h1>
|
||
<p>关闭指定的交换空间</p>
|
||
<h2 id="补充说明">补充说明</h2>
|
||
<p><strong>swapoff命令</strong> 用于关闭指定的交换空间(包括交换文件和交换分区)。swapoff实际上为swapon的符号连接,可用来关闭系统的交换区。</p>
|
||
<h3 id="语法">语法</h3>
|
||
<pre><code class="language-bash">swapoff(选项)(参数)</code></pre>
|
||
<h3 id="选项">选项</h3>
|
||
<pre><code class="language-bash">-a:关闭配置文件“/etc/fstab”中所有的交换空间。</code></pre>
|
||
<h3 id="参数">参数</h3>
|
||
<p>交换空间:指定需要激活的交换空间,可以是交换文件和交换分区,如果是交换分区则指定交换分区对应的设备文件。</p>
|
||
<h3 id="实例">实例</h3>
|
||
<p>关闭交换分区</p>
|
||
<pre><code class="language-bash">swapoff /dev/sda2</code></pre>
|
||
<!-- Linux命令行搜索引擎:https://jaywcjlove.github.io/linux-command/ -->
|