# Best setup for shared hosting?

**URL:** <https://www.ruby-forum.com/t/best-setup-for-shared-hosting/70273>\
**Category:** Rails\
**Created:** [September 27, 2006, 9:35pm UTC](https://www.ruby-forum.com/t/best-setup-for-shared-hosting/70273 "2006-09-27T21:35:56Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![jjkiesch](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/bc79bd/32.png) [@jjkiesch](https://www.ruby-forum.com/u/jjkiesch)\
**Post date:** [September 27, 2006, 9:35pm UTC](https://www.ruby-forum.com/t/best-setup-for-shared-hosting/70273/1 "2006-09-27T21:35:56Z")

</div>

is fcgi/apache still the best thing for shared hosting environments, or  
is there something better?

mongrel sounds awesome, but i’m wondering how it does with multiple  
apps on multiple domains since it sounds like you have to run a mongrel  
server for each application.

---

<div class="post-metadata">

**Author:** ![jjkiesch](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/bc79bd/32.png) [@jjkiesch](https://www.ruby-forum.com/u/jjkiesch)\
**Post date:** [September 27, 2006, 9:49pm UTC](https://www.ruby-forum.com/t/best-setup-for-shared-hosting/70273/2 "2006-09-27T21:49:59Z")

</div>

Here’s an easy way to look at it: One Mongrel server equals one instance  
of  
fastcgi.

Say your shared host allocates 2 fastcgi servers (dispatchers) for your  
application. That’d be like having two mongrel instances running.  
Roughly  
the same memory footprint.

Mongrel instances can be clustered using the awesome mongrel\_cluster  
gem…  
you choose how many instances you need along with the starting port and  
it  
will start / stop the various processes. At that point it’s just a  
matter of  
forwading requests from Apache to Mongrel.

I don’t know how many shared hosts go the mongrel route. A few do  
though.

---

<div class="post-metadata">

**Author:** ![jjkiesch](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/bc79bd/32.png) [@jjkiesch](https://www.ruby-forum.com/u/jjkiesch)\
**Post date:** [September 27, 2006, 10:22pm UTC](https://www.ruby-forum.com/t/best-setup-for-shared-hosting/70273/3 "2006-09-27T22:22:04Z")

</div>

On 27 Sep 2006, at 21:45, Brian H. wrote:

> processes. At that point it’s just a matter of forwading requests  
> from Apache to Mongrel.
> 
> I don’t know how many shared hosts go the mongrel route. A few do  
> though.

a2hosting does for example. You need to make sure your app runs in  
CGI mode first, then post a ticket on the support site and they’ll  
proxy your app to a mongrel. If you do have a bit of cash, I would  
still advise using a VPS instead of a shared host. E.g. send\_file in  
its default setting (streaming the data) will crash your mongrel  
instance. Why? No idea, it just does. Also, any plugin or class that  
extends one of the Rails classes, will make your mongrel crash, you  
need to freeze rails in your vendor folder. I wouldn’t use a2hosting  
anymore (although they provided me with good support), just because  
Rails isn’t their main target audience. For shared hosting, I would  
certainly tend to look at railsplayground now (they use fcgi i believe).

Best regards

Peter De Berdt

---

<div class="post-metadata">

**Author:** ![jjkiesch](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/bc79bd/32.png) [@jjkiesch](https://www.ruby-forum.com/u/jjkiesch)\
**Post date:** [September 28, 2006, 2:34am UTC](https://www.ruby-forum.com/t/best-setup-for-shared-hosting/70273/4 "2006-09-28T02:34:31Z")

</div>

On Sep 27, 2006, at 12:45 PM, Brian H. wrote:

> I don’t know how many shared hosts go the mongrel route. A few do  
> though.

Mongrel is what we recommend[1] when you’re a hosting customer at  
PLANET ARGON.

We automatically proxy your unique ports through our main proxy  
servers[2], so you’re able to manage your own front-end to mongrel  
with Pound[3], Nginix, or Lighttpd.

…and we encourage you to do it all with Capistrano!

For more information on our hosting services, visit http://

> **[Planet Argon](https://www.planetargon.com/hosting.html)**
>
> Planet Argon is a Ruby on Rails development agency specializing in maintenance and support for existing Rails apps. Based in Portland, OR, Planet Argon has been a member of the Rails community since 2004.

[1] [http://www.dgibbons.net/articles/2006/8/8/why-you-need-multiple-](http://www.dgibbons.net/articles/2006/8/8/why-you-need-multiple-)  
mongrel-instances-with-rails  
[2] [http://docs.planetargon.com/wiki/show/ProxyOverview](http://docs.planetargon.com/wiki/show/ProxyOverview)  
[3] [http://docs.planetargon.com/wiki/show/Pound+and+Mongrel](http://docs.planetargon.com/wiki/show/Pound+and+Mongrel)

Cheers,

Robby

–  
Robby R.  
Founder and Executive Director

PLANET ARGON, LLC  
Ruby on Rails Development, Consulting & Hosting

> **[Planet Argon](https://www.planetargon.com)**
>
> Planet Argon is a Ruby on Rails development agency specializing in maintenance and support for existing Rails apps. Based in Portland, OR, Planet Argon has been a member of the Rails community since 2004.

[www.robbyonrails.com](http://www.robbyonrails.com)

+1 503 445 2457  
+1 877 55 ARGON [toll free]  
+1 815 642 4068 [fax]

---

<div class="post-metadata">

**Author:** ![jjkiesch](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/bc79bd/32.png) [@jjkiesch](https://www.ruby-forum.com/u/jjkiesch)\
**Post date:** [September 28, 2006, 8:39am UTC](https://www.ruby-forum.com/t/best-setup-for-shared-hosting/70273/5 "2006-09-28T08:39:12Z")

</div>

I used Litespeed + Ruby LSAPI as an experiment at  
[http://freeonrails.com](http://freeonrails.com) and it’s been far more better than Apache/fcgi.  
It’s surely worth a shot.

Thanks,  
Pratik

On 9/28/06, Brian H. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> > > 
> > 
> > …and we encourage you to do it all with Capistrano!
> 
> >

–  
rm -rf / 2\>/dev/null - [http://null.in](http://null.in)

Dont judge those who try and fail, judge those who fail to try…

---

<div class="post-metadata">

**Author:** ![jjkiesch](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/bc79bd/32.png) [@jjkiesch](https://www.ruby-forum.com/u/jjkiesch)\
**Post date:** [September 28, 2006, 8:17am UTC](https://www.ruby-forum.com/t/best-setup-for-shared-hosting/70273/6 "2006-09-28T08:17:10Z")

</div>

Robby:

I didn’t want to speak for you but I hoped you’d chime in. 🙂
