Go Back   maemo.org - Talk > OS / Platform > Maemo 5 / Fremantle
 
Register FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
  #11  
Old 2010-04-01, 15:02
Rob1n Rob1n is offline
 
Join Date: Nov 2009
Location: Cambridge, UK
Posts: 3,617
Thanks!: 769
Thanked 2,412 Times in 1,382 Posts
Default Re: How to set swappiness?

Quote:
Originally Posted by TheSacredSoul View Post
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.
Reply With Quote
The Following 3 Users Say Thank You to Rob1n For This Useful Post:
  #12  
Old 2010-04-01, 15:13
TheSacredSoul TheSacredSoul is offline
 
Join Date: Mar 2010
Posts: 10
Thanks!: 3
Thanked 5 Times in 4 Posts
Default Re: How to set swappiness?

Thank you Rob1n. My bad. How do you type > using the n900 keyboard?
Reply With Quote
  #13  
Old 2010-04-01, 15:15
Rob1n Rob1n is offline
 
Join Date: Nov 2009
Location: Cambridge, UK
Posts: 3,617
Thanks!: 769
Thanked 2,412 Times in 1,382 Posts
Default Re: How to set swappiness?

Quote:
Originally Posted by TheSacredSoul View Post
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.
Reply With Quote
The Following 2 Users Say Thank You to Rob1n For This Useful Post:
  #14  
Old 2010-04-01, 15:17
TheSacredSoul TheSacredSoul is offline
 
Join Date: Mar 2010
Posts: 10
Thanks!: 3
Thanked 5 Times in 4 Posts
Default Re: How to set swappiness?

Thank you once again. You are a live saver. So just to confirm...


echo 60 > /proc/sys/vm/swappiness
Reply With Quote
The Following 2 Users Say Thank You to TheSacredSoul For This Useful Post:
  #15  
Old 2010-04-01, 15:21
Rob1n Rob1n is offline
 
Join Date: Nov 2009
Location: Cambridge, UK
Posts: 3,617
Thanks!: 769
Thanked 2,412 Times in 1,382 Posts
Default Re: How to set swappiness?

Quote:
Originally Posted by TheSacredSoul View Post
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
Reply With Quote
The Following 8 Users Say Thank You to Rob1n For This Useful Post:
  #16  
Old 2010-04-01, 15:25
TheSacredSoul TheSacredSoul is offline
 
Join Date: Mar 2010
Posts: 10
Thanks!: 3
Thanked 5 Times in 4 Posts
Default Re: How to set swappiness?

Yep it's 60 Thank you!
Reply With Quote
  #17  
Old 2010-04-01, 15:46
Venemo's Avatar
Venemo Venemo is offline
 
Join Date: Aug 2009
Location: Budapest, Hungary
Posts: 1,296
Thanks!: 3,355
Thanked 1,773 Times in 552 Posts
Default Re: How to set swappiness?

Could you tell us how much better does it perform with the new value after some use?
Reply With Quote
  #18  
Old 2010-04-01, 15:53
pycage's Avatar
pycage pycage is offline
 
Join Date: Oct 2005
Location: Germany
Posts: 3,404
Thanks!: 2,562
Thanked 4,474 Times in 1,452 Posts
Default 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.
__________________
Tidings - RSS and Podcast aggregator for Jolla - https://github.com/pycage/tidings
Cargo Dock - file/cloud manager for Jolla - https://github.com/pycage/cargodock
Reply With Quote
The Following 5 Users Say Thank You to pycage For This Useful Post:
  #19  
Old 2010-04-01, 16:10
Venemo's Avatar
Venemo Venemo is offline
 
Join Date: Aug 2009
Location: Budapest, Hungary
Posts: 1,296
Thanks!: 3,355
Thanked 1,773 Times in 552 Posts
Default Re: How to set swappiness?

Thanks Pycage!
Do you know how to set it so the value will persist after reboot?
Reply With Quote
  #20  
Old 2010-04-01, 16:14
@SR @SR is offline
 
Join Date: Dec 2009
Location: Russia
Posts: 53
Thanks!: 2
Thanked 143 Times in 22 Posts
Send a message via ICQ to @SR
Default 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.
Reply With Quote
The Following 5 Users Say Thank You to @SR For This Useful Post:
Reply

Tags
battery


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 21:52.