# Linux Server load after deploy

**URL:** <https://www.ruby-forum.com/t/linux-server-load-after-deploy/139857>\
**Category:** Deployment\
**Created:** [June 8, 2008, 6:07am UTC](https://www.ruby-forum.com/t/linux-server-load-after-deploy/139857 "2008-06-08T06:07:39Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![CRAZ8](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/6bbea6/32.png) [@CRAZ8](https://www.ruby-forum.com/u/CRAZ8)\
**Post date:** [June 8, 2008, 6:07am UTC](https://www.ruby-forum.com/t/linux-server-load-after-deploy/139857/1 "2008-06-08T06:07:39Z")

</div>

I’m setting up a brand new second server for my Rails applications,  
and am having a problem with server load getting out of control.

The machine is a quad core 2Ghz with 4G Ram and a single 500GB disk.  
This is a web/app server with no database.

When I direct traffic to the server and its stable, the thing runs  
great - low Load for a few hundred Rails requests per minute.

If I up the load (either more users show up, or I deploy with  
Capistrano), the Load level increases to 1-2, and then _never comes  
back down_.

With enough traffic going to the server, the load sometimes gets out  
of control, slowly increasing until I direct the traffic back to my  
other server.

I’m having real trouble diagnosing where the load is coming from. CPU  
usage is really low, disk peaks during deploy, but goes back down,  
network traffic isn’t huge.

Anyone got any ideas on what I can try next?

This is a brand new server, so there may be something broken or badly  
configured.

---

<div class="post-metadata">

**Author:** ![CRAZ8](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/6bbea6/32.png) [@CRAZ8](https://www.ruby-forum.com/u/CRAZ8)\
**Post date:** [June 8, 2008, 2:42pm UTC](https://www.ruby-forum.com/t/linux-server-load-after-deploy/139857/2 "2008-06-08T14:42:59Z")

</div>

Have you monitored the server with top / htop to check the behavior of  
the processes?

–  
Aníbal Rojas

> **[Home - Has Many Developers](https://hasmanydevelopers.com/)**
>
> We are the best choice for your building design and development

> **[RUBYCORNER.COM](https://www.rubycorner.com/)**
>
> RUBYCORNER.COM - Contact us for any business inquiries

[http://anibal.rojas.com.ve](http://anibal.rojas.com.ve)

---

<div class="post-metadata">

**Author:** ![CRAZ8](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/6bbea6/32.png) [@CRAZ8](https://www.ruby-forum.com/u/CRAZ8)\
**Post date:** [June 8, 2008, 2:51pm UTC](https://www.ruby-forum.com/t/linux-server-load-after-deploy/139857/3 "2008-06-08T14:51:55Z")

</div>

Have yo monitored the server with top/htop to find the offending  
processes?

What is you stack in this server?

What does the log say?

–  
Aníbal Rojas

> **[Home - Has Many Developers](https://hasmanydevelopers.com/)**
>
> We are the best choice for your building design and development

> **[RUBYCORNER.COM](https://www.rubycorner.com/)**
>
> RUBYCORNER.COM - Contact us for any business inquiries

[http://anibal.rojas.com.ve](http://anibal.rojas.com.ve)

---

<div class="post-metadata">

**Author:** ![CRAZ8](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/6bbea6/32.png) [@CRAZ8](https://www.ruby-forum.com/u/CRAZ8)\
**Post date:** [June 8, 2008, 8:44pm UTC](https://www.ruby-forum.com/t/linux-server-load-after-deploy/139857/4 "2008-06-08T20:44:34Z")

</div>

I have been using atop, and it shows spikes in disk usage during  
deployment, then again after deployment (there’s a lot of cache on the  
machine, so I assume its being flushed there)

The processes are not using any more CPU during this time, but the  
load is slowly going up, and response times are getting longer. CPU  
Wait Time isn’t going up either.

The stack is: Ubuntu 7 Server, Nginx, Rails 2.02, Mongrel 1.1.4, MySQL  
2.7 driver to a remote MySQL server. This is the same configuration  
as my server running Ok

There’s nothing notable in any log I can find.

I think there’s a hardware problem, but the disk diagnostics I ran  
came up clean. I’m having my server provider take a look. This  
server is clearly unacceptable - Quad Core, 4GB RAM can’t run 3  
requests per second of my Rails app without the load going over 10  
after a deploy

---

<div class="post-metadata">

**Author:** ![CRAZ8](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/6bbea6/32.png) [@CRAZ8](https://www.ruby-forum.com/u/CRAZ8)\
**Post date:** [June 10, 2008, 12:54pm UTC](https://www.ruby-forum.com/t/linux-server-load-after-deploy/139857/5 "2008-06-10T12:54:25Z")

</div>

Edd,

On Jun 9, 12:49 pm, Edds [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> Is your system swapping?

According to the information from CRAZ8 no or it will be shown in \*top

> Are you running memcache on the server?

This is an interesting question, why are you doing it?

> What’s the location of the db that it connects to ? Is it local (same  
> switch) ?

Should show a hight time for the DB in the production.log, looks like  
this is not the case (again acording to the information supplied by  
CRAZ8)

CSI Server 😉

–  
Aníbal

---

<div class="post-metadata">

**Author:** ![CRAZ8](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/6bbea6/32.png) [@CRAZ8](https://www.ruby-forum.com/u/CRAZ8)\
**Post date:** [June 9, 2008, 6:49pm UTC](https://www.ruby-forum.com/t/linux-server-load-after-deploy/139857/6 "2008-06-09T18:49:46Z")

</div>

Is your system swapping ? Are you running memcache on the server?  
What’s the location of the db that it connects to ? Is it local (same  
switch) ?

vmstat -s (check ram usage) How many mongrel processes on the  
server ?
