SliTaz SliTaz Forum

You are not logged in.

#1 2018-03-06 07:04:21

Gopal2018
Member
Registered: 2018-02-19
Posts: 38

How can I decrease my computer's swap use?

Hi! my current swappiness setting is 60. How can I change it to 10 as this is especially noticeable on computers with relatively low RAM memory (2 GB or less). My RAM is 2GB. I want to change my swappiness setting to 10.

Offline

#2 2018-03-06 08:36:13

aledie
Member
Registered: 2018-02-21
Posts: 58

Re: How can I decrease my computer's swap use?

On Ubuntu based system I would edit file:

/etc/sysctl.conf

Please check if have the same on slitaz

If not, can you try create one with a line pasted in:

vm.swappiness=10

If it doesn't work, and you don't need swap, may see if you uncomment swap partition all together in: /etc/fstab

Offline

#3 2018-03-06 12:47:55

Ceel
Administrator
Registered: 2011-04-02
Posts: 1,424

Re: How can I decrease my computer's swap use?

This can help http://forum.slitaz.org/topic/how-to-modify-temporarily-the-swappiness-parameter#post-37589

Offline

#4 2018-03-07 06:05:30

Gopal2018
Member
Registered: 2018-02-19
Posts: 38

Re: How can I decrease my computer's swap use?

Hi Ceel!

echo 50 > /proc/sys/vm/swappiness

it's working temporarily, but I want to do my swappiness setting 30 permanently.

My RAM is 2GB, HDD 500GB, which swappiness parameter will be best for my pc?

Offline

#5 2018-03-07 06:52:30

aledie
Member
Registered: 2018-02-21
Posts: 58

Re: How can I decrease my computer's swap use?

After you changed the swapness settings, and if you are running slitaz in live mode, from say USB. Why not just saving your new settings to rootfs.gz by using the function you have on right mouse click on desktop menu. Something called Slitaz Live. Choose lzma format. At next reboot you should have your new settings.

Offline

#6 2018-03-07 07:49:47

Gopal2018
Member
Registered: 2018-02-19
Posts: 38

Re: How can I decrease my computer's swap use?

Hi aledie! I am using Slitaz 5.0 as not live, using it as HDD installation mode. As I am using this OS as my permanent OS now which I replaced with windows.

Offline

#7 2018-03-07 08:35:29

aledie
Member
Registered: 2018-02-21
Posts: 58

Re: How can I decrease my computer's swap use?

Try my solution above!

Edit as root and save the file sysctl.conf, which I check yesterday we also have on slitaz.

If you don't need swap at all ( for such small system like slitaz, even 2gb Ramshould be enough you may also just disable swap in fstab file. I had a similar old PC and 2gb ram Pentium m Dell 700m  with another heavier Linux Antix, and even there swap was always at 0 usage, so I usually never use swap and have no problems...unless you installed heavy apps like Firefox or libre office.

Offline

#8 2018-03-07 10:54:38

Gopal2018
Member
Registered: 2018-02-19
Posts: 38

Re: How can I decrease my computer's swap use?

Hi aledie! Ya its working. I am using Firefox web browser. Thank you.

Offline

Registered users online in this topic: 0, guests: 1
[Bot] ClaudeBot

Board footer

Powered by FluxBB
Modified by Visman

[ Generated in 0.031 seconds, 7 queries executed - Memory usage: 1.54 MiB (Peak: 1.77 MiB) ]