Linux swapon Command
The Linux swapon command is used to activate swap space on a Linux system; Linux memory management must use swap space to create virtual memory.
Syntax
/sbin/swapon -a [-v]
/sbin/swapon [-v] [-p priority] specialfile ...
/sbin/swapon [-s]
Parameter Description:
- -h Please help me
- -V Display version information
- -s Display brief device information
- -a Automatically start all SWAP devices
- -p Set priority. You can assign it a number between 0 and 32767. Or add pri=[value] in /etc/fstab ([value] is a number between 0 and 32767), then you can conveniently use swapon -a to start them all with priority settings.
swapon turns swap on.
Correspondingly, there is a command to turn swap off: swapoff.
Linux Command Reference