One of my games actually freezes the whole system while loading this game. After some analysis, I saw the SWAP completely occupied. So I want to increase this SWAP size to at least 16 or 32 GB (8 GB is not enough for the game).
I could just go to Google and search for how to do that but… Since I use Fedora, I heard that :
Seems like Fedora uses ZRAM instead of SWAP and I find the solution for it.
Create a file named zram-generator.conf on the directory /etc/systemd
Copy/paste that (it’s my configuration, change it depending on what you want)
zram-fraction seems to be a value, for example if the value is 1.X it means that the ZRAM will be equal to the amount of physical ram of your PC. If the value is 2.X, the ZRAM size will be the double of the physical RAM of your computer.
max-zram-size is actually the maximum ZRAM size you want.
So I won’t pretend to be anything close to an expert with respect to ZRAM, but my basic understanding is that ZRAM creates a swapfile in RAM.
If this is accurate (correct me if it isn’t), I don’t see how ZRAM could ever be larger in practice than the amount of physical memory you have (+ whatever the compression ratio is). In other words, it seems that if you use ZRAM the size of swap should be less than the amount of physical ram not more. If you are using swap to compensate for a shortage of RAM, it seems like ZRAM is likely not the best approach.
It seems to me that the best option in more ways tha none would be to add RAM if at all possible.