SWAPON(8) swapon, swapoff - / swapon [] [-...] swapoff [-va] [-...] swapon . -. -L -U -. swapon , , . swapoff . -a , ( /proc/swaps /etc/fstab). -a, --all ,,swap" /etc/fstab , ,,noauto". . -T, --fstab fstab mount(8). , strverscmp(3); (.) ,,.fstab" . . ,,initramfs" ,,chroot" . -d, --discard[=] , . , . : --discard=once ; --discard=pages . , . /etc/fstab discard, discard=, discard= . -e, --ifexists . /etc/fstab nofail . -f, --fixpgsz (exec mkswap) . mkswap(8) . -L . , /proc/partitions .) -o, --options fstab- . : swapon -o pri=1,discard=pages,nofail /dev/sda2 . -p, --priority . 0 32767. . swapon(2) . pri= /etc/fstab- swapon -a. , . -s, --summary . cat /proc/swaps. --show . --show[=...] . --help- . --output-all . --noheadings --show . --raw --show . --bytes --show . -U . -v, --verbose . -h, --help . -V, --version Display version and exit. swapoff 2.36: 0 2 (OOM) 4 swapoff(2) 8 ,,non-swapoff(2)" ( , ...) 16 32 ,,swapoff"- --all 64 ,,swapoff"- --all swapoff --all 0 ( ), 32 ( ), 64 ( , ). + 2.36 , 0 . LIBMOUNT_DEBUG=all libmount . LIBBLKID_DEBUG=all libblkid . /dev/sd?? /etc/fstab , . ,,Btrfs". cp(1) truncate(1) . swapon . fallocate(1) . XFS- 4.18. dd(1) /dev/zero. Btrfs Btrfs- 5.0 nocow . btrfs(5) . Since version 2.41, the command mkswap --file can create a new swap file with the nocow attribute. NFS NFS- . swapon (., S1SUSPEND, S2SUSPEND, ...). , . swapon 4.0BSD-. swapoff(2), swapon(2), fstab(5), init(8), fallocate(1), mkswap(8), mount(8), rc(8) For bug reports, use the issue tracker . swapon ,,util-linux" . util-linux 2.41 2025-03-29 SWAPON(8)