MKSWAP(8) MKSWAP(8) mkswap - ' Linux mkswap [] [] mkswap [] --size --file mkswap ' Linux . , , ( /dev/sdb7), . Linux , , , 82 (LINUX_SWAP), '. (: Solaris . , Solaris.) , . ( ' 1024- . mkswap , . - .) ', swapon(8), . , ' /etc/fstab, , swapon -a, . ' . , . ' Linux. mkswap, mkfs- , , - . , mkswap (SUN, BSD, ...). -c, --check ' ( ) . , . -F, --file ' . -f, --force , . ', , . , , mkswap . -q, --quiet . -L, --label , swapon(8) . --lock[=] BSD , . yes, no ( 1 0) nonblock. , "yes". $LOCK_BLOCK_DEVICE. , systemd-udevd(8) . -p, --pagesize ( ). , ; mkswap . -U, --uuid UUID UUID, . UUID. UUID , , : <>. UUID : clear UUID random UUID time UUID -e, --endianness , . native, little big. native. -o, --offset '. -s, --size ' , KiB (=1024), MiB (=1024*1024) GiB, TiB, PiB, EiB, ZiB YiB ( <> ', , <> , <>). , , . , --file. -v, --swapversion 1 '. ( , -v 0 , -v 1. ' 0 2.5.22 ( 2002 ). 1 2.1.117 ( 1998 ).) --verbose . mkswap '. -h, --help . -V, --version . LIBBLKID_DEBUG=all libblkid. LOCK_BLOCK_DEVICE=<> BSD. <<1>> <<0>>. . --lock, . ' . , ' 4294967295 ( 32- ). ' . Linux 32 '. ' /proc/swaps. mkswap , 10 . , , getconf PAGESIZE. mkswap --file, ' mkswap, , 2.41, mkswap --file nocow ' Btrfs. # dd if=/dev/zero of=swapfile bs=1MiB count=$((8*1024)) ' 8 . , , swapon(8) ' (, ). fdisk(8), swapon(8) mkswap util-linux, Linux . util-linux 2.41 2025-03-29 MKSWAP(8)