Swap memory in Windows and Linux is a area on a hard disk used as the virtual memory extension of a computer’s RAM (Random Access Memory).
The files in the RAM which are not used in more frequent is moved to this space until it is needed later. When needed again will be moved back to the RAM.
In many Operating Systems the files that are moved are called pages and the moving process is called paging.
Swap Memory is also used when the machine is set to hibernate.
Creation of Swap Area:
Most of the Operating systems create the swap area by there own without input from users.
While in Linux (UBUNTU) if you select to do a custom installation you have to create your swap area manually (It is a must step).
The size of the Swap is preferred to be more than the RAM (I usually take RAM memory size x 2)
Advantage of Swap Memory:
- Space availability other than that of just RAM
- Faster memory access as the processor don’t have to go back for reading Hard Disk again and again.
- As the processor don’t have to wait for frequently used pages the processing time is thus less.
Thus we understand the Swap memory is very useful.
If you have something to share please do share with me.