How to SWAP

See Raw devices
Solaris

To set up a temporary swap area, execute these lines as root:

>swap -l

> $ mkfile 1024m /home1/tempfile
> $ chmod o+t /home1/tempfile
> $ swap -a /home1/tempfile

>swap -l
 

 

Linux
#Get swap infos
swapon -s
or
cat /proc/swaps

#turn off swap
swapoff -a

#To set up a temporary Linux swap area, execute these lines as root: 
dd if=/dev/zero of=tmp_swap bs=1M count=500
chmod 600 tmp_swap; mkswap tmp_swap; swapon tmp_swap
#free this space: 
swapoff tmp_swap
rm tmp_swap

#alternatively you can create a filesystem based on the zeroed file
mke2fs tmp_swap