mkswap
mkswap功能说明:设置交换区(swap area)。
语 法:mkswap [-cf][-v0][-v1][设备名称或文件][交换区大小]
补充说明:mkswap可将磁盘分区或文件设为Linux的交换区。
参 数:
-c 建立交换区前,先检查是否有损坏的区块。
-f 在SPARC电脑上建立交换区时,要加上此参数。
-v0 建立旧式交换区,此为预设值。
-v1 建立新式交换区。
[交换区大小] 指定交换区的大小,单位为1024字节。
mkswap
mkswap [options] device
System administration command. Prepare swapspace on device: a disk partition or a prepared file. This command can create old and new style swap areas. The older style provides backward compatibility with 2.2 kernels, but is less efficient and more limited in size. The mkswap command has some dangerous options we have omitted here. They provide backward compatibility and solutions to problems with older libraries, but can destroy a disk if specified incorrectly.
Options
Check for bad blocks before creating the swapspace.
Create a label for use with swapon.
Create an old style swap area.
Create a new style swap area. (The default behavior on newer kernels.)