You are not logged in.

#1 2008-04-15 18:22:34

ninjaprawn
Member
From: Manchester, UK
Registered: 2008-01-26
Posts: 485

[solved]swap question

hi,

my system starts to run slow after its is on for 5 or 6 days. i noticed that as the used swap increases, my system slows down more!

so obviously, it would be best if i could move the swap back into ram? is it possible??

i already have swappiness and vm.cache set to = 0

any ideas?? to save me just rebootin? and other than "buy more ram"?[solved]

Last edited by ninjaprawn (2009-02-12 21:45:46)


2007 - Started using Arch Linux as my only/main OS
- Samsung Series 3, Intel(R) Core(TM) i5-3210M CPU @ 2.50GHz - 8Gb DDR3 ram - 700Gb HDD
On board intel Graphics & Sound

Offline

#2 2008-04-15 18:38:02

tailor
Member
Registered: 2008-01-14
Posts: 7

Re: [solved]swap question

Depends. Do you have any interesting programs running?

Try for example the command "top", which gives good info on which processes are running and how much space they are using.
Swap is done by the Kernel and afaik you cannot influence it that much.

As your system runs faster at the beginning, I think it is a problem with one of your programs.

Greetings

Offline

#3 2008-04-15 19:17:20

ninjaprawn
Member
From: Manchester, UK
Registered: 2008-01-26
Posts: 485

Re: [solved]swap question

opera, amarok, kmail, ktorrent, kopete, conky, ksmoothdock, full kde, kicker. thats all apps.

top - 20:15:07 up 3 days, 23:45,  1 user,  load average: 0.33, 0.1
Tasks:  86 total,   1 running,  85 sleeping,   0 stopped,   0 zomb
Cpu(s): 14.7%us,  4.0%sy,  0.0%ni, 79.8%id,  0.3%wa,  0.1%hi,  1.0
Mem:    514932k total,   508736k used,     6196k free,     6528k b
Swap:   971924k total,   150148k used,   821776k free,   133148k c

  PID USER      PR  NI  VIRT  RES  SHR S %CPU %MEM    TIME+
32522 danny     20   0  163m  51m  26m S  3.8 10.2  11:34.37
16791 danny     20   0  2128  940  728 R  1.9  0.2   0:00.01
    1 root      20   0  1656  488  468 S  0.0  0.1   0:05.08
    2 root      15  -5     0    0    0 S  0.0  0.0   0:00.00
    3 root      RT  -5     0    0    0 S  0.0  0.0   0:00.00
    4 root      15  -5     0    0    0 S  0.0  0.0   0:02.01
    5 root      RT  -5     0    0    0 S  0.0  0.0   0:00.01
    6 root      15  -5     0    0    0 S  0.0  0.0   0:05.82
    7 root      15  -5     0    0    0 S  0.0  0.0   0:00.06

Last edited by ninjaprawn (2008-04-15 19:18:19)


2007 - Started using Arch Linux as my only/main OS
- Samsung Series 3, Intel(R) Core(TM) i5-3210M CPU @ 2.50GHz - 8Gb DDR3 ram - 700Gb HDD
On board intel Graphics & Sound

Offline

#4 2008-04-15 21:23:07

pogeymanz
Member
Registered: 2008-03-11
Posts: 1,020

Re: [solved]swap question

It sounds like one of your programs has a memory leak.

Try not running Opera for a day and see if your swap still climbs. If it does, keep trying with the other programs until you find which one it is.

Offline

#5 2008-04-16 19:46:48

ninjaprawn
Member
From: Manchester, UK
Registered: 2008-01-26
Posts: 485

Re: [solved]swap question

it seems to stablize afta 8 days at around 15% swap used! i think i need to use either lighter apps or get more memory!

thanks


2007 - Started using Arch Linux as my only/main OS
- Samsung Series 3, Intel(R) Core(TM) i5-3210M CPU @ 2.50GHz - 8Gb DDR3 ram - 700Gb HDD
On board intel Graphics & Sound

Offline

#6 2008-04-16 20:40:52

serrghi
Member
From: Bergen, NO
Registered: 2008-02-12
Posts: 100
Website

Re: [solved]swap question

hm weird. my comp doesnt even use my swap... max 4kb tongue even tho i have 2gb for swap.


Unyttig.INFO - Your source to not so useless information
My github - Various configs, dotfiles and nifty scripts

Offline

#7 2008-04-16 21:12:30

floke
Member
Registered: 2007-09-04
Posts: 266

Re: [solved]swap question

Another useful command here is 'free -m', or even better 'watch free -m',
This will show you more detail on memory use than top, since it shows you how much is also being cached (the amount of memory you have free will naturally fall as the cache grows).
Thus, I currently have 1G mem, 965 used, and 36 free - but without the cache its just 351 used and 650 free.
If you use the watch command, you can fire up an app and see how much memory it grabs.

** EDIT: After looking at your 'top' output - I would say get some more memory; and there's no point having a swap size that big since your system will become unusable before it uses even half of it!

Last edited by floke (2008-04-16 21:14:25)

Offline

#8 2009-02-12 21:45:16

ninjaprawn
Member
From: Manchester, UK
Registered: 2008-01-26
Posts: 485

Re: [solved]swap question

wow, so long ago n so much has changed!! lol!

i dont have the same problem with swap fillin up!! changed to openbox, n a lot of smaller apps! i only fill up swap wen doin alot or transmission is busy!!

wen swap is slightly full tho, my system starts to crawl, so to save rebootin, i created a lil script which is in my ob menu!!

#!/bin/sh
#
sync
sudo swapoff -a
sudo swapon -a

i added swapon/off to my sudoers file so it doesnt need a password!! works perfectly!!


2007 - Started using Arch Linux as my only/main OS
- Samsung Series 3, Intel(R) Core(TM) i5-3210M CPU @ 2.50GHz - 8Gb DDR3 ram - 700Gb HDD
On board intel Graphics & Sound

Offline

Board footer

Powered by FluxBB