Linux 1.x
25 September 1995
Aliases: swapoff(8), swapoff(8), swapoff(8), swapoff(8), swapoff(8), swapoff(8), swapoff(8), swapoff(8), swapoff(8), swapoff(8), swapoff(8), swapoff(8), swapoff(8), swapoff(8), swapoff(8), swapoff(8), swapoff(8), swapoff(8)
manpages-zh
Chinese manual pages
man-pages-zh_tw
Traditional Chinese Linux man pages
mount
tools for mounting and manipulating filesystems
util-linux
Miscellaneous system utilities for Linux
NAME
swapon, swapoff - 使用/關閉用於分頁和交換的文件和設備
總覽 (SYNOPSIS)
/sbin/swapon [-h -V]
/sbin/swapon -a [-v]
/sbin/swapon [-v] [-p priority] specialfile ...
/sbin/swapon [-s]
/sbin/swapoff [-h -V]
/sbin/swapoff -a
/sbin/swapoff specialfile ...
/sbin/swapon -a [-v]
/sbin/swapon [-v] [-p priority] specialfile ...
/sbin/swapon [-s]
/sbin/swapoff [-h -V]
/sbin/swapoff -a
/sbin/swapoff specialfile ...
描述 (DESCRIPTION)
Swapon 指出 用於 分頁和交換 的 設備. 一般 在 系統 多用戶運行級 的 初始化文件 /etc/rc 中 調用 swapon , 使 所有的 交換設備 生效, 因此 分頁和交換 活動 可以 在 多個 設備和文件 之中 進行.
Swapoff 禁止 在 指定的 設備和文件 上 做 交換, 如果 指定了 -a 選項, /etc/fstab 中 所有的 交換設備 皆被 關閉.
常用的形式有:
-h | 顯示幫助 |
-V | 顯示版本 |
-s | 顯示交換設備的使用情況.這個選項需要 /proc/swaps (小於 2.1.25 的 內核 可能沒有). |
-a | 使 /etc/fstab 中, 所有 標記了 ’sw’ 的 交換設備 生效. |
-p priority | |
指定 swapon 的 優先級. 這個 選項 要求 swapon 在 1.3.2 或 更高 的 內核 上 編譯 和 使用. priority 介於 0 和 32767 之間. 關於 交換優先級 的 完整 描述 請 參看 swapon(2) . 在 /etc/fstab 文件 中, 交換設備 的 選項域 裏 加上 pri=value, 用 swapon -a 可以 使其 生效. |
注意 (NOTE)
別在 包含 空洞(hole) 的 文件 上 使用 swapon .
文件 (FILES)
/dev/hd?? 標準分頁設備
/dev/sd?? 標準 (SCSI) 分頁設備
/etc/fstab ascii 格式的 文件系統 描述表
/dev/sd?? 標準 (SCSI) 分頁設備
/etc/fstab ascii 格式的 文件系統 描述表
歷史 (HISTORY)
swapon 命令 源於 4.0BSD.
[中文版維護人]
徐明 <xuming>
[中文版最新更新]
2001/11/18
《中國Linux論壇man手冊頁翻譯計劃》
http://cmpp.linuxforum.net
跋
本頁面中文版由中文 man 手冊頁計劃提供。
中文 man 手冊頁計劃:https://github.com/man-pages-zh/manpages-zh
中文 man 手冊頁計劃:https://github.com/man-pages-zh/manpages-zh