CONTENT
  • CHANGES
Szukaj
counter

#top mkswap


mkswap - set up a Linux swap area

Powiązane:
dumpe2fs, e2fsck(fsck.ext2,fsck.ext3), mke2fs(mkfs.ext2,mkfs.ext3), mkswap, tune2fs,

SYNOPSIS
mkswap [-c] [-vN] [-f] [-p PSZ] [-L label] device [size]


DESCRIPTION



OPTIONS
-c
Check the device (if it is a block device) for bad blocks before creating the swap area. If any are found, the count is printed.

-f
Force - go ahead even if the command is stupid. This allows the creation of a swap area larger than the file or partition it resides on. On SPARC, force creation of the swap area. Without this option mkswap will refuse to create a v0 swap on a device with a valid SPARC superblock, as that probably means one is going to erase the partition table.

-p
PSZ Specify the page size to use.

-L label
Specify a label, to allow swapon by label. (Only for new style swap areas.)

-v0
Create an old style swap area.

-v1
Create a new style swap area.

If no -v option is given, mkswap will default to new style, but use old style if the current kernel is older than 2.1.117 (and also if PAGE_SIZE is less than 2048). The new style header does not touch the first block, so may be preferable, in case you have a boot loader or disk label there. If you need to use both 2.0 and 2.2 kernels, use the -v0 option when creating the swapspace.

Version 0 (-v0) swap space format is no longer supported in 2.5+ kernels.



EXAMPLES
mkswap -L LABEL /dev/sda4 # make swap space with label: LABEL




Zmodyfikowany ostatnio: 2014/05/15 09:59:14 (9 lat temu), textsize: 2,24 kB, htmlsize: 2,89 kB

Zapraszam do komentowania, zgłaszania sugestii, propozycji, własnych przykładów, ...
Dodaj komentarzKomentarze użytkowników