Linux temporarily increases swap space:
Step 1:
#dd If=/dev/zero Of=/home/swap bs=1024 count=500000
Note: Of=/home/swap, place swap space; Count is the size of the increased swap space, 1024 is the block size, here is 1K, so the total space is bs*count=500m
Step 2:
# Mkswap/home/swap
Note: Format the space just to swap all kinds of
Step 3:
#swapon/home/swap
Comment: Make the swap space you just created
To close the newly opened swap space, just command: #swapoff
Solaris temporarily increases swap space:
Step 1:
#mkdir/swap
Step 2:
#mkfile 51200k/swap/s01
Comment: Create an empty file of the desired size
Step 3:
#swap-a/swap/s01
Note: Parameter a indicates a new swap partition
Step 4:
#swap-L
Comment: Verify that the swap file is correctly added to the disk space pool
Step 5:
#swap-S
Comment: summary information for swap space
Other:
If you want to use the entire partition as the swap space, you can take the block device name as a parameter to the swap command:
#swap-a/dev/dsk/c1t1d2s1
to ensure that the partition is added as swap at startup, you need to/etc/ The Vfstab file adds the following:
#deveice device Mount FS fsck mount Mount
#to mount to fsck point type Pass a tboot ops
/dev/ DSK/C1T1D2S1--Swap-no-
-D option to remove a file (or device) from the Swap Space pool:
#swap-D/swap/s01
#swap-D/dev/dsk/c1t1d2s1< /p>