1832758 Members
2872 Online
110045 Solutions
New Discussion

Re: Pseudo swap

 
Abhijeet_3
Frequent Advisor

Pseudo swap

Hi,

I know about Device swap , Filesystem swap .
Need to know about what is pseudo swap.

I know pseudo swap is enabled by using kernel parameter swapmem_on .

Thanks

Abhijeet
2 REPLIES 2
RAC_1
Honored Contributor

Re: Pseudo swap

It is nothing but kernel calculation. When swapmem_on is set the kernel calculates available swap areas as swap space cconfigured + 75% of RAM. This helps to inflate swap space then actually available. Fopr example, If you have 64GB of RAM, you run apps/programs such that you just do not need to have 64*2 or 64*1.5 of swap space. In this case you can have small swap space and psudo swap enabled. It proves helpful with systems having large RAM and when I say large RAM, it varies fron one environment to another.

device swap - swap space configured on a device. e.g. - primary swap space.

file system swap - swap space configured on a file system. In such case a less used FS can be configured as file system swap. But when you are swapping, FS swap is like slowing the things further.
There is no substitute to HARDWORK
A. Clay Stephenson
Acclaimed Contributor

Re: Pseudo swap

First on modern systems, (and especially those with "large" amounts of RAM -- something like 8GiB and above) the old rules about 2X-3X RAM for swapsize just don't apply -- and haven't applied for about 15-20 years.

Consider the case where you have 32GB of memory. Without pseudoswap, you would have to have at 32GB of swap space to allow the use of the entire 32GB Virtual Address Space
because without pseudoswap, the kernel will only reserve space for processes equal to the amount of swap. However, with swapmem_on = 1, 75% of your memory is counted as VAS so that only 8GB of swap would allow access to all of your memory for processes. Pseudoswap is intended for systems that have much more memory than swap
--- which is perfectly legal. I have many such systems and they never swap --- that's why I bought all the memory in the first place. Pseudoswap serves no purpose in systems which have more swap than memory. Lastly, pseudoswap isn't swap at all, it simply changes the way the kernel caculates space for process reservation.
If it ain't broke, I can fix that.