How to change swappiness from 60 to 10?

i followed a tutorial to change swappiness on manjaro by editing /etc/sysctl.d/100-manjaro.conf but no file exists in the sysctl.d1 directory.

Then create it:

sudo touch /etc/systctl.d/100-manjaro.conf

Or open it with nano, edit it and it will be created upon saving:

sudo nano /etc/systctl.d/100-manjaro.conf
1 Like

What tutorial? Careful what you follow.
(PS swappiness of 10 can be reliable … but it can be too low for some systems and result in lock-ups)

10 is recommended by Manjaro wiki for most desktop PCs.

how to know for a certain PC: is it classified as “most cases” or “rare cases”?

For me vm.swappiness of 1 looks like running good for couple of years. It is just RAM usage vs swap file/partition usage balance and 1 configure the usage RAM as maximum as could be with swap usage as minimum as could be.

What’s the point of config to use swap instead of free RAM memory?
What issues could be here? To shorter life of permanent storage by swap on it, to degrade system performance. What else difference of 60 vs 10 or 1?

There tons of sources where 0 noted as disables swappiness and others told that it is minimum swappiness, but not disabled and will be used only after RAM is full.

I have 32 GB of RAM.

… by trying I guess. :grin:

sudo touch /etc/sysctl.d/100-manjaro.conf
sudo vim /etc/sysctl.d/100-manjaro.conf  

append vm.swappiness=10 and reboot

3 Likes

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.