Cindy
 
Photo by caribbean

Let’s say you have a Ruby on Rails website hosted at Slicehost. Let’s also say you used the snazzy deprec instructions to install said web site. And finally, let’s say said website is receiving increased traffic. Well, you may very well need to add another mongrel instance so your site’s performance remains acceptable.

That’s easy!

  • Add 1 to the “servers” parameter in /etc/mongrel_cluster/appname.yml.
Maruku could not parse this XML/HTML: 
<pre>servers: 3  # previously was 2
  • Add another balance member to /usr/local/apache2/conf/apps/appname.conf:
Maruku could not parse this XML/HTML: 
<pre>BalancerMember http://127.0.0.1:8000
BalancerMember http://127.0.0.1:8001  # Added this one
  • Restart the mongrel cluster using Capistrano:
cap restart_mongrel_cluster
  • Restart the apache server using Capistrano:
cap restart_apache   # or cap apache_restart

You’re done!

Aug 29, 2007 · Subscribe · Archive · Projects · Twitter · GitHub · Flickr