maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Maemo 5 / Fremantle (https://talk.maemo.org/forumdisplay.php?f=40)
-   -   How to set swappiness? (https://talk.maemo.org/showthread.php?t=48966)

Rob1n 2010-04-01 15:02

Re: How to set swappiness?
 
Quote:

Originally Posted by TheSacredSoul (Post 591456)
From what I've read, the sweet spot is 60... I just set mine to 60. Shall give it a try. Thanks for your help. And for anyone who wants to know the command is

echo 60 /proc/sys/vm/swappiness

The sweet spot will be very much dependent on the ratio between the memory performance and the media performance. That will be drastically different on a standard desktop PC (with very high-speed RAM and pretty slow hard drive media) than on the N900 (with slower RAM and higher-speed flash memory media).

And you've missed the critical '>' in the command you've given there.

TheSacredSoul 2010-04-01 15:13

Re: How to set swappiness?
 
Thank you Rob1n. My bad. How do you type > using the n900 keyboard?

Rob1n 2010-04-01 15:15

Re: How to set swappiness?
 
Quote:

Originally Posted by TheSacredSoul (Post 591498)
Thank you Rob1n. My bad. How do you type > using the n900 keyboard?

It's in the symbols table - press the blue arrow, then the Sym/Ctrl key above it, then select '>' from the pop-up symbols table.

TheSacredSoul 2010-04-01 15:17

Re: How to set swappiness?
 
Thank you once again. You are a live saver. So just to confirm...


echo 60 > /proc/sys/vm/swappiness

Rob1n 2010-04-01 15:21

Re: How to set swappiness?
 
Quote:

Originally Posted by TheSacredSoul (Post 591505)
Thank you once again. You are a live saver. So just to confirm...


echo 60 > /proc/sys/vm/swappiness

Yep, that's it. You can check the current value by running:

Code:

cat /proc/sys/vm/swappiness

TheSacredSoul 2010-04-01 15:25

Re: How to set swappiness?
 
Yep it's 60 :) Thank you!

Venemo 2010-04-01 15:46

Re: How to set swappiness?
 
Could you tell us how much better does it perform with the new value after some use?

pycage 2010-04-01 15:53

Re: How to set swappiness?
 
I have been running my N900 with swappiness 30 for some weeks without any ill side-effect. But it seems that battery-life and device responsiveness have both noticably improved.

BTW, on Diablo OS, the default swappiness value was 1. I'm almost certain that a default value of 100 on the N900 is not the optimal setting for this device at all.

Venemo 2010-04-01 16:10

Re: How to set swappiness?
 
Thanks Pycage!
Do you know how to set it so the value will persist after reboot?

@SR 2010-04-01 16:14

Re: How to set swappiness?
 
On n900 default value for swappiness is set by /etc/init.d/rcS script somewhere in the last lines.
echo value > /proc/sys/vm/swappiness works until the next reboot. So if you want to change the value permanently you should edit it in rcS script.


All times are GMT. The time now is 06:32.

vBulletin® Version 3.8.8