View the current partition: free –m

Increase the swap size to about 2G: dd if=/dev/zero of=/var/swap bs=1024 count=2048000

Set exchange file: mkswap /var/swap

Activate and enable swap partition now: swapon /var/swap

Add a system boot time self start run: vi /etc/fstab

Add a line: /var/swap swap swap defaults 0 0

To reclaim swap space: swapoff /var/swap

Recycle from file system: rm /var/swap