mongrel

Segfault on Mongrel_Rails start

When I run mongrel_rails start for my application, I get the following error: /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/gems/1.8/gems/mongrel-1.1.5/lib/http11.bundle: [BUG] Segmentation fault ruby 1.8.7 (2010-06-23 patchlevel 299) [i686-darwin10] I am running Snow Leopard and Ruby, Rails, and PostgreSQL 8.4 v...

deployment for jruby on rails app

I am trying to deploy a jruby on rails application. Right now I am running mongrel + Apache2 using reverse proxy from mod_proxy. However, because mongrel_jcluster does not work for the latest versions of jruby, I am only able to run one mongrel server, and cant take advantage of load balancing from apache2. Is there any way other way ...

Replace Mongrel with Apache

I am new to Rails, so bear with me, I need to have apache tomcat as application server. How do i configure that by replacing the default Mongrel ...

Mongrel cluster does not start on Snow Leopard

Hi, I fail to deploy my ruby (v1.8.7) rails (v2.3.5) application on Snow Leopard (10.6.3). After "cap deploy", the Mongrel-cluster (v1.1.5) fails to start up with the following output in mongrel.*.log: ** Daemonized, any open files are closed. Look at tmp/pids/mongrel.8000.pid and log/mongrel.8000.log for info. ** Starting Mongrel l...

httperf for load testing and validating response

I want to load test a site with httperf. But this is not for performance testing. It is to reproduce a random bug where sessions are not maintained correctly and content generated by users are swapped. Can i use httperf to make simultaneous post requests and verify the response/results of the post are consistent? ...

Rails InvalidAuthenticityToken at random times

Here is the deal. Our application is working and is being used by writers to send in content for the web site. Problem is, from times to times, our writers get an error after submiting the form for any rescource in the site. The error after checking the production logs was the good old InvalidAuthenticityToken. Problem is, they don't c...

Mongrel CACHE log entries, specifically CACHE entries for SQL statements

In the process of looking at my logs from Mongrel, I found some SQL statements that I wanted to optimize. While looking into these, I noticed that these entries sometimes have CACHE in front of them, e.g.: CACHE (0.0ms) SELECT * FROM `customers` WHERE (`customers`.`id` = 35) Given the execution time, I'm assuming Mongrel really is ...

What happens to a user request when a Mongrel thread locks up & gets restarted by monit?

Hi, I cannot find an answer to this anywhere I've looked so hoping someone can help. We run a pack of 30 mongrel servers & have just started to use monit to identify locked threads and restart them. My question is, what happens to the users request, which was being handled by the locked thread when this happens - especially, what do ...

Is there a way to actively monitor HTTP requests on Rails, to direct the request to another mongrel if it times out?

Hi, I am working with a client who's server admin refuses to install monit or god on their webserver to restart locked or slow mongrels / threads as they reckon the application should just work flawlessly and threads should never lock / go slow. Unfortunately their app makes a lot of calls to 3rd party webservices, many of which are sl...

Mongrel Gzip Compression

I would like to compress my mongrel's output, I found this plugin, but it's from 2007, and I could not make it work. I have haproxy balancing among several mongrels on my server, I've apache, but it's used only for static content, so mod_deflate doesnt affect the page itself. Any suggestion? If haproxy could compress, that would do it...

Mongrel Cluster fails to start

Hello, I have an issue with Mongrel cluster start-up, when I start the cluster I am getting the following error: /usr/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in 'gem_original_require': no such file to load -- /home/admin/test-project/test-app/config/environment (LoadError) log file link I am using this command to st...

"You are being redirected" bug in Rails 2.3.8 + mongrel

We've recently upgraded Rails to 2.3.8 (from something so ancient you don't wanna know). Everything was going fine and everything worked just fine in development, then when we put it up on staging we discovered that redirections suddenly stopped working. Instead of being redirected (say during login) we just got a blank page that says ...

Mongrel does not shut down using CTRL-C

I am building a Rails 2.3.5 application using Ruby 1.8.7. My development platform is a MacBook Pro running Snow Leopard 10.6.4. Often during development I can not shut down mongrel using the Ctrl-C command in Terminal. It does work sometimes but 8 times out of 10 it does not work. I do not think the Ctrl-C failure is linked to any partic...

Significance of /dev/null in Web Servers?

Recently I've heard a bit about the implementation (or rather, use of) /dev/null in Mongrel2, as well as other projects. However, I've never seen it explained what this actually means. What does this mean, and why is it good for scalability (as I've seen it be claimed)? ...

Setting up virtual hosts for Rails apps on Apache and Mongrel

I have a single Linux server running 3 site on Apache. Let's call them RailsApp1, RailsApp2, and SimpleApp. Both Rails applications are using Mongrel clusters. The other application is just a single HTML file. I have different Virtual Host files setup in Apache for each site, as well as mongrel_cluster.yml files for both Rails sites (cod...

Can mongrel be used in production for ruby on rails?

Unlike Webrick, can Mongrel be used in production? I'm looking for a small web server for Ruby on Rails that can be used locally in case of an emergency and all lines to the main webserver on the Internet are down. I thought I could start it with a batch file like ruby script/server and webrick does. Thank you for any help. ...

Why would running a Rails app as a WEBrick server work, but installing it as a Mongrel service would not?

Yet another newbie RoR question from me. I started banging my head against a wall last night when I simply could not get my Rails app to display in my browser after installing it as a Mongrel service. I installed it using a command like this (from the app's root directory): mongrel_rails service::install -N MyAppName -e development -...

how to I force apache to handle download request...running apache+mongrel

hii all, Am running apche as frontend to mongrel ,i added these line in Apache's httpd.conf file LoadModule rewrite_module modules/mod_rewrite.so LoadModule proxy_module modules/mod_proxy.so LoadModule proxy_balancer_module modules/mod_proxy_balancer.so LoadModule proxy_http_module modules/mod_proxy_http.so LoadModule xse...

Does creating more mongrel clusters improves application performance/response?

Hi I have currently 10 instances of mongrel cluster running. But at rush hour my avg response time goes up. See bellow Average db time 0.00 sec Average request length 24.92 sec Average view time 24.73 sec Requests 8.10 req/min Slow Requests 5.40 req/min Slow requests percentage 67% HOw can I improve avg response time? How...

ruby on rails mongrel on local network

Okay so I have instant rails running on my windows laptop, I thought if I have the mongrel server running (ruby script/server), then I should be able to access the application using my laptops external ip address. (Ex. 172.17.104.100:3000/fontpage) However, when I try it from my roommates computer I cannot access the app. Any suggestion...