Why is moving from RAM to swap fast and from swap to RAM very slow?
When I run program that needs more memory that is available, I see that the RAM is prety quickly "cleaned" by moving unsused (=the least accessed) pages to swap.
But then when I run
swapoff -a ; swapon -a
it takes really long time (minutes for several GBs of swap) to move the swap back to RAM.
The swap is in addition on SSD. Or do the
swapoff -a command some special check, that I can avoid/disable?