VectorLinux
November 22, 2014, 12:35:48 am *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
News: Visit our home page for VL info. To search the old message board go to http://vectorlinux.com/forum1. The first VL forum is temporarily offline until we can find a host for it. Thanks for your patience.
 
Now powered by KnowledgeDex.
   Home   Help Search Login Register  
Please support VectorLinux!
Pages: [1]
  Print  
Author Topic: swappiness value  (Read 3714 times)
vectornewb
Member
*
Posts: 46


« on: July 18, 2011, 02:49:54 pm »

Curious what the experienced user think of the subject. Am told vm.swappiness=10 is a good setting for desktop PC's. Can't even find where to change it, which VL light is set to the normal default of most distro's at =60. Worth doing and advice as to what to edit to achieve it if it is ? I mean I can run the command to temporarily set it.

echo 10 > /proc/sys/vm/swappiness

But it isn't persistent and the default value of 60 is restored upon reboot. Any thoughts and experiences with this folks ?


Thanks.
Logged
nightflier
Administrator
Vectorian
*****
Posts: 4029



« Reply #1 on: July 18, 2011, 04:13:09 pm »

Try adding the command to /etc/rc.d/rc.local
Logged
vectornewb
Member
*
Posts: 46


« Reply #2 on: July 19, 2011, 07:22:51 pm »

Thanks nightflier, in your experience is it worth doing ? I mean any benefits to it ? Honestly VL light doesn't use the swap hardly that I've seen even at the default of 60. Guess could always change it with echo and see if there's any noticeable difference. Thought to ask the people more linux savvy and who have more experience with VL than I do what they think about the topic.

Anyway, thanks for the reply and suggestion.
Logged
nightflier
Administrator
Vectorian
*****
Posts: 4029



« Reply #3 on: July 20, 2011, 01:04:09 am »

I never played much with it, the defaults work fine for my use. It can't hurt to test different values though, so play with it and see if you notice any change. And please share your experience if you do, for the benefit of everyone. Smiley
Logged
vectornewb
Member
*
Posts: 46


« Reply #4 on: July 20, 2011, 04:10:54 pm »

Just been using that echo command to temp change it now and then. Not really seeing all that much of a diff. Haven't experimented enough. When editing the file you mention, not even overly sure where to add the edit. So is making leery of messing with it. Considering it barely uses swap even with the default setting. VL seems a bit harder to figure out how to dig into than some others I've tried. Though in my (nix newb) case found out, that can be a good thing. As it keeps me from borking it up. Cheesy
Logged
vectornewb
Member
*
Posts: 46


« Reply #5 on: July 20, 2011, 04:12:25 pm »

Just been using that echo command to temp change it now and then. Not really seeing all that much of a diff. Haven't experimented enough. When editing the file you mention, not even overly sure where to add the edit. So is making leery of messing with it. Considering it barely uses swap even with the default setting. VL seems a bit harder to figure out how to dig into than some others I've tried. Though in my case (nix newb) found out, that can be a good thing. As it keeps me from borking it up. Cheesy

As always thanks for the reply and input nightflier. Seems like you single handedly handle a ton of requests for help and support with this distro.
Logged
nightflier
Administrator
Vectorian
*****
Posts: 4029



« Reply #6 on: July 20, 2011, 04:27:04 pm »

Thanks. Smiley

Yes, VL is a little simpler than the "fully automatic" distros that grab the headlines. You need to open the hood and get your hands dirty to really appriate it. As far as this command goes, you would add the line:
Code:
echo 10 > /proc/sys/vm/swappiness
to the end of /etc/rc/d/rc.local

The commands in rc.local get executed with root privileges. Commands in your WM/DE startup files launch with user privileges.
Actions performed as regular user can bork your profile, but won't hurt the system, so keep a good backup of important files and go for it. Have fun figuring things out.
Logged
vectornewb
Member
*
Posts: 46


« Reply #7 on: July 21, 2011, 12:54:35 am »

Ah why not ... what's the worst that can happen ? A reinstall I guess. Definitely done enough of those trying to learn the ropes w linux mint. Also agree nix is weird. The distro I dislike the most and found to be nothing special is a household name. The really cool ones that do something spectacular ... barely anyone knows about ? Which VL light definitely lives up to it's name and I've been promoting. When they said light ... they weren't kidding. While still being full of features, user friendly and packed fulla linuxy goodness.

Sighs anyway, cover me ... I'm going in. Cheesy

Well it's done ... check in terminal confirms swappiness=10 now. Guess will have to spend some time comparing and try to figure out if there's any real difference. Thanks nightflier as always. Basic look around seems nothing is borked.
« Last Edit: July 21, 2011, 01:16:09 am by vectornewb » Logged
vectornewb
Member
*
Posts: 46


« Reply #8 on: July 22, 2011, 03:01:22 am »

Update: Not really noticing much difference. Then again VL light wasn't using the swap hardly ever with it set to default. Haven't exhaustively played with it. Can say it hasn't borked anything, sys stats seem to be where they were before. Still prefer doing this as have seen vm.swappiness=10 being the recommended setting for desktops in some places around the web. Think every lil bit can help make a nix OS run smoother. So generally just change it and file it under every lil bit helps, shrugs.

Guess it could improve performance a bit for folks who push their systems harder than I do. Lowering the OS's tendency to use the swap when there's free RAM still available has to be at least a tad of benefit ? I mean disk writes and CPU cycles I'd think would add up and cause at least some lag otherwise. Just a nix newbs opinion and could be totally wrong. Thanks yet again nightflier for pointing me in the right direction. Would've more than likely never found the right file to edit on my own.



« Last Edit: July 22, 2011, 03:15:04 am by vectornewb » Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!