Linode Forum
Linode Community Forums
 FAQFAQ    SearchSearch    MembersMembers      Register Register 
 LoginLogin [ Anonymous ] 
Post new topic  Reply to topic
Author Message
 Post subject:
PostPosted: Sun Feb 01, 2009 8:38 pm 
Offline
Senior Member

Joined: Fri May 02, 2008 8:44 pm
Posts: 1121
richard.scott wrote:
I'm on newark61 and over the last 30 days my IO has averaged 10K by looking at the graphs in my control panel.

3 weeks ago this was less than 1K and I'm not doing anything different on my server it just seems to use up swap space more than normal!

CPU usage is currently at 10% (5% average for the last 30 days).


If you're regularly using swap, you have a problem. It also hurts the performance of whatever you have on the server, so find a convenient time to reboot your server and see if you can control your swap usage.


Top
   
 Post subject:
PostPosted: Mon Feb 02, 2009 5:57 am 
Offline
Junior Member

Joined: Fri Oct 22, 2004 6:40 am
Posts: 20
hybinet wrote:
If you're regularly using swap, you have a problem.


I am using swap space, but I don't know why!

I used to run my email server on a co-located Mini-itx VIA PD10000 1GHz Motherboard with only 512MB of ram and that never ever touched swap space.

I would have thought that a linode was quicker than that?? But since moving that all to a Linode 540 its done nothing but swap!

...but, and here's the really annoying part....

i've only been swapping like crazy for the last 3 weeks and I've been using the server since the start of December as my mail email server!

I don't understand why the performacne has degraded so much in the past 3 weeks :shock:

Rich


Top
   
 Post subject:
PostPosted: Mon Feb 02, 2009 7:02 am 
Offline
Senior Member

Joined: Fri May 02, 2008 8:44 pm
Posts: 1121
The problem we've been discussing in this thread only hits from time to time, for a maximum of few hours. Not for three weeks straight. Hardware problems tend to get fixed pretty soon, so if it's been three weeks, something's definitely wrong with one of your programs.

A linode 540 obviously has more RAM than your old colo, and it's also many times more powerful. Also, it was fine until three weeks ago, right? Then try to find out what happened when the problems began. Did you change some configurations? Did you update your programs from your distro's repository? Did you suddenly get a lot of visitors to your web site or a lot of spam to your mail server? Perhaps someone hacked your server without your knowledge?

There are many diagnostic tools that can tell you which program is using the most CPU and RAM. top is the most simple of all; htop looks prettier; munin is a bit more sophisticated. You can get halfway towards a solution if you can pinpoint the bad guy.


Top
   
 Post subject:
PostPosted: Mon Feb 02, 2009 7:40 am 
Offline
Junior Member

Joined: Fri Oct 22, 2004 6:40 am
Posts: 20
Head hung in shame... I think its a config error!

I've been poking about and found that my grey-listing daemon on my mail server is configured to keep connections open to mysql.

It doesn't seem to re-use connections, but just keeps opening them up to the 100 limit set in gld.conf

Hopefully I've fixed it and my Linode can go back to being awesome! :wink: :oops:


Top
   
 Post subject:
PostPosted: Mon Feb 02, 2009 9:59 am 
Offline
Junior Member

Joined: Fri Oct 22, 2004 6:40 am
Posts: 20
ok, I spoke too soon. but I think I've found the reason.

using 'htop' i've found that clamd is using 311MB of ram! WTF :cry:

No wonder nothing else has room to work nicely without swapping all the time :roll:


Top
   
 Post subject:
PostPosted: Tue Feb 03, 2009 8:36 am 
Offline
Junior Member

Joined: Fri Oct 22, 2004 6:40 am
Posts: 20
ok, I've found a possible fix for my I/O trhashing.

If I change my "vm.swappiness" value from the default of 60 to 95 it seems to help?

I run this at boot time:
Code:
sysctl -q -w vm.swappiness=95


However, it totally fills my swap space up :shock:

Code:
top - 12:34:33 up 20 min,  1 user,  load average: 0.24, 0.14, 0.10
Tasks: 104 total,   1 running, 103 sleeping,   0 stopped,   0 zombie
Cpu(s):  1.0%us,  1.0%sy,  0.1%ni, 95.9%id,  1.9%wa,  0.0%hi,  0.0%si,  0.2%st
Mem:    553176k total,   537280k used,    15896k free,     2480k buffers
Swap:   262136k total,   218204k used,    43932k free,   297812k cached


But it seems to have reduced my disk IO :lol:

I'll keep an eye on it.

Rich


Top
   
 Post subject:
PostPosted: Tue Feb 03, 2009 9:04 am 
Offline
Senior Member

Joined: Tue Apr 29, 2008 6:26 pm
Posts: 58
Website: http://blog.shadypixel.com/
Using up most of the swap space during normal system operation is probably not a great idea. If your load increases even slightly for whatever reason, your machine is going to quickly slow to a crawl.

If none of the programs you're running are using abnormal amounts of memory, I would suggest just getting a bigger linode.


Top
   
 Post subject:
PostPosted: Tue Feb 03, 2009 9:18 am 
Offline
Junior Member

Joined: Fri Oct 22, 2004 6:40 am
Posts: 20
btmorex wrote:
Using up most of the swap space during normal system operation is probably not a great idea. If your load increases even slightly for whatever reason, your machine is going to quickly slow to a crawl.


I apprecieate that its not a good position to be in but its better than it was with regards to performance.

btmorex wrote:
Is there anything specific in the configuration of the Zen Host that would make this use swap space more often?

If none of the programs you're running are using abnormal amounts of memory, I would suggest just getting a bigger linode.


I've changed my vm.swappiness value to be 5 to test both ends of the scale and my swap space isn't used but my load average goes up to around 3!

Reverting vm.swappiness back to 95 results in a load average of 0.40!

Rich


Top
   
 Post subject:
PostPosted: Tue Feb 03, 2009 3:22 pm 
Offline
Junior Member

Joined: Fri Oct 22, 2004 6:40 am
Posts: 20
I've edited this post as my fix was to create more indexes in MySQL :oops:

do not edit your vm.swappiness value unless you have a good reason to do so :wink:


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
cron
RSS

Powered by phpBB® Forum Software © phpBB Group