I needed to temporarily increase the swap space by 16GB. Simplest and the quickest method is to add a swap file for the duration and then remove it after the task is over.
First of all identify a large enough partition on the internal disk and then go about the task as below..
1. Locate the partition where the file can be created, say /u06/swap
2. make a directory : /u06/swap
3. create the swap file using the command "dd" : dd if=/dev/zero of=/u06/swap/swapfile bs=1024 count=16384000
4. make the file as swapfile : mkswap /u06/swap/swapfile
5. To make the file available after reboot , add it to the /etc/fstab file: /u06/swap/swapfile swap swap defaults 0 0
6. Activate the swap space : swapon -a /tmp/swapfile
7. check the swap space : swapon -s
I followed redhat documentation , but the link below explains methods precisely the way I created the swap space. The link also shows how to drop the swap space.
http://www.technofunction.com/2010/08/adding-swap-space-in-redhatfedora-linux-manually-using-file-and-partition/
How to move swapfile from one location to another
First of all identify a large enough partition on the internal disk and then go about the task as below..
1. Locate the partition where the file can be created, say /u06/swap
2. make a directory : /u06/swap
3. create the swap file using the command "dd" : dd if=/dev/zero of=/u06/swap/swapfile bs=1024 count=16384000
4. make the file as swapfile : mkswap /u06/swap/swapfile
5. To make the file available after reboot , add it to the /etc/fstab file: /u06/swap/swapfile swap swap defaults 0 0
6. Activate the swap space : swapon -a /tmp/swapfile
7. check the swap space : swapon -s
I followed redhat documentation , but the link below explains methods precisely the way I created the swap space. The link also shows how to drop the swap space.
http://www.technofunction.com/2010/08/adding-swap-space-in-redhatfedora-linux-manually-using-file-and-partition/
How to move swapfile from one location to another
1. Locate the file where the created swapfile exists
2. Turnoff swap from swapfile
swapoff /mnt/dallas_prod_old/swapfile_dir/swapfile
3.