Ruby processes consuming 1,000 megs of swap space


#1

Hi all. The subject pretty much says it.

I’m running on a VPS-style shared server at pipespring.com. I’ve got
Typo
setup, and have been running it fine for about a month.

However, today I got an e-mail from my host saying they disabled Ruby
(chmod
000) because it was using waaay too much swap space.

I haven’t changed anything with my server at all (Rails or otherwise) in
at
least a week.

I looked through the server, development and fastcgicrash logs but found
nothing that screamed “I’m messing this up!”

The server is up and running right now, seems to be fine. Running a ps
-ax
yields about 8 or 9 Ruby processes - earlier in the day (after I turned
enabled Ruby) it was spitting out like 30-40 processes after a single
request to my site.

Any ideas? Anything else I should look at?

  • Rabbit

#2

This sounds like you are running typo in development mode and in CGI
mode.

If you would be running in production mode using fastcgi with working
static caching you should not need more then a single typo process.

On 1/20/06, Rabbit removed_email_address@domain.invalid wrote:

  • Rabbit

Rails mailing list
removed_email_address@domain.invalid
http://lists.rubyonrails.org/mailman/listinfo/rails


Tobi
http://jadedpixel.com - modern e-commerce software
http://typo.leetsoft.com - Open source weblog engine
http://blog.leetsoft.com - Technical weblog


#3

My RoR processes (both SCGI and Webrick) eventually use up a lot of
memory too. I periodically restart them. I don’t know if there’s a max
memory setting, or option to automatically restart after so many
connections (like Apache can do with its child processes).

csn


#4

It’s running in development mode with FCGI. If I change my httpd.conf to
run
Typo in production mode it fails to start. Dunno why.

How can I get Typo to run in production mode?

  • Rabbit


#5

Make sure your production database is configured correctly in
database.yml

You should never run development on a shared host, your admin will hate
you
(as you’ve found out)


From: removed_email_address@domain.invalid
[mailto:removed_email_address@domain.invalid] On Behalf Of Rabbit
Sent: Saturday, January 21, 2006 9:39 PM
To: removed_email_address@domain.invalid
Subject: Re: [Rails] Re: Ruby processes consuming 1,000 megs of swap
space

It’s running in development mode with FCGI. If I change my httpd.conf to
run
Typo in production mode it fails to start. Dunno why.

How can I get Typo to run in production mode?

  • Rabbit

On 1/21/06, csn removed_email_address@domain.invalid wrote:

My RoR processes (both SCGI and Webrick) eventually use up a lot of
memory too. I periodically restart them. I don’t know if there’s a max
memory setting, or option to automatically restart after so many
connections (like Apache can do with its child processes).

csn


Posted via http://www.ruby-forum.com/.