From mental at rydia.net Mon Jan 1 00:16:48 2007 From: mental at rydia.net (MenTaLguY) Date: Mon, 01 Jan 2007 00:16:48 -0500 Subject: [Mongrel] [ANN] fastthread 0.6.1 In-Reply-To: <71166b3b0612312021i32745625s2b6cbd3453ac7998@mail.gmail.com> References: <1167548672.17601.61.camel@localhost.localdomain> <20061231052624.b01d4f07.zedshaw@zedshaw.com> <71166b3b0612312021i32745625s2b6cbd3453ac7998@mail.gmail.com> Message-ID: <1167628608.25880.10.camel@localhost.localdomain> We should probably get the current fastthread in releases/gems/ too, so people testing the mongrel RCs get the latest ones. -mental -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 189 bytes Desc: This is a digitally signed message part Url : http://rubyforge.org/pipermail/mongrel-users/attachments/20070101/d40a76c9/attachment.bin From jdz99 at hotmail.com Tue Jan 2 11:40:55 2007 From: jdz99 at hotmail.com (Jim Douglas) Date: Tue, 02 Jan 2007 16:40:55 +0000 Subject: [Mongrel] my apache 2.2 conf In-Reply-To: <86lkl19htl.fsf@bitty.lumos.us> Message-ID: >From: Steven Lumos >Reply-To: mongrel-users at rubyforge.org >To: mongrel-users at rubyforge.org >Subject: [Mongrel] my apache 2.2 conf >Date: Thu, 21 Dec 2006 11:20:38 -0800 > > >I just finished updating our internal site, which hosts multiple Rails >apps, to Apache 2.2.3. It also has a TWiki rewritten into the root, >ViewVC mounted on /cvs, and /server-status and /server-info. > > > ServerName int.example.com > ServerAlias int > > CustomLog /var/www/logs/int.example.com/access.log combined > ErrorLog /var/www/logs/int.example.com/error.log > > [...] > > ## Application Server > > # APP1 > > BalancerMember http://127.0.0.1:11001 > > > Alias /app1 /production/app1/public > > Allow from .example.com > RewriteEngine on > RewriteRule ^/?$ balancer://app1%{REQUEST_URI} [P,L] > RewriteCond %{REQUEST_FILENAME} !-f > RewriteRule . balancer://app1%{REQUEST_URI} [P,L] > > # End APP1 > > # APP2 > > BalancerMember http://127.0.0.1:11010 > > > Alias /app2 /dev/app2/public > > Allow from .example.com > RewriteEngine on > RewriteRule ^/?$ balancer://app2%{REQUEST_URI} [P,L] > RewriteCond %{REQUEST_FILENAME} !-f > RewriteRule . balancer://app2%{REQUEST_URI} [P,L] > > # End APP2 > > >Then I give mongrel_rails --prefix app and done. Almost too easy. >And it's going to be almost trivial to add more mongrels whenever we >need them and I set up mongrel_cluster. Thanks again Zed and whoever >is responsible for mod_proxy(_balance). > >Steve > >_______________________________________________ >Mongrel-users mailing list >Mongrel-users at rubyforge.org >http://rubyforge.org/mailman/listinfo/mongrel-users I tried this config and can get it working from the server like so, http://www.myserver.com:3000/ ...but when I try to access this address from a client machine elsewhere I get a "unable to connect error" any ideas? Jim _________________________________________________________________ Find sales, coupons, and free shipping, all in one place! ?MSN Shopping Sales & Deals http://shopping.msn.com/content/shp/?ctid=198,ptnrid=176,ptnrdata=200639 From rsanheim at gmail.com Tue Jan 2 13:19:25 2007 From: rsanheim at gmail.com (Rob Sanheim) Date: Tue, 2 Jan 2007 12:19:25 -0600 Subject: [Mongrel] problem with mongrel/apache2.2.3 and subdomain setup Message-ID: Hi all I got a vps setup amazingly fast using the deprec recipes on Ubuntu edgy, but now I'm having a minor issue where my site loads for the main domain when I only want it accessible from the subdomain. This is a pretty typical setup, apache 2.2.3 -> mongrel_proxy_balancer -> mongrel cluster. I'm sure I'm missing something obvious in the config... I have the conf files pasted below. Should I just be able to set the ServerName like I did in myapp.conf for this to work? Do I need to do something else in the stock apache config? Here's the relevant config files: mongrel_cluster.yml: ======================== cwd: /var/www/apps/myapp/current port: "8000" environment: production address: 127.0.0.1 pid_file: log/mongrel.pid servers: 2 myapp.conf ============================ ServerName myapp.domain.com DocumentRoot /var/www/apps/myapp/current/public Options FollowSymLinks AllowOverride None Order allow,deny Allow from all # Configure mongrel_cluster BalancerMember http://127.0.0.1:8000 BalancerMember http://127.0.0.1:8001 RewriteEngine On # Prevent access to .svn directories RewriteRule ^(.*/)?\.svn/ - [F,L] ErrorDocument 403 "Access Forbidden" # Check for maintenance file and redirect all requests RewriteCond %{DOCUMENT_ROOT}/system/maintenance.html -f RewriteCond %{SCRIPT_FILENAME} !maintenance.html RewriteRule ^.*$ /system/maintenance.html [L] # Rewrite index to check for static RewriteRule ^/$ /index.html [QSA] # Rewrite to check for Rails cached page RewriteRule ^([^.]+)$ $1.html [QSA] # Redirect all non-static requests to cluster RewriteCond %{DOCUMENT_ROOT}/%{REQUEST_FILENAME} !-f RewriteRule ^/(.*)$ balancer://myapp%{REQUEST_URI} [P,QSA,L] # Deflate AddOutputFilterByType DEFLATE text/html text/plain text/xml BrowserMatch ^Mozilla/4 gzip-only-text/html BrowserMatch ^Mozilla/4\.0[678] no-gzip BrowserMatch \bMSIE !no-gzip !gzip-only-text/html ErrorLog logs/myapp.domain.com-error_log CustomLog logs/myapp.domain.com-access_log combined ========================= the apache httpd.conf is pretty stock, but here's the part that I _thought_ would allow me to serve from the main domain just using apache: ServerName domain.com DocumentRoot "/usr/local/apache2/htdocs" Options FollowSymLinks AllowOverride None Order deny,allow Deny from all Options Indexes FollowSymLinks AllowOverride None Order allow,deny Allow from all thanks, Rob From zedshaw at zedshaw.com Tue Jan 2 13:41:24 2007 From: zedshaw at zedshaw.com (Zed A. Shaw) Date: Tue, 2 Jan 2007 10:41:24 -0800 Subject: [Mongrel] Recommendation: Stalled Mongrel? Memcache Hates Spaces Message-ID: <20070102104124.0b6a36f9.zedshaw@zedshaw.com> Hi Everyone, There's quite a few of you who have contacted me about Mongrel suddenly stopping. After a lot of investigation, I found that the common thread between all of you is memcache and Eric Hodel's memcache-client. People who were running this combination would have intermittent pauses and investigating the stalled mongrels showed that memcache-client was waiting for information from memcached. A friend just told me that he found out the problem is memcache does not accept keys with spaces in them. From this spec: http://cvs.danga.com/browse.cgi/wcmtools/memcached/doc/protocol.txt?rev=HEAD We have this paragraph: "Data stored by memcached is identified with the help of a key. A key is a text string which should uniquely identify the data for clients that are interested in storing and retrieving it. Currently the length limit of a key is set at 250 characters (of course, normally clients wouldn't need to use such long keys); the key must not include control characters or whitespace." Notice the last part "the key most not include control characters or whitespace". Since memcache-client doesn't currently escape your keys for you (not sure if it should actually), you have to do this yourself or bad super evil things happen. The few people who have made this change report no more stopped mongrel processes. Please try this out and report back to me if it fixes things. -- Zed A. Shaw, MUDCRAP-CE Master Black Belt Sifu http://www.zedshaw.com/ http://www.awprofessional.com/title/0321483502 -- The Mongrel Book http://mongrel.rubyforge.org/ http://www.lingr.com/room/3yXhqKbfPy8 -- Come get help. From michael.dauria at gmail.com Tue Jan 2 13:41:39 2007 From: michael.dauria at gmail.com (Michael D'Auria) Date: Tue, 2 Jan 2007 13:41:39 -0500 Subject: [Mongrel] my apache 2.2 conf In-Reply-To: References: <86lkl19htl.fsf@bitty.lumos.us> Message-ID: <1907e2ca0701021041l4cc4a6b9v2830d966013015e7@mail.gmail.com> Mongrel is probably set up to listen on port 3000 for localhost only. Shouldn't you be connecting via port 80 instead and let Apache talk to Mongrel? http://www.myserver.com On 1/2/07, Jim Douglas wrote: > > >From: Steven Lumos > >Reply-To: mongrel-users at rubyforge.org > >To: mongrel-users at rubyforge.org > >Subject: [Mongrel] my apache 2.2 conf > >Date: Thu, 21 Dec 2006 11:20:38 -0800 > > > > > >I just finished updating our internal site, which hosts multiple Rails > >apps, to Apache 2.2.3. It also has a TWiki rewritten into the root, > >ViewVC mounted on /cvs, and /server-status and /server-info. > > > > > > ServerName int.example.com > > ServerAlias int > > > > CustomLog /var/www/logs/int.example.com/access.log combined > > ErrorLog /var/www/logs/int.example.com/error.log > > > > [...] > > > > ## Application Server > > > > # APP1 > > > > BalancerMember http://127.0.0.1:11001 > > > > > > Alias /app1 /production/app1/public > > > > Allow from .example.com > > RewriteEngine on > > RewriteRule ^/?$ balancer://app1%{REQUEST_URI} [P,L] > > RewriteCond %{REQUEST_FILENAME} !-f > > RewriteRule . balancer://app1%{REQUEST_URI} [P,L] > > > > # End APP1 > > > > # APP2 > > > > BalancerMember http://127.0.0.1:11010 > > > > > > Alias /app2 /dev/app2/public > > > > Allow from .example.com > > RewriteEngine on > > RewriteRule ^/?$ balancer://app2%{REQUEST_URI} [P,L] > > RewriteCond %{REQUEST_FILENAME} !-f > > RewriteRule . balancer://app2%{REQUEST_URI} [P,L] > > > > # End APP2 > > > > > >Then I give mongrel_rails --prefix app and done. Almost too easy. > >And it's going to be almost trivial to add more mongrels whenever we > >need them and I set up mongrel_cluster. Thanks again Zed and whoever > >is responsible for mod_proxy(_balance). > > > >Steve > > > >_______________________________________________ > >Mongrel-users mailing list > >Mongrel-users at rubyforge.org > >http://rubyforge.org/mailman/listinfo/mongrel-users > > > I tried this config and can get it working from the server like so, > > http://www.myserver.com:3000/ > > ...but when I try to access this address from a client machine elsewhere I > get a "unable to connect error" > > any ideas? > > Jim > > _________________________________________________________________ > Find sales, coupons, and free shipping, all in one place! MSN Shopping > Sales & Deals > http://shopping.msn.com/content/shp/?ctid=198,ptnrid=176,ptnrdata=200639 > > > > _______________________________________________ > Mongrel-users mailing list > Mongrel-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/mongrel-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/mongrel-users/attachments/20070102/fc42f20a/attachment-0001.html From me at seebq.com Tue Jan 2 13:50:43 2007 From: me at seebq.com (Charles Brian Quinn) Date: Tue, 2 Jan 2007 13:50:43 -0500 Subject: [Mongrel] problem with mongrel/apache2.2.3 and subdomain setup In-Reply-To: References: Message-ID: <3a2de0cd0701021050y56cf7fc1j743a324a32adc5d6@mail.gmail.com> I'd add another: ServerName www.otherdomain.tld DocumentRoot /www/otherdomain for your main document root, since you're using VirtualHosts. and make sure that loads last -- this could mean if you're doing something like: Include /etc/rails/*.conf in an apache configuration file that you name the files accordingly (perhaps 00_my_site.conf and 99_default_vhost.conf) hope that helps, -- Charles Brian Quinn self-promotion: www.seebq.com highgroove studios: www.highgroove.com slingshot hosting: www.slingshothosting.com Ruby on Rails Bootcamp at the Big Nerd Ranch Intensive Ruby on Rails Training: http://www.bignerdranch.com/classes/ruby.shtml On 1/2/07, Rob Sanheim wrote: > Hi all > > I got a vps setup amazingly fast using the deprec recipes on Ubuntu > edgy, but now I'm having a minor issue where my site loads for the > main domain when I only want it accessible from the subdomain. This > is a pretty typical setup, apache 2.2.3 -> mongrel_proxy_balancer -> > mongrel cluster. I'm sure I'm missing something obvious in the > config... > > I have the conf files pasted below. Should I just be able to set the > ServerName like I did in myapp.conf for this to work? Do I need to do > something else in the stock apache config? > > Here's the relevant config files: > > mongrel_cluster.yml: > ======================== > cwd: /var/www/apps/myapp/current > port: "8000" > environment: production > address: 127.0.0.1 > pid_file: log/mongrel.pid > servers: 2 > > myapp.conf > ============================ > > ServerName myapp.domain.com > > DocumentRoot /var/www/apps/myapp/current/public > > > Options FollowSymLinks > AllowOverride None > Order allow,deny > Allow from all > > > # Configure mongrel_cluster > > BalancerMember http://127.0.0.1:8000 > BalancerMember http://127.0.0.1:8001 > > > RewriteEngine On > > # Prevent access to .svn directories > RewriteRule ^(.*/)?\.svn/ - [F,L] > ErrorDocument 403 "Access Forbidden" > > # Check for maintenance file and redirect all requests > RewriteCond %{DOCUMENT_ROOT}/system/maintenance.html -f > RewriteCond %{SCRIPT_FILENAME} !maintenance.html > RewriteRule ^.*$ /system/maintenance.html [L] > > # Rewrite index to check for static > RewriteRule ^/$ /index.html [QSA] > > # Rewrite to check for Rails cached page > RewriteRule ^([^.]+)$ $1.html [QSA] > > # Redirect all non-static requests to cluster > RewriteCond %{DOCUMENT_ROOT}/%{REQUEST_FILENAME} !-f > RewriteRule ^/(.*)$ balancer://myapp%{REQUEST_URI} [P,QSA,L] > > # Deflate > AddOutputFilterByType DEFLATE text/html text/plain text/xml > BrowserMatch ^Mozilla/4 gzip-only-text/html > BrowserMatch ^Mozilla/4\.0[678] no-gzip > BrowserMatch \bMSIE !no-gzip !gzip-only-text/html > > ErrorLog logs/myapp.domain.com-error_log > CustomLog logs/myapp.domain.com-access_log combined > > ========================= > the apache httpd.conf is pretty stock, but here's the part that I > _thought_ would allow me to serve from the main domain just using > apache: > > ServerName domain.com > DocumentRoot "/usr/local/apache2/htdocs" > > Options FollowSymLinks > AllowOverride None > Order deny,allow > Deny from all > > > Options Indexes FollowSymLinks > AllowOverride None > Order allow,deny > Allow from all > > > thanks, > Rob > _______________________________________________ > Mongrel-users mailing list > Mongrel-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/mongrel-users > From kovacs at gmail.com Tue Jan 2 15:09:30 2007 From: kovacs at gmail.com (Michael Kovacs) Date: Tue, 2 Jan 2007 12:09:30 -0800 Subject: [Mongrel] problems with apache 2.2 proxying to mongrel cluster Message-ID: <4C751C24-C739-411A-A763-55752BA08FEF@gmail.com> Hi all, I've been having problems with the apache 2.2-mod_proxy_balancer- mongrel setup. My setup is: CentOS 4.3 apache 2.2.3 (compiled from source) with mod_proxy_balancer mysql 4.1 ruby 1.8.4 mongrel 0.3.14 (I know I need to update but I think this problem is independent of the mongrel version) mongrel_cluster 0.2.0 rails_machine 0.1.1 I have apache setup as per Coda's configuration on his blog posting from several months back. http://blog.codahale.com/2006/06/19/time-for-a-grown-up-server-rails- mongrel-apache-capistrano-and-you/ I have 4 mongrels in my cluster. Things work fine for periods of time but after several hours of inactivity (I think 8 hours or so) I experience oddness where only 1 of the 4 mongrels is properly responding. I end up getting a "500 internal server error" 3 out of 4 requests as they round robin from mongrel to mongrel. There is nothing in the production log file nor in the mongrel log. I've reproduced this problem on my staging box as well as my production box. The last time I reproduced the problem I decided to run "top" and see what's going on when I hit the server. Mongrel does receive every request but mysql is only active on the 1 request that works. In the other mongrels it never spikes up in CPU usage. Looking at the mysql process list revealed that all of the processes had received the "sleep" command but one of the processes is still working properly. I've played with connection timeouts other than to set the timeout in my application's environment (ActiveRecord::Base.verification_timeout = 14400) as well as the mysql interactive_timeout variable but it seems that all the mongrels should work or they shouldn't. The fact that 1 out of 4 always works is rather puzzling to me. Trying a 'killall -USR1 mongrel_rails" to turn debug on simply killed the 4 threads running mongrel. So now I'm running the cluster in debug mode and am going to just let it sit there for several hours until it happens again and hopefully get some idea of where the breakdown is happening. I still think it has to be a mysql connection timeout but again, the fact that 1 of the 4 always works doesn't lend credence to the timeout theory. Has anyone experienced this phenomenon themselves? Thanks for any tips/pointers and thanks Zed for all your hard work with mongrel. -Michael http://javathehutt.blogspot.com -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/mongrel-users/attachments/20070102/2657856d/attachment.html From jgeiger at gmail.com Tue Jan 2 16:36:48 2007 From: jgeiger at gmail.com (Joey Geiger) Date: Tue, 2 Jan 2007 15:36:48 -0600 Subject: [Mongrel] problems with apache 2.2 proxying to mongrel cluster In-Reply-To: <4C751C24-C739-411A-A763-55752BA08FEF@gmail.com> References: <4C751C24-C739-411A-A763-55752BA08FEF@gmail.com> Message-ID: <466af3440701021336j767ca23apbe685cb0b7203fc4@mail.gmail.com> This may have to do with log rotation. There was a thread about similar issue posted in I believe December. You might want to try searching the mailing list archives. You're probably rotating your logs based on a specific size, which is why it's happening every couple hours, instead of nightly. On 1/2/07, Michael Kovacs wrote: > Hi all, > > I've been having problems with the apache 2.2-mod_proxy_balancer-mongrel > setup. > > My setup is: > > CentOS 4.3 > apache 2.2.3 (compiled from source) with mod_proxy_balancer > mysql 4.1 > ruby 1.8.4 > mongrel 0.3.14 (I know I need to update but I think this problem is > independent of the mongrel version) > mongrel_cluster 0.2.0 > rails_machine 0.1.1 > > I have apache setup as per Coda's configuration on his blog posting from > several months back. > http://blog.codahale.com/2006/06/19/time-for-a-grown-up-server-rails-mongrel-apache-capistrano-and-you/ > > I have 4 mongrels in my cluster. > > Things work fine for periods of time but after several hours of inactivity > (I think 8 hours or so) I experience oddness where only 1 of the 4 mongrels > is properly > responding. I end up getting a "500 internal server error" 3 out of 4 > requests as they round robin from mongrel to mongrel. There is nothing in > the production > log file nor in the mongrel log. I've reproduced this problem on my staging > box as well as my production box. > > The last time I reproduced the problem I decided to run "top" and see what's > going on when I hit the server. > Mongrel does receive every request but mysql is only active on the 1 request > that works. In the other mongrels it never spikes up in CPU usage. > > Looking at the mysql process list revealed that all of the processes had > received the "sleep" command but one of the processes is still > working properly. I've played with connection timeouts other than to set the > timeout in my application's environment > (ActiveRecord::Base.verification_timeout = 14400) as well as the mysql > interactive_timeout variable but it seems that all the mongrels should work > or they shouldn't. The fact that 1 out of 4 always works is rather puzzling > to me. > > Trying a 'killall -USR1 mongrel_rails" to turn debug on simply killed the 4 > threads running mongrel. So now I'm running the cluster in debug mode and am > going to just let it sit there for several hours until it happens again and > hopefully get some idea of where the breakdown is happening. I still think > it has to be a mysql connection timeout but again, the fact that 1 of the 4 > always works doesn't lend credence to the timeout theory. > > Has anyone experienced this phenomenon themselves? > > Thanks for any tips/pointers and thanks Zed for all your hard work with > mongrel. > > > > -Michaelhttp://javathehutt.blogspot.com > > > _______________________________________________ > Mongrel-users mailing list > Mongrel-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/mongrel-users > > From shawn at brmethod.com Tue Jan 2 16:59:17 2007 From: shawn at brmethod.com (Shawn Hill) Date: Tue, 2 Jan 2007 15:59:17 -0600 Subject: [Mongrel] problems with apache 2.2 proxying to mongrel cluster In-Reply-To: <4C751C24-C739-411A-A763-55752BA08FEF@gmail.com> Message-ID: <0MKoyl-1H1ra12qlX-0005JG@mrelay.perfora.net> I have the same problem. People (including myself) use monit to ensure processes don't freeze and some also set up scripts to periodically restart individual mongrels (mine restart every 30 minutes.) My setup: Linux 2.6.18 everything else is the same, except I upgraded mongrel (which had no effect on the problem.) Appreciate suggestions from people who have encountered and successfully resolved this issue. _____ From: mongrel-users-bounces at rubyforge.org [mailto:mongrel-users-bounces at rubyforge.org] On Behalf Of Michael Kovacs Sent: Tuesday, January 02, 2007 2:10 PM To: mongrel-users at rubyforge.org Subject: [Mongrel] problems with apache 2.2 proxying to mongrel cluster Hi all, I've been having problems with the apache 2.2-mod_proxy_balancer-mongrel setup. My setup is: CentOS 4.3 apache 2.2.3 (compiled from source) with mod_proxy_balancer mysql 4.1 ruby 1.8.4 mongrel 0.3.14 (I know I need to update but I think this problem is independent of the mongrel version) mongrel_cluster 0.2.0 rails_machine 0.1.1 I have apache setup as per Coda's configuration on his blog posting from several months back. http://blog.codahale.com/2006/06/19/time-for-a-grown-up-server-rails-mongrel -apache-capistrano-and-you/ I have 4 mongrels in my cluster. Things work fine for periods of time but after several hours of inactivity (I think 8 hours or so) I experience oddness where only 1 of the 4 mongrels is properly responding. I end up getting a "500 internal server error" 3 out of 4 requests as they round robin from mongrel to mongrel. There is nothing in the production log file nor in the mongrel log. I've reproduced this problem on my staging box as well as my production box. The last time I reproduced the problem I decided to run "top" and see what's going on when I hit the server. Mongrel does receive every request but mysql is only active on the 1 request that works. In the other mongrels it never spikes up in CPU usage. Looking at the mysql process list revealed that all of the processes had received the "sleep" command but one of the processes is still working properly. I've played with connection timeouts other than to set the timeout in my application's environment (ActiveRecord::Base.verification_timeout = 14400) as well as the mysql interactive_timeout variable but it seems that all the mongrels should work or they shouldn't. The fact that 1 out of 4 always works is rather puzzling to me. Trying a 'killall -USR1 mongrel_rails" to turn debug on simply killed the 4 threads running mongrel. So now I'm running the cluster in debug mode and am going to just let it sit there for several hours until it happens again and hopefully get some idea of where the breakdown is happening. I still think it has to be a mysql connection timeout but again, the fact that 1 of the 4 always works doesn't lend credence to the timeout theory. Has anyone experienced this phenomenon themselves? Thanks for any tips/pointers and thanks Zed for all your hard work with mongrel. -Michael http://javathehutt.blogspot.com -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/mongrel-users/attachments/20070102/c8e6ebc7/attachment-0001.html From jdz99 at hotmail.com Tue Jan 2 17:01:18 2007 From: jdz99 at hotmail.com (Jim Douglas) Date: Tue, 02 Jan 2007 22:01:18 +0000 Subject: [Mongrel] my apache 2.2 conf In-Reply-To: <1907e2ca0701021041l4cc4a6b9v2830d966013015e7@mail.gmail.com> Message-ID: >From: "Michael D'Auria" >Reply-To: mongrel-users at rubyforge.org >To: mongrel-users at rubyforge.org >Subject: Re: [Mongrel] my apache 2.2 conf >Date: Tue, 2 Jan 2007 13:41:39 -0500 > >Mongrel is probably set up to listen on port 3000 for localhost only. >Shouldn't you be connecting via port 80 instead and let Apache talk to >Mongrel? http://www.myserver.com > >On 1/2/07, Jim Douglas wrote: >> >> >From: Steven Lumos >> >Reply-To: mongrel-users at rubyforge.org >> >To: mongrel-users at rubyforge.org >> >Subject: [Mongrel] my apache 2.2 conf >> >Date: Thu, 21 Dec 2006 11:20:38 -0800 >> > >> > >> >I just finished updating our internal site, which hosts multiple Rails >> >apps, to Apache 2.2.3. It also has a TWiki rewritten into the root, >> >ViewVC mounted on /cvs, and /server-status and /server-info. >> > >> > >> > ServerName int.example.com >> > ServerAlias int >> > >> > CustomLog /var/www/logs/int.example.com/access.log combined >> > ErrorLog /var/www/logs/int.example.com/error.log >> > >> > [...] >> > >> > ## Application Server >> > >> > # APP1 >> > >> > BalancerMember http://127.0.0.1:11001 >> > >> > >> > Alias /app1 /production/app1/public >> > >> > Allow from .example.com >> > RewriteEngine on >> > RewriteRule ^/?$ balancer://app1%{REQUEST_URI} [P,L] >> > RewriteCond %{REQUEST_FILENAME} !-f >> > RewriteRule . balancer://app1%{REQUEST_URI} [P,L] >> > >> > # End APP1 >> > >> > # APP2 >> > >> > BalancerMember http://127.0.0.1:11010 >> > >> > >> > Alias /app2 /dev/app2/public >> > >> > Allow from .example.com >> > RewriteEngine on >> > RewriteRule ^/?$ balancer://app2%{REQUEST_URI} [P,L] >> > RewriteCond %{REQUEST_FILENAME} !-f >> > RewriteRule . balancer://app2%{REQUEST_URI} [P,L] >> > >> > # End APP2 >> > >> > >> >Then I give mongrel_rails --prefix app and done. Almost too easy. >> >And it's going to be almost trivial to add more mongrels whenever we >> >need them and I set up mongrel_cluster. Thanks again Zed and whoever >> >is responsible for mod_proxy(_balance). >> > >> >Steve >> > >> >_______________________________________________ >> >Mongrel-users mailing list >> >Mongrel-users at rubyforge.org >> >http://rubyforge.org/mailman/listinfo/mongrel-users >> >> >>I tried this config and can get it working from the server like so, >> >>http://www.myserver.com:3000/ >> >>...but when I try to access this address from a client machine elsewhere I >>get a "unable to connect error" >> >>any ideas? >> >>Jim >> >>_________________________________________________________________ >>Find sales, coupons, and free shipping, all in one place! MSN Shopping >>Sales & Deals >>http://shopping.msn.com/content/shp/?ctid=198,ptnrid=176,ptnrdata=200639 >> >> >> >>_______________________________________________ >>Mongrel-users mailing list >>Mongrel-users at rubyforge.org >>http://rubyforge.org/mailman/listinfo/mongrel-users >> >> >_______________________________________________ >Mongrel-users mailing list >Mongrel-users at rubyforge.org >http://rubyforge.org/mailman/listinfo/mongrel-users I have a websirte and want to demo a RoR appin a sub directory. Apache in front of Mongrel, that's why I want http://www.myserver.com:/ror, but I keep getting this error, Status: 500 Internal Server Error Content-Type: text/html Application error (Rails) So I am getting to it via, http://www.myserver.com/3000 Jim _________________________________________________________________ Type your favorite song.? Get a customized station.? Try MSN Radio powered by Pandora. http://radio.msn.com/?icid=T002MSN03A07001 From kovacs at gmail.com Tue Jan 2 17:32:46 2007 From: kovacs at gmail.com (Michael Kovacs) Date: Tue, 2 Jan 2007 14:32:46 -0800 Subject: [Mongrel] problems with apache 2.2 proxying to mongrel cluster In-Reply-To: <466af3440701021336j767ca23apbe685cb0b7203fc4@mail.gmail.com> References: <4C751C24-C739-411A-A763-55752BA08FEF@gmail.com> <466af3440701021336j767ca23apbe685cb0b7203fc4@mail.gmail.com> Message-ID: Hmm... thanks for the suggestion I'll give that a look as well as search the archives here. I do have the logger rotating daily right now: config.logger = Logger.new(config.log_path, 'daily') I think I'll remove that and see if this occurs again. The thing that still bothers me though is that if one mongrel is broken from this shouldn't they all be? I can always count on 1 of 4 mongrels working so that every 3rd request is successful :-) In order to monitor that I'd have to hit the site twice to ensure that I'm not just getting the good mongrel on the first hit. Not very fresh. -Michael http://javathehutt.blogspot.com On Jan 2, 2007, at 1:36 PM, Joey Geiger wrote: > This may have to do with log rotation. There was a thread about > similar issue posted in I believe December. You might want to try > searching the mailing list archives. > > You're probably rotating your logs based on a specific size, which is > why it's happening every couple hours, instead of nightly. > > On 1/2/07, Michael Kovacs wrote: >> Hi all, >> >> I've been having problems with the apache 2.2-mod_proxy_balancer- >> mongrel >> setup. >> >> My setup is: >> >> CentOS 4.3 >> apache 2.2.3 (compiled from source) with mod_proxy_balancer >> mysql 4.1 >> ruby 1.8.4 >> mongrel 0.3.14 (I know I need to update but I think this problem is >> independent of the mongrel version) >> mongrel_cluster 0.2.0 >> rails_machine 0.1.1 >> >> I have apache setup as per Coda's configuration on his blog >> posting from >> several months back. >> http://blog.codahale.com/2006/06/19/time-for-a-grown-up-server- >> rails-mongrel-apache-capistrano-and-you/ >> >> I have 4 mongrels in my cluster. >> >> Things work fine for periods of time but after several hours of >> inactivity >> (I think 8 hours or so) I experience oddness where only 1 of the 4 >> mongrels >> is properly >> responding. I end up getting a "500 internal server error" 3 out of 4 >> requests as they round robin from mongrel to mongrel. There is >> nothing in >> the production >> log file nor in the mongrel log. I've reproduced this problem on >> my staging >> box as well as my production box. >> >> The last time I reproduced the problem I decided to run "top" and >> see what's >> going on when I hit the server. >> Mongrel does receive every request but mysql is only active on the >> 1 request >> that works. In the other mongrels it never spikes up in CPU usage. >> >> Looking at the mysql process list revealed that all of the >> processes had >> received the "sleep" command but one of the processes is still >> working properly. I've played with connection timeouts other than >> to set the >> timeout in my application's environment >> (ActiveRecord::Base.verification_timeout = 14400) as well as the >> mysql >> interactive_timeout variable but it seems that all the mongrels >> should work >> or they shouldn't. The fact that 1 out of 4 always works is rather >> puzzling >> to me. >> >> Trying a 'killall -USR1 mongrel_rails" to turn debug on simply >> killed the 4 >> threads running mongrel. So now I'm running the cluster in debug >> mode and am >> going to just let it sit there for several hours until it happens >> again and >> hopefully get some idea of where the breakdown is happening. I >> still think >> it has to be a mysql connection timeout but again, the fact that 1 >> of the 4 >> always works doesn't lend credence to the timeout theory. >> >> Has anyone experienced this phenomenon themselves? >> >> Thanks for any tips/pointers and thanks Zed for all your hard work >> with >> mongrel. >> >> >> >> -Michaelhttp://javathehutt.blogspot.com >> >> >> _______________________________________________ >> Mongrel-users mailing list >> Mongrel-users at rubyforge.org >> http://rubyforge.org/mailman/listinfo/mongrel-users >> >> > _______________________________________________ > Mongrel-users mailing list > Mongrel-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/mongrel-users From kovacs at gmail.com Tue Jan 2 17:35:08 2007 From: kovacs at gmail.com (Michael Kovacs) Date: Tue, 2 Jan 2007 14:35:08 -0800 Subject: [Mongrel] problems with apache 2.2 proxying to mongrel cluster In-Reply-To: <0MKoyl-1H1ra12qlX-0005JG@mrelay.perfora.net> References: <0MKoyl-1H1ra12qlX-0005JG@mrelay.perfora.net> Message-ID: <79FAAADD-0FA5-48EA-B23E-F34756C07DA3@gmail.com> So you are currently proactively restarting mongrel processes every 30 minutes? I have yet to setup monit but have every intention of doing so very soon, but the process of proactively restarting mongrels regardless of state isn't something I'd relish doing. I don't imagine that's the common case. At least I hope not. -Michael http://javathehutt.blogspot.com On Jan 2, 2007, at 1:59 PM, Shawn Hill wrote: > I have the same problem. People (including myself) use monit to > ensure processes don't freeze and some also set up scripts to > periodically restart individual mongrels (mine restart every 30 > minutes.) > > My setup: > Linux 2.6.18 > everything else is the same, except I upgraded mongrel (which had > no effect on the problem.) > > Appreciate suggestions from people who have encountered and > successfully resolved this issue. > > > From: mongrel-users-bounces at rubyforge.org [mailto:mongrel-users- > bounces at rubyforge.org] On Behalf Of Michael Kovacs > Sent: Tuesday, January 02, 2007 2:10 PM > To: mongrel-users at rubyforge.org > Subject: [Mongrel] problems with apache 2.2 proxying to mongrel > cluster > > Hi all, > > I've been having problems with the apache 2.2-mod_proxy_balancer- > mongrel setup. > > My setup is: > > CentOS 4.3 > apache 2.2.3 (compiled from source) with mod_proxy_balancer > mysql 4.1 > ruby 1.8.4 > mongrel 0.3.14 (I know I need to update but I think this problem is > independent of the mongrel version) > mongrel_cluster 0.2.0 > rails_machine 0.1.1 > > I have apache setup as per Coda's configuration on his blog posting > from several months back. > http://blog.codahale.com/2006/06/19/time-for-a-grown-up-server- > rails-mongrel-apache-capistrano-and-you/ > > I have 4 mongrels in my cluster. > > Things work fine for periods of time but after several hours of > inactivity (I think 8 hours or so) I experience oddness where only > 1 of the 4 mongrels is properly > responding. I end up getting a "500 internal server error" 3 out of > 4 requests as they round robin from mongrel to mongrel. There is > nothing in the production > log file nor in the mongrel log. I've reproduced this problem on my > staging box as well as my production box. > > The last time I reproduced the problem I decided to run "top" and > see what's going on when I hit the server. > Mongrel does receive every request but mysql is only active on the > 1 request that works. In the other mongrels it never spikes up in > CPU usage. > > Looking at the mysql process list revealed that all of the > processes had received the "sleep" command but one of the processes > is still > working properly. I've played with connection timeouts other than > to set the timeout in my application's environment > (ActiveRecord::Base.verification_timeout = 14400) as well as the > mysql interactive_timeout variable but it seems that all the > mongrels should work or they shouldn't. The fact that 1 out of 4 > always works is rather puzzling to me. > > Trying a 'killall -USR1 mongrel_rails" to turn debug on simply > killed the 4 threads running mongrel. So now I'm running the > cluster in debug mode and am going to just let it sit there for > several hours until it happens again and hopefully get some idea of > where the breakdown is happening. I still think it has to be a > mysql connection timeout but again, the fact that 1 of the 4 always > works doesn't lend credence to the timeout theory. > Has anyone experienced this phenomenon themselves? > > Thanks for any tips/pointers and thanks Zed for all your hard work > with mongrel. > > -Michael > http://javathehutt.blogspot.com > > _______________________________________________ > Mongrel-users mailing list > Mongrel-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/mongrel-users -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/mongrel-users/attachments/20070102/ec314aab/attachment.html From michael.dauria at gmail.com Tue Jan 2 17:51:31 2007 From: michael.dauria at gmail.com (Michael D'Auria) Date: Tue, 2 Jan 2007 17:51:31 -0500 Subject: [Mongrel] problems with apache 2.2 proxying to mongrel cluster In-Reply-To: References: <4C751C24-C739-411A-A763-55752BA08FEF@gmail.com> <466af3440701021336j767ca23apbe685cb0b7203fc4@mail.gmail.com> Message-ID: <1907e2ca0701021451n709c5b9u66964fa2a4d13540@mail.gmail.com> I didn't know i could use the Logger class like that, pretty sweet. Do people know if rotating the logs via Logger is the issue or just rotating in general? .: Michael :. On 1/2/07, Michael Kovacs wrote: > > Hmm... thanks for the suggestion I'll give that a look as well as > search the archives here. > > I do have the logger rotating daily right now: > config.logger = Logger.new(config.log_path, 'daily') > > I think I'll remove that and see if this occurs again. The thing that > still bothers me though > is that if one mongrel is broken from this shouldn't they all be? I > can always count on 1 of 4 mongrels > working so that every 3rd request is successful :-) In order to > monitor that I'd have to hit the site twice to > ensure that I'm not just getting the good mongrel on the first hit. > Not very fresh. > > -Michael > http://javathehutt.blogspot.com > > On Jan 2, 2007, at 1:36 PM, Joey Geiger wrote: > > > This may have to do with log rotation. There was a thread about > > similar issue posted in I believe December. You might want to try > > searching the mailing list archives. > > > > You're probably rotating your logs based on a specific size, which is > > why it's happening every couple hours, instead of nightly. > > > > On 1/2/07, Michael Kovacs wrote: > >> Hi all, > >> > >> I've been having problems with the apache 2.2-mod_proxy_balancer- > >> mongrel > >> setup. > >> > >> My setup is: > >> > >> CentOS 4.3 > >> apache 2.2.3 (compiled from source) with mod_proxy_balancer > >> mysql 4.1 > >> ruby 1.8.4 > >> mongrel 0.3.14 (I know I need to update but I think this problem is > >> independent of the mongrel version) > >> mongrel_cluster 0.2.0 > >> rails_machine 0.1.1 > >> > >> I have apache setup as per Coda's configuration on his blog > >> posting from > >> several months back. > >> http://blog.codahale.com/2006/06/19/time-for-a-grown-up-server- > >> rails-mongrel-apache-capistrano-and-you/ > >> > >> I have 4 mongrels in my cluster. > >> > >> Things work fine for periods of time but after several hours of > >> inactivity > >> (I think 8 hours or so) I experience oddness where only 1 of the 4 > >> mongrels > >> is properly > >> responding. I end up getting a "500 internal server error" 3 out of 4 > >> requests as they round robin from mongrel to mongrel. There is > >> nothing in > >> the production > >> log file nor in the mongrel log. I've reproduced this problem on > >> my staging > >> box as well as my production box. > >> > >> The last time I reproduced the problem I decided to run "top" and > >> see what's > >> going on when I hit the server. > >> Mongrel does receive every request but mysql is only active on the > >> 1 request > >> that works. In the other mongrels it never spikes up in CPU usage. > >> > >> Looking at the mysql process list revealed that all of the > >> processes had > >> received the "sleep" command but one of the processes is still > >> working properly. I've played with connection timeouts other than > >> to set the > >> timeout in my application's environment > >> (ActiveRecord::Base.verification_timeout = 14400) as well as the > >> mysql > >> interactive_timeout variable but it seems that all the mongrels > >> should work > >> or they shouldn't. The fact that 1 out of 4 always works is rather > >> puzzling > >> to me. > >> > >> Trying a 'killall -USR1 mongrel_rails" to turn debug on simply > >> killed the 4 > >> threads running mongrel. So now I'm running the cluster in debug > >> mode and am > >> going to just let it sit there for several hours until it happens > >> again and > >> hopefully get some idea of where the breakdown is happening. I > >> still think > >> it has to be a mysql connection timeout but again, the fact that 1 > >> of the 4 > >> always works doesn't lend credence to the timeout theory. > >> > >> Has anyone experienced this phenomenon themselves? > >> > >> Thanks for any tips/pointers and thanks Zed for all your hard work > >> with > >> mongrel. > >> > >> > >> > >> -Michaelhttp://javathehutt.blogspot.com > >> > >> > >> _______________________________________________ > >> Mongrel-users mailing list > >> Mongrel-users at rubyforge.org > >> http://rubyforge.org/mailman/listinfo/mongrel-users > >> > >> > > _______________________________________________ > > Mongrel-users mailing list > > Mongrel-users at rubyforge.org > > http://rubyforge.org/mailman/listinfo/mongrel-users > > _______________________________________________ > Mongrel-users mailing list > Mongrel-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/mongrel-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/mongrel-users/attachments/20070102/8f95ba77/attachment-0001.html From ezmobius at gmail.com Tue Jan 2 17:55:32 2007 From: ezmobius at gmail.com (Ezra Zygmuntowicz) Date: Tue, 2 Jan 2007 14:55:32 -0800 Subject: [Mongrel] problems with apache 2.2 proxying to mongrel cluster In-Reply-To: References: <4C751C24-C739-411A-A763-55752BA08FEF@gmail.com> <466af3440701021336j767ca23apbe685cb0b7203fc4@mail.gmail.com> Message-ID: <25274268-2C4C-4CD9-9882-E9CF55759036@brainspl.at> Hey Michael- You should definitely now use the ruby logger to do rotation. That has caused tons of issues for me and others. Use syslog or logrotate to rotate the logs as the Logger rotator is borken trust me. As for why you are having opne process stay alive and the others die. I think what causes that is that all four of your mongrels will try to rotate the logs. And its a free for all. So the one who does it last 'wins' and stays alive. Or if it is a mysql timeout issue then what is probably happening is that only one of your mongrels is getting 'exercised' . By this I mean the load balancer is only sending requests to one mongrel because there is not enough traffic to make it drive all four mongrels. This means that the one mongrel is getting requests which keep its db connection alive. While the others are not getting requests so their db connectiosn die off. I think it's one of these two things. Sop don't use Logger to rotate logs for starters and see if that fixes it for you. Cheers -Ezra On Jan 2, 2007, at 2:32 PM, Michael Kovacs wrote: > Hmm... thanks for the suggestion I'll give that a look as well as > search the archives here. > > I do have the logger rotating daily right now: > config.logger = Logger.new(config.log_path, 'daily') > > I think I'll remove that and see if this occurs again. The thing that > still bothers me though > is that if one mongrel is broken from this shouldn't they all be? I > can always count on 1 of 4 mongrels > working so that every 3rd request is successful :-) In order to > monitor that I'd have to hit the site twice to > ensure that I'm not just getting the good mongrel on the first hit. > Not very fresh. > > -Michael > http://javathehutt.blogspot.com > > On Jan 2, 2007, at 1:36 PM, Joey Geiger wrote: > >> This may have to do with log rotation. There was a thread about >> similar issue posted in I believe December. You might want to try >> searching the mailing list archives. >> >> You're probably rotating your logs based on a specific size, which is >> why it's happening every couple hours, instead of nightly. >> >> On 1/2/07, Michael Kovacs wrote: >>> Hi all, >>> >>> I've been having problems with the apache 2.2-mod_proxy_balancer- >>> mongrel >>> setup. >>> >>> My setup is: >>> >>> CentOS 4.3 >>> apache 2.2.3 (compiled from source) with mod_proxy_balancer >>> mysql 4.1 >>> ruby 1.8.4 >>> mongrel 0.3.14 (I know I need to update but I think this problem is >>> independent of the mongrel version) >>> mongrel_cluster 0.2.0 >>> rails_machine 0.1.1 >>> >>> I have apache setup as per Coda's configuration on his blog >>> posting from >>> several months back. >>> http://blog.codahale.com/2006/06/19/time-for-a-grown-up-server- >>> rails-mongrel-apache-capistrano-and-you/ >>> >>> I have 4 mongrels in my cluster. >>> >>> Things work fine for periods of time but after several hours of >>> inactivity >>> (I think 8 hours or so) I experience oddness where only 1 of the 4 >>> mongrels >>> is properly >>> responding. I end up getting a "500 internal server error" 3 out >>> of 4 >>> requests as they round robin from mongrel to mongrel. There is >>> nothing in >>> the production >>> log file nor in the mongrel log. I've reproduced this problem on >>> my staging >>> box as well as my production box. >>> >>> The last time I reproduced the problem I decided to run "top" and >>> see what's >>> going on when I hit the server. >>> Mongrel does receive every request but mysql is only active on the >>> 1 request >>> that works. In the other mongrels it never spikes up in CPU usage. >>> >>> Looking at the mysql process list revealed that all of the >>> processes had >>> received the "sleep" command but one of the processes is still >>> working properly. I've played with connection timeouts other than >>> to set the >>> timeout in my application's environment >>> (ActiveRecord::Base.verification_timeout = 14400) as well as the >>> mysql >>> interactive_timeout variable but it seems that all the mongrels >>> should work >>> or they shouldn't. The fact that 1 out of 4 always works is rather >>> puzzling >>> to me. >>> >>> Trying a 'killall -USR1 mongrel_rails" to turn debug on simply >>> killed the 4 >>> threads running mongrel. So now I'm running the cluster in debug >>> mode and am >>> going to just let it sit there for several hours until it happens >>> again and >>> hopefully get some idea of where the breakdown is happening. I >>> still think >>> it has to be a mysql connection timeout but again, the fact that 1 >>> of the 4 >>> always works doesn't lend credence to the timeout theory. >>> >>> Has anyone experienced this phenomenon themselves? >>> >>> Thanks for any tips/pointers and thanks Zed for all your hard work >>> with >>> mongrel. >>> >>> >>> >>> -Michaelhttp://javathehutt.blogspot.com >>> >>> >>> _______________________________________________ >>> Mongrel-users mailing list >>> Mongrel-users at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/mongrel-users >>> >>> >> _______________________________________________ >> Mongrel-users mailing list >> Mongrel-users at rubyforge.org >> http://rubyforge.org/mailman/listinfo/mongrel-users > > _______________________________________________ > Mongrel-users mailing list > Mongrel-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/mongrel-users > -- Ezra Zygmuntowicz -- Lead Rails Evangelist -- ez at engineyard.com -- Engine Yard, Serious Rails Hosting -- (866) 518-YARD (9273) From jgeiger at gmail.com Tue Jan 2 17:56:29 2007 From: jgeiger at gmail.com (Joey Geiger) Date: Tue, 2 Jan 2007 16:56:29 -0600 Subject: [Mongrel] problems with apache 2.2 proxying to mongrel cluster In-Reply-To: <79FAAADD-0FA5-48EA-B23E-F34756C07DA3@gmail.com> References: <0MKoyl-1H1ra12qlX-0005JG@mrelay.perfora.net> <79FAAADD-0FA5-48EA-B23E-F34756C07DA3@gmail.com> Message-ID: <466af3440701021456s7205dacfv6f2116e13c8326f1@mail.gmail.com> Actually won't kill all the mongrels, since one of them will still have control of the log file. It's the ones that can't access the log file that are failing. I'm using logrotate to swap my logs, and also having monit restart each mongrel in turn after the rotation so they pick up the new log file. This may have the consequence of losing some requests on the mongrel side, but everything for me is being logged via apache anyway, so I don't really care. I'd like to try installing SyslogLogger eventually, but for now, my solution is working fine. On 1/2/07, Michael Kovacs wrote: > So you are currently proactively restarting mongrel processes every 30 > minutes? I have yet to setup monit but have every intention of > doing so very soon, but the process of proactively restarting mongrels > regardless of state isn't something I'd relish doing. I don't imagine > that's the common case. At least I hope not. > > > -Michaelhttp://javathehutt.blogspot.com > > > On Jan 2, 2007, at 1:59 PM, Shawn Hill wrote: > > I have the same problem. People (including myself) use monit to ensure > processes don't freeze and some also set up scripts to periodically restart > individual mongrels (mine restart every 30 minutes.) > > My setup: > Linux 2.6.18 > everything else is the same, except I upgraded mongrel (which had no effect > on the problem.) > > Appreciate suggestions from people who have encountered and successfully > resolved this issue. > > > ________________________________ > From: mongrel-users-bounces at rubyforge.org > [mailto:mongrel-users-bounces at rubyforge.org] On Behalf Of > Michael Kovacs > Sent: Tuesday, January 02, 2007 2:10 PM > To: mongrel-users at rubyforge.org > Subject: [Mongrel] problems with apache 2.2 proxying to mongrel cluster > > > Hi all, > > > I've been having problems with the apache 2.2-mod_proxy_balancer-mongrel > setup. > > > My setup is: > > > CentOS 4.3 > apache 2.2.3 (compiled from source) with mod_proxy_balancer > mysql 4.1 > ruby 1.8.4 > mongrel 0.3.14 (I know I need to update but I think this problem is > independent of the mongrel version) > mongrel_cluster 0.2.0 > rails_machine 0.1.1 > > > I have apache setup as per Coda's configuration on his blog posting from > several months back. > http://blog.codahale.com/2006/06/19/time-for-a-grown-up-server-rails-mongrel-apache-capistrano-and-you/ > > > I have 4 mongrels in my cluster. > > > Things work fine for periods of time but after several hours of inactivity > (I think 8 hours or so) I experience oddness where only 1 of the 4 mongrels > is properly > responding. I end up getting a "500 internal server error" 3 out of 4 > requests as they round robin from mongrel to mongrel. There is nothing in > the production > log file nor in the mongrel log. I've reproduced this problem on my staging > box as well as my production box. > > > The last time I reproduced the problem I decided to run "top" and see what's > going on when I hit the server. > Mongrel does receive every request but mysql is only active on the 1 request > that works. In the other mongrels it never spikes up in CPU usage. > > > Looking at the mysql process list revealed that all of the processes had > received the "sleep" command but one of the processes is still > working properly. I've played with connection timeouts other than to set the > timeout in my application's environment > (ActiveRecord::Base.verification_timeout = 14400) as well as the mysql > interactive_timeout variable but it seems that all the mongrels should work > or they shouldn't. The fact that 1 out of 4 always works is rather puzzling > to me. > > > Trying a 'killall -USR1 mongrel_rails" to turn debug on simply killed the 4 > threads running mongrel. So now I'm running the cluster in debug mode and am > going to just let it sit there for several hours until it happens again and > hopefully get some idea of where the breakdown is happening. I still think > it has to be a mysql connection timeout but again, the fact that 1 of the 4 > always works doesn't lend credence to the timeout theory. > > Has anyone experienced this phenomenon themselves? > > > Thanks for any tips/pointers and thanks Zed for all your hard work with > mongrel. > > > > > -Michaelhttp://javathehutt.blogspot.com > > _______________________________________________ > Mongrel-users mailing list > Mongrel-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/mongrel-users > > _______________________________________________ > Mongrel-users mailing list > Mongrel-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/mongrel-users > > From _ at whats-your.name Tue Jan 2 17:49:49 2007 From: _ at whats-your.name (carmen) Date: Tue, 2 Jan 2007 17:49:49 -0500 Subject: [Mongrel] problems with apache 2.2 proxying to mongrel cluster In-Reply-To: <4C751C24-C739-411A-A763-55752BA08FEF@gmail.com> References: <4C751C24-C739-411A-A763-55752BA08FEF@gmail.com> Message-ID: <20070102224949.GA8945@replic.net> speaking of problems with apache 2 proxying to mongrel cluster. does anyone know how to make it not unescape GET URIs before passing them to mongrel? ive done some googling and it looks like its some kind of intractable design issue, i see complaints of it in 2001, 2003, and 2006. but maybe theres a workaround? i already tried 'reescaping' it using mod_rewrite, but they ened up different than before (its crucial that the URI is unmodified in my app - even query strings and # .. guess i should just buy a slicehost and bypass my currant admins reluctance to switch off apache.. From kovacs at gmail.com Tue Jan 2 18:21:50 2007 From: kovacs at gmail.com (Michael Kovacs) Date: Tue, 2 Jan 2007 15:21:50 -0800 Subject: [Mongrel] problems with apache 2.2 proxying to mongrel cluster In-Reply-To: <1907e2ca0701021451n709c5b9u66964fa2a4d13540@mail.gmail.com> References: <4C751C24-C739-411A-A763-55752BA08FEF@gmail.com> <466af3440701021336j767ca23apbe685cb0b7203fc4@mail.gmail.com> <1907e2ca0701021451n709c5b9u66964fa2a4d13540@mail.gmail.com> Message-ID: <84D517AD-92BB-4601-9D51-8E1992D60E7B@gmail.com> So I've used the rotating log with lightty/fcgi and the only issue was that when it would rotate you would lose all further requests because it didn't have a handle to the logfile. So everyday at log rotation time I would restart my fcgi processes so that a new production.log file would be populated and my app would go along its merry way. Apparently I've hit the same thing with mongrel only the processes die with no errors anywhere. I still have to determine this is the cause of my problem but I will be surprised if it's not. -Michael http://javathehutt.blogspot.com On Jan 2, 2007, at 2:51 PM, Michael D'Auria wrote: > I didn't know i could use the Logger class like that, pretty sweet. > > Do people know if rotating the logs via Logger is the issue or just > rotating in general? > > .: Michael :. > > > On 1/2/07, Michael Kovacs wrote: > Hmm... thanks for the suggestion I'll give that a look as well as > search the archives here. > > I do have the logger rotating daily right now: > config.logger = Logger.new(config.log_path, 'daily') > > I think I'll remove that and see if this occurs again. The thing that > still bothers me though > is that if one mongrel is broken from this shouldn't they all be? I > can always count on 1 of 4 mongrels > working so that every 3rd request is successful :-) In order to > monitor that I'd have to hit the site twice to > ensure that I'm not just getting the good mongrel on the first hit. > Not very fresh. > > -Michael > http://javathehutt.blogspot.com > > On Jan 2, 2007, at 1:36 PM, Joey Geiger wrote: > > > This may have to do with log rotation. There was a thread about > > similar issue posted in I believe December. You might want to try > > searching the mailing list archives. > > > > You're probably rotating your logs based on a specific size, > which is > > why it's happening every couple hours, instead of nightly. > > > > On 1/2/07, Michael Kovacs wrote: > >> Hi all, > >> > >> I've been having problems with the apache 2.2-mod_proxy_balancer- > >> mongrel > >> setup. > >> > >> My setup is: > >> > >> CentOS 4.3 > >> apache 2.2.3 (compiled from source) with mod_proxy_balancer > >> mysql 4.1 > >> ruby 1.8.4 > >> mongrel 0.3.14 (I know I need to update but I think this problem is > >> independent of the mongrel version) > >> mongrel_cluster 0.2.0 > >> rails_machine 0.1.1 > >> > >> I have apache setup as per Coda's configuration on his blog > >> posting from > >> several months back. > >> http://blog.codahale.com/2006/06/19/time-for-a-grown-up-server- > >> rails-mongrel-apache-capistrano-and-you/ > >> > >> I have 4 mongrels in my cluster. > >> > >> Things work fine for periods of time but after several hours of > >> inactivity > >> (I think 8 hours or so) I experience oddness where only 1 of the 4 > >> mongrels > >> is properly > >> responding. I end up getting a "500 internal server error" 3 out > of 4 > >> requests as they round robin from mongrel to mongrel. There is > >> nothing in > >> the production > >> log file nor in the mongrel log. I've reproduced this problem on > >> my staging > >> box as well as my production box. > >> > >> The last time I reproduced the problem I decided to run "top" and > >> see what's > >> going on when I hit the server. > >> Mongrel does receive every request but mysql is only active on the > >> 1 request > >> that works. In the other mongrels it never spikes up in CPU usage. > >> > >> Looking at the mysql process list revealed that all of the > >> processes had > >> received the "sleep" command but one of the processes is still > >> working properly. I've played with connection timeouts other than > >> to set the > >> timeout in my application's environment > >> (ActiveRecord::Base.verification_timeout = 14400) as well as the > >> mysql > >> interactive_timeout variable but it seems that all the mongrels > >> should work > >> or they shouldn't. The fact that 1 out of 4 always works is rather > >> puzzling > >> to me. > >> > >> Trying a 'killall -USR1 mongrel_rails" to turn debug on simply > >> killed the 4 > >> threads running mongrel. So now I'm running the cluster in debug > >> mode and am > >> going to just let it sit there for several hours until it happens > >> again and > >> hopefully get some idea of where the breakdown is happening. I > >> still think > >> it has to be a mysql connection timeout but again, the fact that 1 > >> of the 4 > >> always works doesn't lend credence to the timeout theory. > >> > >> Has anyone experienced this phenomenon themselves? > >> > >> Thanks for any tips/pointers and thanks Zed for all your hard work > >> with > >> mongrel. > >> > >> > >> > >> -Michaelhttp://javathehutt.blogspot.com > >> > >> > >> _______________________________________________ > >> Mongrel-users mailing list > >> Mongrel-users at rubyforge.org > >> http://rubyforge.org/mailman/listinfo/mongrel-users > >> > >> > > _______________________________________________ > > Mongrel-users mailing list > > Mongrel-users at rubyforge.org > > http://rubyforge.org/mailman/listinfo/mongrel-users > > _______________________________________________ > Mongrel-users mailing list > Mongrel-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/mongrel-users > > _______________________________________________ > Mongrel-users mailing list > Mongrel-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/mongrel-users -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/mongrel-users/attachments/20070102/12a41c13/attachment-0001.html From me at seebq.com Tue Jan 2 18:27:58 2007 From: me at seebq.com (Charles Brian Quinn) Date: Tue, 2 Jan 2007 18:27:58 -0500 Subject: [Mongrel] my apache 2.2 conf In-Reply-To: References: <1907e2ca0701021041l4cc4a6b9v2830d966013015e7@mail.gmail.com> Message-ID: <3a2de0cd0701021527r69c7eaedw1f546dfc56b45a07@mail.gmail.com> if your mongrel configuration files have the line: address: 127.0.0.1 you will only be able to access them from the local machine, i.e. 127.0.0.1 or localhost -- so http://localhost:3000/ NOT: http://servername.com:3000/ Also, if you're wanting to use a prefix (a directory after the domain, like http://mydomain.com/ror/ then, you need the mongrel prefix line: prefix: ror Check the syntax on the above, but should be right. On 1/2/07, Jim Douglas wrote: > >From: "Michael D'Auria" > >Reply-To: mongrel-users at rubyforge.org > >To: mongrel-users at rubyforge.org > >Subject: Re: [Mongrel] my apache 2.2 conf > >Date: Tue, 2 Jan 2007 13:41:39 -0500 > > > >Mongrel is probably set up to listen on port 3000 for localhost only. > >Shouldn't you be connecting via port 80 instead and let Apache talk to > >Mongrel? http://www.myserver.com > > > >On 1/2/07, Jim Douglas wrote: > >> > >> >From: Steven Lumos > >> >Reply-To: mongrel-users at rubyforge.org > >> >To: mongrel-users at rubyforge.org > >> >Subject: [Mongrel] my apache 2.2 conf > >> >Date: Thu, 21 Dec 2006 11:20:38 -0800 > >> > > >> > > >> >I just finished updating our internal site, which hosts multiple Rails > >> >apps, to Apache 2.2.3. It also has a TWiki rewritten into the root, > >> >ViewVC mounted on /cvs, and /server-status and /server-info. > >> > > >> > > >> > ServerName int.example.com > >> > ServerAlias int > >> > > >> > CustomLog /var/www/logs/int.example.com/access.log combined > >> > ErrorLog /var/www/logs/int.example.com/error.log > >> > > >> > [...] > >> > > >> > ## Application Server > >> > > >> > # APP1 > >> > > >> > BalancerMember http://127.0.0.1:11001 > >> > > >> > > >> > Alias /app1 /production/app1/public > >> > > >> > Allow from .example.com > >> > RewriteEngine on > >> > RewriteRule ^/?$ balancer://app1%{REQUEST_URI} [P,L] > >> > RewriteCond %{REQUEST_FILENAME} !-f > >> > RewriteRule . balancer://app1%{REQUEST_URI} [P,L] > >> > > >> > # End APP1 > >> > > >> > # APP2 > >> > > >> > BalancerMember http://127.0.0.1:11010 > >> > > >> > > >> > Alias /app2 /dev/app2/public > >> > > >> > Allow from .example.com > >> > RewriteEngine on > >> > RewriteRule ^/?$ balancer://app2%{REQUEST_URI} [P,L] > >> > RewriteCond %{REQUEST_FILENAME} !-f > >> > RewriteRule . balancer://app2%{REQUEST_URI} [P,L] > >> > > >> > # End APP2 > >> > > >> > > >> >Then I give mongrel_rails --prefix app and done. Almost too easy. > >> >And it's going to be almost trivial to add more mongrels whenever we > >> >need them and I set up mongrel_cluster. Thanks again Zed and whoever > >> >is responsible for mod_proxy(_balance). > >> > > >> >Steve > >> > > >> >_______________________________________________ > >> >Mongrel-users mailing list > >> >Mongrel-users at rubyforge.org > >> >http://rubyforge.org/mailman/listinfo/mongrel-users > >> > >> > >>I tried this config and can get it working from the server like so, > >> > >>http://www.myserver.com:3000/ > >> > >>...but when I try to access this address from a client machine elsewhere I > >>get a "unable to connect error" > >> > >>any ideas? > >> > >>Jim > >> > >>_________________________________________________________________ > >>Find sales, coupons, and free shipping, all in one place! MSN Shopping > >>Sales & Deals > >>http://shopping.msn.com/content/shp/?ctid=198,ptnrid=176,ptnrdata=200639 > >> > >> > >> > >>_______________________________________________ > >>Mongrel-users mailing list > >>Mongrel-users at rubyforge.org > >>http://rubyforge.org/mailman/listinfo/mongrel-users > >> > >> > > > >_______________________________________________ > >Mongrel-users mailing list > >Mongrel-users at rubyforge.org > >http://rubyforge.org/mailman/listinfo/mongrel-users > > > I have a websirte and want to demo a RoR appin a sub directory. Apache in > front of Mongrel, that's why I want http://www.myserver.com:/ror, but I keep > getting this error, > > Status: 500 Internal Server Error Content-Type: text/html > Application error (Rails) > > So I am getting to it via, > http://www.myserver.com/3000 > > Jim > > _________________________________________________________________ > Type your favorite song. Get a customized station. Try MSN Radio powered > by Pandora. http://radio.msn.com/?icid=T002MSN03A07001 > > > > _______________________________________________ > Mongrel-users mailing list > Mongrel-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/mongrel-users > > -- Charles Brian Quinn self-promotion: www.seebq.com highgroove studios: www.highgroove.com slingshot hosting: www.slingshothosting.com Ruby on Rails Bootcamp at the Big Nerd Ranch Intensive Ruby on Rails Training: http://www.bignerdranch.com/classes/ruby.shtml From kovacs at gmail.com Tue Jan 2 21:04:50 2007 From: kovacs at gmail.com (Michael Kovacs) Date: Tue, 2 Jan 2007 18:04:50 -0800 Subject: [Mongrel] problems with apache 2.2 proxying to mongrel cluster In-Reply-To: <25274268-2C4C-4CD9-9882-E9CF55759036@brainspl.at> References: <4C751C24-C739-411A-A763-55752BA08FEF@gmail.com> <466af3440701021336j767ca23apbe685cb0b7203fc4@mail.gmail.com> <25274268-2C4C-4CD9-9882-E9CF55759036@brainspl.at> Message-ID: <252748EB-AC54-48BE-9A22-21D80A880893@gmail.com> Yep log rolling was the problem. I setup my staging box and reproduced it just fine by rolling the date. Taking out the log roller command from my environment.rb setup worked just fine when I rolled days. -Michael http://javathehutt.blogspot.com On Jan 2, 2007, at 2:55 PM, Ezra Zygmuntowicz wrote: > Hey Michael- > > You should definitely now use the ruby logger to do rotation. That > has caused tons of issues for me and others. Use syslog or logrotate > to rotate the logs as the Logger rotator is borken trust me. > > As for why you are having opne process stay alive and the others > die. I think what causes that is that all four of your mongrels will > try to rotate the logs. And its a free for all. So the one who does > it last 'wins' and stays alive. Or if it is a mysql timeout issue > then what is probably happening is that only one of your mongrels is > getting 'exercised' . By this I mean the load balancer is only > sending requests to one mongrel because there is not enough traffic > to make it drive all four mongrels. This means that the one mongrel > is getting requests which keep its db connection alive. While the > others are not getting requests so their db connectiosn die off. > > I think it's one of these two things. Sop don't use Logger to rotate > logs for starters and see if that fixes it for you. > > Cheers > -Ezra > > On Jan 2, 2007, at 2:32 PM, Michael Kovacs wrote: > >> Hmm... thanks for the suggestion I'll give that a look as well as >> search the archives here. >> >> I do have the logger rotating daily right now: >> config.logger = Logger.new(config.log_path, 'daily') >> >> I think I'll remove that and see if this occurs again. The thing that >> still bothers me though >> is that if one mongrel is broken from this shouldn't they all be? I >> can always count on 1 of 4 mongrels >> working so that every 3rd request is successful :-) In order to >> monitor that I'd have to hit the site twice to >> ensure that I'm not just getting the good mongrel on the first hit. >> Not very fresh. >> >> -Michael >> http://javathehutt.blogspot.com >> >> On Jan 2, 2007, at 1:36 PM, Joey Geiger wrote: >> >>> This may have to do with log rotation. There was a thread about >>> similar issue posted in I believe December. You might want to try >>> searching the mailing list archives. >>> >>> You're probably rotating your logs based on a specific size, >>> which is >>> why it's happening every couple hours, instead of nightly. >>> >>> On 1/2/07, Michael Kovacs wrote: >>>> Hi all, >>>> >>>> I've been having problems with the apache 2.2-mod_proxy_balancer- >>>> mongrel >>>> setup. >>>> >>>> My setup is: >>>> >>>> CentOS 4.3 >>>> apache 2.2.3 (compiled from source) with mod_proxy_balancer >>>> mysql 4.1 >>>> ruby 1.8.4 >>>> mongrel 0.3.14 (I know I need to update but I think this problem is >>>> independent of the mongrel version) >>>> mongrel_cluster 0.2.0 >>>> rails_machine 0.1.1 >>>> >>>> I have apache setup as per Coda's configuration on his blog >>>> posting from >>>> several months back. >>>> http://blog.codahale.com/2006/06/19/time-for-a-grown-up-server- >>>> rails-mongrel-apache-capistrano-and-you/ >>>> >>>> I have 4 mongrels in my cluster. >>>> >>>> Things work fine for periods of time but after several hours of >>>> inactivity >>>> (I think 8 hours or so) I experience oddness where only 1 of the 4 >>>> mongrels >>>> is properly >>>> responding. I end up getting a "500 internal server error" 3 out >>>> of 4 >>>> requests as they round robin from mongrel to mongrel. There is >>>> nothing in >>>> the production >>>> log file nor in the mongrel log. I've reproduced this problem on >>>> my staging >>>> box as well as my production box. >>>> >>>> The last time I reproduced the problem I decided to run "top" and >>>> see what's >>>> going on when I hit the server. >>>> Mongrel does receive every request but mysql is only active on the >>>> 1 request >>>> that works. In the other mongrels it never spikes up in CPU usage. >>>> >>>> Looking at the mysql process list revealed that all of the >>>> processes had >>>> received the "sleep" command but one of the processes is still >>>> working properly. I've played with connection timeouts other than >>>> to set the >>>> timeout in my application's environment >>>> (ActiveRecord::Base.verification_timeout = 14400) as well as the >>>> mysql >>>> interactive_timeout variable but it seems that all the mongrels >>>> should work >>>> or they shouldn't. The fact that 1 out of 4 always works is rather >>>> puzzling >>>> to me. >>>> >>>> Trying a 'killall -USR1 mongrel_rails" to turn debug on simply >>>> killed the 4 >>>> threads running mongrel. So now I'm running the cluster in debug >>>> mode and am >>>> going to just let it sit there for several hours until it happens >>>> again and >>>> hopefully get some idea of where the breakdown is happening. I >>>> still think >>>> it has to be a mysql connection timeout but again, the fact that 1 >>>> of the 4 >>>> always works doesn't lend credence to the timeout theory. >>>> >>>> Has anyone experienced this phenomenon themselves? >>>> >>>> Thanks for any tips/pointers and thanks Zed for all your hard work >>>> with >>>> mongrel. >>>> >>>> >>>> >>>> -Michaelhttp://javathehutt.blogspot.com >>>> >>>> >>>> _______________________________________________ >>>> Mongrel-users mailing list >>>> Mongrel-users at rubyforge.org >>>> http://rubyforge.org/mailman/listinfo/mongrel-users >>>> >>>> >>> _______________________________________________ >>> Mongrel-users mailing list >>> Mongrel-users at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/mongrel-users >> >> _______________________________________________ >> Mongrel-users mailing list >> Mongrel-users at rubyforge.org >> http://rubyforge.org/mailman/listinfo/mongrel-users >> > > -- Ezra Zygmuntowicz > -- Lead Rails Evangelist > -- ez at engineyard.com > -- Engine Yard, Serious Rails Hosting > -- (866) 518-YARD (9273) > > > _______________________________________________ > Mongrel-users mailing list > Mongrel-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/mongrel-users From jdz99 at hotmail.com Wed Jan 3 15:09:59 2007 From: jdz99 at hotmail.com (Jim Douglas) Date: Wed, 03 Jan 2007 20:09:59 +0000 Subject: [Mongrel] Frustrating Error Message-ID: I am followint this article, http://blog.codahale.com/2006/06/19/time-for-a-grown-up-server-rails-mongrel-apache-capistrano-and-you/ ...but I keep getting this error in the log...not sure what to try next... ** Daemonized, any open files are closed. Look at log/mongrel.8000.pid and log/mongrel.log for info. ** Starting Mongrel listening at 127.0.0.1:8000 /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/tcphack.rb:12:in `initialize_without_backlog': Address already in use - bind(2) (Errno::EADDRINUSE) from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/tcphack.rb:12:in `initialize' from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:560:in `new' from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:560:in `initialize' from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/configurator.rb:128:in `new' from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/configurator.rb:128:in `listener' from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:98:in `cloaker_' from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/configurator.rb:51:in `call' from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/configurator.rb:51:in `initialize' from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:83:in `new' from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:83:in `run' from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/command.rb:211:in `run' from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:243 from /usr/bin/mongrel_rails:18:in `load' from /usr/bin/mongrel_rails:18 Thanks, Jim _________________________________________________________________ The MSN Entertainment Guide to Golden Globes is here. Get all the scoop. http://tv.msn.com/tv/globes2007/ From kylekochis at gmail.com Wed Jan 3 15:20:40 2007 From: kylekochis at gmail.com (Kyle Kochis) Date: Wed, 3 Jan 2007 13:20:40 -0700 Subject: [Mongrel] Frustrating Error In-Reply-To: References: Message-ID: <6a7034b0701031220k3f24bcffy2f5a817bed321a9e@mail.gmail.com> Based on the error it looks like you probably have another server running on that port--my guess is mongrel but it could also be something else running there too. Kyle Kochis On 1/3/07, Jim Douglas wrote: > > I am followint this article, > > > http://blog.codahale.com/2006/06/19/time-for-a-grown-up-server-rails-mongrel-apache-capistrano-and-you/ > > > ...but I keep getting this error in the log...not sure what to try next... > > ** Daemonized, any open files are closed. Look at log/mongrel.8000.pid > and > log/mongrel.log for info. > ** Starting Mongrel listening at 127.0.0.1:8000 > /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/tcphack.rb:12:in > `initialize_without_backlog': Address already in use - bind(2) > (Errno::EADDRINUSE) > from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0 > /lib/mongrel/tcphack.rb:12:in > `initialize' > from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:560:in > `new' > from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:560:in > `initialize' > from > /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/configurator.rb:128:in > `new' > from > /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/configurator.rb:128:in > `listener' > from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0 > /bin/mongrel_rails:98:in > `cloaker_' > from > /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/configurator.rb:51:in > `call' > from > /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/configurator.rb:51:in > `initialize' > from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:83:in > `new' > from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:83:in > `run' > from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0 > /lib/mongrel/command.rb:211:in > `run' > from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:243 > from /usr/bin/mongrel_rails:18:in `load' > from /usr/bin/mongrel_rails:18 > > Thanks, > Jim > > _________________________________________________________________ > The MSN Entertainment Guide to Golden Globes is here. Get all the scoop. > http://tv.msn.com/tv/globes2007/ > > _______________________________________________ > Mongrel-users mailing list > Mongrel-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/mongrel-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/mongrel-users/attachments/20070103/e6a705dc/attachment.html From rsanheim at gmail.com Wed Jan 3 15:23:01 2007 From: rsanheim at gmail.com (Rob Sanheim) Date: Wed, 3 Jan 2007 14:23:01 -0600 Subject: [Mongrel] problem with mongrel/apache2.2.3 and subdomain setup In-Reply-To: <3a2de0cd0701021050y56cf7fc1j743a324a32adc5d6@mail.gmail.com> References: <3a2de0cd0701021050y56cf7fc1j743a324a32adc5d6@mail.gmail.com> Message-ID: On 1/2/07, Charles Brian Quinn wrote: > I'd add another: > > > ServerName www.otherdomain.tld > DocumentRoot /www/otherdomain > > > for your main document root, since you're using VirtualHosts. > > and make sure that loads last -- this could mean if you're doing something like: > > Include /etc/rails/*.conf > > in an apache configuration file that you name the files accordingly > (perhaps 00_my_site.conf and 99_default_vhost.conf) > > hope that helps, Thanks, that led me down the right path. I needed the main domain vhost to load first, and I also needed to add NameVirtualHost *:80 to my main config. Now it all works. - Rob From luislavena at gmail.com Wed Jan 3 15:24:38 2007 From: luislavena at gmail.com (Luis Lavena) Date: Wed, 3 Jan 2007 17:24:38 -0300 Subject: [Mongrel] Frustrating Error In-Reply-To: References: Message-ID: <71166b3b0701031224s763a8927h257d72ee55d23641@mail.gmail.com> On 1/3/07, Jim Douglas wrote: > I am followint this article, > > http://blog.codahale.com/2006/06/19/time-for-a-grown-up-server-rails-mongrel-apache-capistrano-and-you/ > > > ...but I keep getting this error in the log...not sure what to try next... > Errno::EADDRINUSE refer to the address+port combination being used by OTHER application (could be another mongrel already daemonized on that port or webrick). you could check using ps: $ sudo ps ax | grep mongrel And if you get more than one grep mongrel process running, that means you must kill them first. > ** Daemonized, any open files are closed. Look at log/mongrel.8000.pid and > log/mongrel.log for info. > ** Starting Mongrel listening at 127.0.0.1:8000 > /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/tcphack.rb:12:in > `initialize_without_backlog': Address already in use - bind(2) > (Errno::EADDRINUSE) > from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/tcphack.rb:12:in > `initialize' > from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:560:in `new' > from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:560:in > `initialize' > from > /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/configurator.rb:128:in > `new' > from > /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/configurator.rb:128:in > `listener' > from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:98:in > `cloaker_' > from > /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/configurator.rb:51:in > `call' > from > /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/configurator.rb:51:in > `initialize' > from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:83:in `new' > from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:83:in `run' > from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/command.rb:211:in > `run' > from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:243 > from /usr/bin/mongrel_rails:18:in `load' > from /usr/bin/mongrel_rails:18 > > Thanks, > Jim > > _________________________________________________________________ > The MSN Entertainment Guide to Golden Globes is here. Get all the scoop. > http://tv.msn.com/tv/globes2007/ > > _______________________________________________ > Mongrel-users mailing list > Mongrel-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/mongrel-users > -- Luis Lavena Multimedia systems - Leaders are made, they are not born. They are made by hard effort, which is the price which all of us must pay to achieve any goal that is worthwhile. Vince Lombardi From michael.dauria at gmail.com Wed Jan 3 16:00:29 2007 From: michael.dauria at gmail.com (Michael D'Auria) Date: Wed, 3 Jan 2007 16:00:29 -0500 Subject: [Mongrel] Frustrating Error In-Reply-To: <6a7034b0701031220k3f24bcffy2f5a817bed321a9e@mail.gmail.com> References: <6a7034b0701031220k3f24bcffy2f5a817bed321a9e@mail.gmail.com> Message-ID: <1907e2ca0701031300r6921bfdfxcccff6caf0bd023f@mail.gmail.com> issue an: "lsof | grep 8000" which lists all open files, which includes all open ports so you can see the process that is causing you grief. Let us know what you find. .: Michael :. On 1/3/07, Kyle Kochis wrote: > > Based on the error it looks like you probably have another server running > on that port--my guess is mongrel but it could also be something else > running there too. > Kyle Kochis > > On 1/3/07, Jim Douglas wrote: > > > > I am followint this article, > > > > http://blog.codahale.com/2006/06/19/time-for-a-grown-up-server-rails-mongrel-apache-capistrano-and-you/ > > > > > > > > ...but I keep getting this error in the log...not sure what to try > > next... > > > > ** Daemonized, any open files are closed. Look at log/mongrel.8000.pid > > and > > log/mongrel.log for info. > > ** Starting Mongrel listening at 127.0.0.1:8000 > > /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/tcphack.rb:12:in > > `initialize_without_backlog': Address already in use - bind(2) > > (Errno::EADDRINUSE) > > from /usr/lib/ruby/gems/1.8/gems/mongrel- 1.0 > > /lib/mongrel/tcphack.rb:12:in > > `initialize' > > from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:560:in > > `new' > > from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0 > > /lib/mongrel.rb:560:in > > `initialize' > > from > > /usr/lib/ruby/gems/1.8/gems/mongrel-1.0 > > /lib/mongrel/configurator.rb:128:in > > `new' > > from > > /usr/lib/ruby/gems/1.8/gems/mongrel-1.0 > > /lib/mongrel/configurator.rb:128:in > > `listener' > > from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0 > > /bin/mongrel_rails:98:in > > `cloaker_' > > from > > /usr/lib/ruby/gems/1.8/gems/mongrel-1.0 > > /lib/mongrel/configurator.rb:51:in > > `call' > > from > > /usr/lib/ruby/gems/1.8/gems/mongrel-1.0 > > /lib/mongrel/configurator.rb:51:in > > `initialize' > > from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:83:in > > `new' > > from /usr/lib/ruby/gems/1.8/gems/mongrel- 1.0/bin/mongrel_rails:83:in > > `run' > > from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0 > > /lib/mongrel/command.rb:211:in > > `run' > > from /usr/lib/ruby/gems/1.8/gems/mongrel-1.0 > > /bin/mongrel_rails:243 > > from /usr/bin/mongrel_rails:18:in `load' > > from /usr/bin/mongrel_rails:18 > > > > Thanks, > > Jim > > > > _________________________________________________________________ > > The MSN Entertainment Guide to Golden Globes is here. Get all the > > scoop. > > http://tv.msn.com/tv/globes2007/ > > > > _______________________________________________ > > Mongrel-users mailing list > > Mongrel-users at rubyforge.org > > http://rubyforge.org/mailman/listinfo/mongrel-users > > > > > _______________________________________________ > Mongrel-users mailing list > Mongrel-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/mongrel-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/mongrel-users/attachments/20070103/b4cf032d/attachment.html From jdz99 at hotmail.com Wed Jan 3 16:23:24 2007 From: jdz99 at hotmail.com (Jim Douglas) Date: Wed, 03 Jan 2007 21:23:24 +0000 Subject: [Mongrel] Frustrating Error In-Reply-To: <71166b3b0701031224s763a8927h257d72ee55d23641@mail.gmail.com> Message-ID: >From: "Luis Lavena" >Reply-To: mongrel-users at rubyforge.org >To: mongrel-users at rubyforge.org >Subject: Re: [Mongrel] Frustrating Error >Date: Wed, 3 Jan 2007 17:24:38 -0300 > >On 1/3/07, Jim Douglas wrote: > > I am followint this article, > > > > >http://blog.codahale.com/2006/06/19/time-for-a-grown-up-server-rails-mongrel-apache-capistrano-and-you/ > > > > > > ...but I keep getting this error in the log...not sure what to try >next... > > > >Errno::EADDRINUSE refer to the address+port combination being used by >OTHER application (could be another mongrel already daemonized on that >port or webrick). > >you could check using ps: > >$ sudo ps ax | grep mongrel > >And if you get more than one grep mongrel process running, that means >you must kill them first. > > > > ** Daemonized, any open files are closed. Look at log/mongrel.8000.pid >and > > log/mongrel.log for info. > > ** Starting Mongrel listening at 127.0.0.1:8000 > > /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/tcphack.rb:12:in > > `initialize_without_backlog': Address already in use - bind(2) > > (Errno::EADDRINUSE) > > from >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/tcphack.rb:12:in > > `initialize' > > from >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:560:in `new' > > from >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:560:in > > `initialize' > > from > > >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/configurator.rb:128:in > > `new' > > from > > >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/configurator.rb:128:in > > `listener' > > from >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:98:in > > `cloaker_' > > from > > >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/configurator.rb:51:in > > `call' > > from > > >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/configurator.rb:51:in > > `initialize' > > from >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:83:in `new' > > from >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:83:in `run' > > from >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/command.rb:211:in > > `run' > > from >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:243 > > from /usr/bin/mongrel_rails:18:in `load' > > from /usr/bin/mongrel_rails:18 > > > > Thanks, > > Jim > > > > _________________________________________________________________ > > The MSN Entertainment Guide to Golden Globes is here. Get all the >scoop. > > http://tv.msn.com/tv/globes2007/ > > > > _______________________________________________ > > Mongrel-users mailing list > > Mongrel-users at rubyforge.org > > http://rubyforge.org/mailman/listinfo/mongrel-users > > > > >-- >Luis Lavena >Multimedia systems >- >Leaders are made, they are not born. They are made by hard effort, >which is the price which all of us must pay to achieve any goal that >is worthwhile. >Vince Lombardi >_______________________________________________ >Mongrel-users mailing list >Mongrel-users at rubyforge.org >http://rubyforge.org/mailman/listinfo/mongrel-users After killing all mongrels and re-starting w/o any errors in the log I cannot browse www.mysite.com:8000, only http://localhost:8000 works on the server.. ...this is my comgrel.yml cwd: /usr/local/apache2/sites/mysite port: "3000" environment: production ---address: 127.0.0.1 pid_file: log/mongrel.pid servers: 3 It seems like mongrel isn't passing off to apache, but why? This is my proxy_cluster.conf, BalancerMember http://127.0.0.1:8000 BalancerMember http://127.0.0.1:8001 BalancerMember http://127.0.0.1:8002 This is my mysite.conf, ServerName www.mysite.com DocumentRoot /usr/local/apache2/sites/mysite ServerAdmin p at yahoo.com ServerAlias mysite.com *.mysite.com Options FollowSymLinks AllowOverride None Order allow,deny Allow from all Include /usr/local/apache2/conf/extra/mongrel.common ErrorLog /usr/local/apache2/logs/mysite_errors_log CustomLog /usr/local/apache2/logs/mysite_log combined Jim _________________________________________________________________ Your Hotmail address already works to sign into Windows Live Messenger! Get it now http://clk.atdmt.com/MSN/go/msnnkwme0020000001msn/direct/01/?href=http://get.live.com/messenger/overview From dave.verwer at shinydevelopment.com Wed Jan 3 16:33:14 2007 From: dave.verwer at shinydevelopment.com (Dave Verwer) Date: Wed, 3 Jan 2007 21:33:14 +0000 Subject: [Mongrel] Frustrating Error In-Reply-To: References: <71166b3b0701031224s763a8927h257d72ee55d23641@mail.gmail.com> Message-ID: Change: port: "3000" to port: "8000" You need to match that up to the ports used in the balancer config On 1/3/07, Jim Douglas wrote: > >From: "Luis Lavena" > >Reply-To: mongrel-users at rubyforge.org > >To: mongrel-users at rubyforge.org > >Subject: Re: [Mongrel] Frustrating Error > >Date: Wed, 3 Jan 2007 17:24:38 -0300 > > > >On 1/3/07, Jim Douglas wrote: > > > I am followint this article, > > > > > > > >http://blog.codahale.com/2006/06/19/time-for-a-grown-up-server-rails-mongrel-apache-capistrano-and-you/ > > > > > > > > > ...but I keep getting this error in the log...not sure what to try > >next... > > > > > > >Errno::EADDRINUSE refer to the address+port combination being used by > >OTHER application (could be another mongrel already daemonized on that > >port or webrick). > > > >you could check using ps: > > > >$ sudo ps ax | grep mongrel > > > >And if you get more than one grep mongrel process running, that means > >you must kill them first. > > > > > > > ** Daemonized, any open files are closed. Look at log/mongrel.8000.pid > >and > > > log/mongrel.log for info. > > > ** Starting Mongrel listening at 127.0.0.1:8000 > > > /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/tcphack.rb:12:in > > > `initialize_without_backlog': Address already in use - bind(2) > > > (Errno::EADDRINUSE) > > > from > >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/tcphack.rb:12:in > > > `initialize' > > > from > >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:560:in `new' > > > from > >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:560:in > > > `initialize' > > > from > > > > >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/configurator.rb:128:in > > > `new' > > > from > > > > >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/configurator.rb:128:in > > > `listener' > > > from > >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:98:in > > > `cloaker_' > > > from > > > > >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/configurator.rb:51:in > > > `call' > > > from > > > > >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/configurator.rb:51:in > > > `initialize' > > > from > >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:83:in `new' > > > from > >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:83:in `run' > > > from > >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/command.rb:211:in > > > `run' > > > from > >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:243 > > > from /usr/bin/mongrel_rails:18:in `load' > > > from /usr/bin/mongrel_rails:18 > > > > > > Thanks, > > > Jim > > > > > > _________________________________________________________________ > > > The MSN Entertainment Guide to Golden Globes is here. Get all the > >scoop. > > > http://tv.msn.com/tv/globes2007/ > > > > > > _______________________________________________ > > > Mongrel-users mailing list > > > Mongrel-users at rubyforge.org > > > http://rubyforge.org/mailman/listinfo/mongrel-users > > > > > > > > >-- > >Luis Lavena > >Multimedia systems > >- > >Leaders are made, they are not born. They are made by hard effort, > >which is the price which all of us must pay to achieve any goal that > >is worthwhile. > >Vince Lombardi > >_______________________________________________ > >Mongrel-users mailing list > >Mongrel-users at rubyforge.org > >http://rubyforge.org/mailman/listinfo/mongrel-users > > > After killing all mongrels and re-starting w/o any errors in the log I > cannot browse www.mysite.com:8000, only http://localhost:8000 works on the > server.. > > ...this is my comgrel.yml > > cwd: /usr/local/apache2/sites/mysite > port: "3000" > environment: production > ---address: 127.0.0.1 > pid_file: log/mongrel.pid > servers: 3 > > It seems like mongrel isn't passing off to apache, but why? > > This is my proxy_cluster.conf, > > BalancerMember http://127.0.0.1:8000 > BalancerMember http://127.0.0.1:8001 > BalancerMember http://127.0.0.1:8002 > > > This is my mysite.conf, > > > ServerName www.mysite.com > > DocumentRoot /usr/local/apache2/sites/mysite > > ServerAdmin p at yahoo.com > ServerAlias mysite.com *.mysite.com > > > Options FollowSymLinks > AllowOverride None > Order allow,deny > Allow from all > > > Include /usr/local/apache2/conf/extra/mongrel.common > > ErrorLog /usr/local/apache2/logs/mysite_errors_log > CustomLog /usr/local/apache2/logs/mysite_log combined > > > > Jim > > _________________________________________________________________ > Your Hotmail address already works to sign into Windows Live Messenger! Get > it now > http://clk.atdmt.com/MSN/go/msnnkwme0020000001msn/direct/01/?href=http://get.live.com/messenger/overview > > _______________________________________________ > Mongrel-users mailing list > Mongrel-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/mongrel-users > From michael.dauria at gmail.com Wed Jan 3 16:38:49 2007 From: michael.dauria at gmail.com (Michael D'Auria) Date: Wed, 3 Jan 2007 16:38:49 -0500 Subject: [Mongrel] Frustrating Error In-Reply-To: References: <71166b3b0701031224s763a8927h257d72ee55d23641@mail.gmail.com> Message-ID: <1907e2ca0701031338g4ad1032aw3a7132a329462cae@mail.gmail.com> Because you have Mongrel set up to create 3 instances from port 3000 not 8000 as your Apache config is suggesting. .: Michael :. On 1/3/07, Jim Douglas wrote: > > >From: "Luis Lavena" > >Reply-To: mongrel-users at rubyforge.org > >To: mongrel-users at rubyforge.org > >Subject: Re: [Mongrel] Frustrating Error > >Date: Wed, 3 Jan 2007 17:24:38 -0300 > > > >On 1/3/07, Jim Douglas wrote: > > > I am followint this article, > > > > > > > > > http://blog.codahale.com/2006/06/19/time-for-a-grown-up-server-rails-mongrel-apache-capistrano-and-you/ > > > > > > > > > ...but I keep getting this error in the log...not sure what to try > >next... > > > > > > >Errno::EADDRINUSE refer to the address+port combination being used by > >OTHER application (could be another mongrel already daemonized on that > >port or webrick). > > > >you could check using ps: > > > >$ sudo ps ax | grep mongrel > > > >And if you get more than one grep mongrel process running, that means > >you must kill them first. > > > > > > > ** Daemonized, any open files are closed. Look at > log/mongrel.8000.pid > >and > > > log/mongrel.log for info. > > > ** Starting Mongrel listening at 127.0.0.1:8000 > > > /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/tcphack.rb:12:in > > > `initialize_without_backlog': Address already in use - bind(2) > > > (Errno::EADDRINUSE) > > > from > >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/tcphack.rb:12:in > > > `initialize' > > > from > >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:560:in `new' > > > from > >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:560:in > > > `initialize' > > > from > > > > >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0 > /lib/mongrel/configurator.rb:128:in > > > `new' > > > from > > > > >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0 > /lib/mongrel/configurator.rb:128:in > > > `listener' > > > from > >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:98:in > > > `cloaker_' > > > from > > > > >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/configurator.rb:51:in > > > `call' > > > from > > > > >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/configurator.rb:51:in > > > `initialize' > > > from > >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:83:in `new' > > > from > >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:83:in `run' > > > from > >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/command.rb:211:in > > > `run' > > > from > >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:243 > > > from /usr/bin/mongrel_rails:18:in `load' > > > from /usr/bin/mongrel_rails:18 > > > > > > Thanks, > > > Jim > > > > > > _________________________________________________________________ > > > The MSN Entertainment Guide to Golden Globes is here. Get all the > >scoop. > > > http://tv.msn.com/tv/globes2007/ > > > > > > _______________________________________________ > > > Mongrel-users mailing list > > > Mongrel-users at rubyforge.org > > > http://rubyforge.org/mailman/listinfo/mongrel-users > > > > > > > > >-- > >Luis Lavena > >Multimedia systems > >- > >Leaders are made, they are not born. They are made by hard effort, > >which is the price which all of us must pay to achieve any goal that > >is worthwhile. > >Vince Lombardi > >_______________________________________________ > >Mongrel-users mailing list > >Mongrel-users at rubyforge.org > >http://rubyforge.org/mailman/listinfo/mongrel-users > > > After killing all mongrels and re-starting w/o any errors in the log I > cannot browse www.mysite.com:8000, only http://localhost:8000 works on the > server.. > > ...this is my comgrel.yml > > cwd: /usr/local/apache2/sites/mysite > port: "3000" > environment: production > ---address: 127.0.0.1 > pid_file: log/mongrel.pid > servers: 3 > > It seems like mongrel isn't passing off to apache, but why? > > This is my proxy_cluster.conf, > > BalancerMember http://127.0.0.1:8000 > BalancerMember http://127.0.0.1:8001 > BalancerMember http://127.0.0.1:8002 > > > This is my mysite.conf, > > > ServerName www.mysite.com > > DocumentRoot /usr/local/apache2/sites/mysite > > ServerAdmin p at yahoo.com > ServerAlias mysite.com *.mysite.com > > > Options FollowSymLinks > AllowOverride None > Order allow,deny > Allow from all > > > Include /usr/local/apache2/conf/extra/mongrel.common > > ErrorLog /usr/local/apache2/logs/mysite_errors_log > CustomLog /usr/local/apache2/logs/mysite_log combined > > > > Jim > > _________________________________________________________________ > Your Hotmail address already works to sign into Windows Live Messenger! > Get > it now > > http://clk.atdmt.com/MSN/go/msnnkwme0020000001msn/direct/01/?href=http://get.live.com/messenger/overview > > _______________________________________________ > Mongrel-users mailing list > Mongrel-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/mongrel-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/mongrel-users/attachments/20070103/3c25e0df/attachment-0001.html From jdz99 at hotmail.com Wed Jan 3 20:19:01 2007 From: jdz99 at hotmail.com (Jim Douglas) Date: Thu, 04 Jan 2007 01:19:01 +0000 Subject: [Mongrel] Frustrating Error In-Reply-To: <1907e2ca0701031338g4ad1032aw3a7132a329462cae@mail.gmail.com> Message-ID: >From: "Michael D'Auria" >Reply-To: mongrel-users at rubyforge.org >To: mongrel-users at rubyforge.org >Subject: Re: [Mongrel] Frustrating Error >Date: Wed, 3 Jan 2007 16:38:49 -0500 > >Because you have Mongrel set up to create 3 instances from port 3000 not >8000 as your Apache config is suggesting. > >.: Michael :. > > >On 1/3/07, Jim Douglas wrote: >> >> >From: "Luis Lavena" >> >Reply-To: mongrel-users at rubyforge.org >> >To: mongrel-users at rubyforge.org >> >Subject: Re: [Mongrel] Frustrating Error >> >Date: Wed, 3 Jan 2007 17:24:38 -0300 >> > >> >On 1/3/07, Jim Douglas wrote: >> > > I am followint this article, >> > > >> > > >> > >>http://blog.codahale.com/2006/06/19/time-for-a-grown-up-server-rails-mongrel-apache-capistrano-and-you/ >> > > >> > > >> > > ...but I keep getting this error in the log...not sure what to try >> >next... >> > > >> > >> >Errno::EADDRINUSE refer to the address+port combination being used by >> >OTHER application (could be another mongrel already daemonized on that >> >port or webrick). >> > >> >you could check using ps: >> > >> >$ sudo ps ax | grep mongrel >> > >> >And if you get more than one grep mongrel process running, that means >> >you must kill them first. >> > >> > >> > > ** Daemonized, any open files are closed. Look at >>log/mongrel.8000.pid >> >and >> > > log/mongrel.log for info. >> > > ** Starting Mongrel listening at 127.0.0.1:8000 >> > > /usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/tcphack.rb:12:in >> > > `initialize_without_backlog': Address already in use - bind(2) >> > > (Errno::EADDRINUSE) >> > > from >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/tcphack.rb:12:in >> > > `initialize' >> > > from >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:560:in `new' >> > > from >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:560:in >> > > `initialize' >> > > from >> > > >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0 >>/lib/mongrel/configurator.rb:128:in >> > > `new' >> > > from >> > > >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0 >>/lib/mongrel/configurator.rb:128:in >> > > `listener' >> > > from >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:98:in >> > > `cloaker_' >> > > from >> > > >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/configurator.rb:51:in >> > > `call' >> > > from >> > > >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/configurator.rb:51:in >> > > `initialize' >> > > from >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:83:in `new' >> > > from >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:83:in `run' >> > > from >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/command.rb:211:in >> > > `run' >> > > from >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:243 >> > > from /usr/bin/mongrel_rails:18:in `load' >> > > from /usr/bin/mongrel_rails:18 >> > > >> > > Thanks, >> > > Jim >> > > >> > > _________________________________________________________________ >> > > The MSN Entertainment Guide to Golden Globes is here. Get all the >> >scoop. >> > > http://tv.msn.com/tv/globes2007/ >> > > >> > > _______________________________________________ >> > > Mongrel-users mailing list >> > > Mongrel-users at rubyforge.org >> > > http://rubyforge.org/mailman/listinfo/mongrel-users >> > > >> > >> > >> >-- >> >Luis Lavena >> >Multimedia systems >> >- >> >Leaders are made, they are not born. They are made by hard effort, >> >which is the price which all of us must pay to achieve any goal that >> >is worthwhile. >> >Vince Lombardi >> >_______________________________________________ >> >Mongrel-users mailing list >> >Mongrel-users at rubyforge.org >> >http://rubyforge.org/mailman/listinfo/mongrel-users >> >> >>After killing all mongrels and re-starting w/o any errors in the log I >>cannot browse www.mysite.com:8000, only http://localhost:8000 works on the >>server.. >> >>...this is my comgrel.yml >> >>cwd: /usr/local/apache2/sites/mysite >>port: "3000" >>environment: production >>---address: 127.0.0.1 >>pid_file: log/mongrel.pid >>servers: 3 >> >>It seems like mongrel isn't passing off to apache, but why? >> >>This is my proxy_cluster.conf, >> >>BalancerMember http://127.0.0.1:8000 >>BalancerMember http://127.0.0.1:8001 >>BalancerMember http://127.0.0.1:8002 >> >> >>This is my mysite.conf, >> >> >>ServerName www.mysite.com >> >>DocumentRoot /usr/local/apache2/sites/mysite >> >>ServerAdmin p at yahoo.com >>ServerAlias mysite.com *.mysite.com >> >> >> Options FollowSymLinks >> AllowOverride None >> Order allow,deny >> Allow from all >> >> >> Include /usr/local/apache2/conf/extra/mongrel.common >> >> ErrorLog /usr/local/apache2/logs/mysite_errors_log >> CustomLog /usr/local/apache2/logs/mysite_log combined >> >> >> >>Jim >> >>_________________________________________________________________ >>Your Hotmail address already works to sign into Windows Live Messenger! >>Get >>it now >> >>http://clk.atdmt.com/MSN/go/msnnkwme0020000001msn/direct/01/?href=http://get.live.com/messenger/overview >> >>_______________________________________________ >>Mongrel-users mailing list >>Mongrel-users at rubyforge.org >>http://rubyforge.org/mailman/listinfo/mongrel-users >> >_______________________________________________ >Mongrel-users mailing list >Mongrel-users at rubyforge.org >http://rubyforge.org/mailman/listinfo/mongrel-users I still have to specify www.mysite.com:8000 to see the RoR app? How can I get it to come up without the "8000"? Thanks, Jim _________________________________________________________________ Dave vs. Carl: The Insignificant Championship Series. ?Who will win? http://clk.atdmt.com/MSN/go/msnnkwsp0070000001msn/direct/01/?href=http://davevscarl.spaces.live.com/?icid=T001MSN38C07001 From luislavena at gmail.com Wed Jan 3 20:35:13 2007 From: luislavena at gmail.com (Luis Lavena) Date: Wed, 3 Jan 2007 22:35:13 -0300 Subject: [Mongrel] Frustrating Error In-Reply-To: References: <1907e2ca0701031338g4ad1032aw3a7132a329462cae@mail.gmail.com> Message-ID: <71166b3b0701031735u64d76827tdebacdc22a8b22e7@mail.gmail.com> On 1/3/07, Jim Douglas wrote: > > I still have to specify www.mysite.com:8000 to see the RoR app? > How can I get it to come up without the "8000"? > You need a traditional webserver in from of mongrel, like apache, lighttpd or nginx. Configuration or more details about this are beyond the purpose of this list (also, escapes my knowledge of *nix systems). I'll suggest you try some guide/howto about getting your webserver running THEN adding mongrel or mongrel_cluster to the equation (baby steps, one step at time). -- Luis Lavena Multimedia systems - Leaders are made, they are not born. They are made by hard effort, which is the price which all of us must pay to achieve any goal that is worthwhile. Vince Lombardi From michael.dauria at gmail.com Wed Jan 3 20:56:18 2007 From: michael.dauria at gmail.com (Michael D'Auria) Date: Wed, 3 Jan 2007 20:56:18 -0500 Subject: [Mongrel] Frustrating Error In-Reply-To: References: <1907e2ca0701031338g4ad1032aw3a7132a329462cae@mail.gmail.com> Message-ID: <1907e2ca0701031756l36b7f74ax1ee2114ef41537ae@mail.gmail.com> > I still have to specify www.mysite.com:8000 to see the RoR app? > How can I get it to come up without the "8000"? > > Thanks, > Jim Something is up with your apache config, i personally don't use Apache, try following this guide: http://mongrel.rubyforge.org/docs/apache.html. Make sure you understand why you are using this configuration, like why are you proxying requests and the like. It's important to understand what you have going on rather than just copying and pasting everything. .: Michael :. On 1/3/07, Jim Douglas wrote: > > >From: "Michael D'Auria" > >Reply-To: mongrel-users at rubyforge.org > >To: mongrel-users at rubyforge.org > >Subject: Re: [Mongrel] Frustrating Error > >Date: Wed, 3 Jan 2007 16:38:49 -0500 > > > >Because you have Mongrel set up to create 3 instances from port 3000 not > >8000 as your Apache config is suggesting. > > > >.: Michael :. > > > > > >On 1/3/07, Jim Douglas wrote: > >> > >> >From: "Luis Lavena" > >> >Reply-To: mongrel-users at rubyforge.org > >> >To: mongrel-users at rubyforge.org > >> >Subject: Re: [Mongrel] Frustrating Error > >> >Date: Wed, 3 Jan 2007 17:24:38 -0300 > >> > > >> >On 1/3/07, Jim Douglas wrote: > >> > > I am followint this article, > >> > > > >> > > > >> > > >> > http://blog.codahale.com/2006/06/19/time-for-a-grown-up-server-rails-mongrel-apache-capistrano-and-you/ > >> > > > >> > > > >> > > ...but I keep getting this error in the log...not sure what to try > >> >next... > >> > > > >> > > >> >Errno::EADDRINUSE refer to the address+port combination being used by > >> >OTHER application (could be another mongrel already daemonized on that > >> >port or webrick). > >> > > >> >you could check using ps: > >> > > >> >$ sudo ps ax | grep mongrel > >> > > >> >And if you get more than one grep mongrel process running, that means > >> >you must kill them first. > >> > > >> > > >> > > ** Daemonized, any open files are closed. Look at > >>log/mongrel.8000.pid > >> >and > >> > > log/mongrel.log for info. > >> > > ** Starting Mongrel listening at 127.0.0.1:8000 > >> > > /usr/lib/ruby/gems/1.8/gems/mongrel-1.0 > /lib/mongrel/tcphack.rb:12:in > >> > > `initialize_without_backlog': Address already in use - bind(2) > >> > > (Errno::EADDRINUSE) > >> > > from > >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/tcphack.rb:12:in > >> > > `initialize' > >> > > from > >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:560:in `new' > >> > > from > >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:560:in > >> > > `initialize' > >> > > from > >> > > > >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0 > >>/lib/mongrel/configurator.rb:128:in > >> > > `new' > >> > > from > >> > > > >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0 > >>/lib/mongrel/configurator.rb:128:in > >> > > `listener' > >> > > from > >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:98:in > >> > > `cloaker_' > >> > > from > >> > > > >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0 > /lib/mongrel/configurator.rb:51:in > >> > > `call' > >> > > from > >> > > > >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0 > /lib/mongrel/configurator.rb:51:in > >> > > `initialize' > >> > > from > >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:83:in `new' > >> > > from > >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:83:in `run' > >> > > from > >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/command.rb:211:in > >> > > `run' > >> > > from > >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:243 > >> > > from /usr/bin/mongrel_rails:18:in `load' > >> > > from /usr/bin/mongrel_rails:18 > >> > > > >> > > Thanks, > >> > > Jim > >> > > > >> > > _________________________________________________________________ > >> > > The MSN Entertainment Guide to Golden Globes is here. Get all the > >> >scoop. > >> > > http://tv.msn.com/tv/globes2007/ > >> > > > >> > > _______________________________________________ > >> > > Mongrel-users mailing list > >> > > Mongrel-users at rubyforge.org > >> > > http://rubyforge.org/mailman/listinfo/mongrel-users > >> > > > >> > > >> > > >> >-- > >> >Luis Lavena > >> >Multimedia systems > >> >- > >> >Leaders are made, they are not born. They are made by hard effort, > >> >which is the price which all of us must pay to achieve any goal that > >> >is worthwhile. > >> >Vince Lombardi > >> >_______________________________________________ > >> >Mongrel-users mailing list > >> >Mongrel-users at rubyforge.org > >> >http://rubyforge.org/mailman/listinfo/mongrel-users > >> > >> > >>After killing all mongrels and re-starting w/o any errors in the log I > >>cannot browse www.mysite.com:8000, only http://localhost:8000 works on > the > >>server.. > >> > >>...this is my comgrel.yml > >> > >>cwd: /usr/local/apache2/sites/mysite > >>port: "3000" > >>environment: production > >>---address: 127.0.0.1 > >>pid_file: log/mongrel.pid > >>servers: 3 > >> > >>It seems like mongrel isn't passing off to apache, but why? > >> > >>This is my proxy_cluster.conf, > >> > >>BalancerMember http://127.0.0.1:8000 > >>BalancerMember http://127.0.0.1:8001 > >>BalancerMember http://127.0.0.1:8002 > >> > >> > >>This is my mysite.conf, > >> > >> > >>ServerName www.mysite.com > >> > >>DocumentRoot /usr/local/apache2/sites/mysite > >> > >>ServerAdmin p at yahoo.com > >>ServerAlias mysite.com *.mysite.com > >> > >> > >> Options FollowSymLinks > >> AllowOverride None > >> Order allow,deny > >> Allow from all > >> > >> > >> Include /usr/local/apache2/conf/extra/mongrel.common > >> > >> ErrorLog /usr/local/apache2/logs/mysite_errors_log > >> CustomLog /usr/local/apache2/logs/mysite_log combined > >> > >> > >> > >>Jim > >> > >>_________________________________________________________________ > >>Your Hotmail address already works to sign into Windows Live Messenger! > >>Get > >>it now > >> > >> > http://clk.atdmt.com/MSN/go/msnnkwme0020000001msn/direct/01/?href=http://get.live.com/messenger/overview > >> > >>_______________________________________________ > >>Mongrel-users mailing list > >>Mongrel-users at rubyforge.org > >>http://rubyforge.org/mailman/listinfo/mongrel-users > >> > > > >_______________________________________________ > >Mongrel-users mailing list > >Mongrel-users at rubyforge.org > >http://rubyforge.org/mailman/listinfo/mongrel-users > > > I still have to specify www.mysite.com:8000 to see the RoR app? > How can I get it to come up without the "8000"? > > Thanks, > Jim > > _________________________________________________________________ > Dave vs. Carl: The Insignificant Championship Series. Who will win? > > http://clk.atdmt.com/MSN/go/msnnkwsp0070000001msn/direct/01/?href=http://davevscarl.spaces.live.com/?icid=T001MSN38C07001 > > > > _______________________________________________ > Mongrel-users mailing list > Mongrel-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/mongrel-users > > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/mongrel-users/attachments/20070103/62f7eef4/attachment-0001.html From joevandyk at gmail.com Thu Jan 4 03:55:41 2007 From: joevandyk at gmail.com (Joe Van Dyk) Date: Thu, 4 Jan 2007 00:55:41 -0800 Subject: [Mongrel] fastthread -- what is it? Message-ID: Hi, A quick search didn't explain what fastthread is, and how it relates to mongrel. Why would I want to install fastthread? Thanks, Joe From technoweenie at gmail.com Thu Jan 4 05:14:37 2007 From: technoweenie at gmail.com (Rick Olson) Date: Thu, 4 Jan 2007 04:14:37 -0600 Subject: [Mongrel] fastthread -- what is it? In-Reply-To: References: Message-ID: <48fe25b0701040214w634b4021wb0a397d77f57ea5@mail.gmail.com> On 1/4/07, Joe Van Dyk wrote: > Hi, > > A quick search didn't explain what fastthread is, and how it relates > to mongrel. Why would I want to install fastthread? > > Thanks, > Joe http://moonbase.rydia.net/mental/blog/programming/fastthread.html (3rd google result for 'ruby fastthread') -- Rick Olson http://weblog.techno-weenie.net http://mephistoblog.com From zedshaw at zedshaw.com Thu Jan 4 10:05:28 2007 From: zedshaw at zedshaw.com (Zed A. Shaw) Date: Thu, 4 Jan 2007 07:05:28 -0800 Subject: [Mongrel] fastthread -- what is it? In-Reply-To: References: Message-ID: <20070104070528.5bee0321.zedshaw@zedshaw.com> On Thu, 4 Jan 2007 00:55:41 -0800 "Joe Van Dyk" wrote: > Hi, > > A quick search didn't explain what fastthread is, and how it relates > to mongrel. Why would I want to install fastthread? Hi Joe, long answer is that ruby has a bug in how the array works and how threads are garbage collected. When the current Ruby thread locking primitives operate on threads, they tend to store idle ones in arrays. As the existing thread locking mechanisms pull the threads off the array they never get garbage collected and that causes a nasty leak. At the time I was testing this, me and Bradley Taylor narrowed the problem down and produced these two scripts: http://pastie.caboo.se/10194 http://pastie.caboo.se/10317 The first one shows the leak by using Mutex (with graph), the second showed proper GC operation by using Sync (with graph). Still wasn't enough because several high profile idiots on ruby-lang tried to claim the test was invalid but couldn't offer a reason why the first script leaked and the second didn't. Later, after much arguing, calling me an idiot, debating the merits of OS memory allocation, and other stupidities, we find out that Eric Mahurin fixed the whole problem a year ago and it was missed: http://blade.nagaokgaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-core/5861 Thankfully, there's smart cool people like mentalguy who can make improvements and provide them as gems. What mentalguy did is re-create all of the Ruby thread locking gear in a C extension called fastthread. With fastthread we can provide a modest speed boost as well as fix the memory leaks Ruby has by just including a gem. He's pushing for it to become the new thread locking api in Ruby, so hopefully he can get it in without much fuss. I'm telling people that you have to use fastthread, but it's still external so if you run into problems or don't see an improvements then you don't have to run it. Mongrel has fastthread as a gem dependency, but it will run it only if it's installed. So, you can install it, try it out, and then remove the gem if it's a problem. And that's the whole story. Enjoy! -- Zed A. Shaw, MUDCRAP-CE Master Black Belt Sifu http://www.zedshaw.com/ http://www.awprofessional.com/title/0321483502 -- The Mongrel Book http://mongrel.rubyforge.org/ http://www.lingr.com/room/3yXhqKbfPy8 -- Come get help. From mi-mongrel at moensolutions.com Thu Jan 4 12:45:32 2007 From: mi-mongrel at moensolutions.com (Michael Moen) Date: Thu, 4 Jan 2007 09:45:32 -0800 Subject: [Mongrel] Recommendation: Stalled Mongrel? Memcache Hates Spaces In-Reply-To: <20070102104124.0b6a36f9.zedshaw@zedshaw.com> References: <20070102104124.0b6a36f9.zedshaw@zedshaw.com> Message-ID: On Jan 2, 2007, at 10:41 AM, Zed A. Shaw wrote: > Since memcache-client doesn't currently escape your keys for you > (not sure if it should actually), you have to do this yourself or > bad super evil things happen. The few people who have made this > change report no more stopped mongrel processes. > > Please try this out and report back to me if it fixes things. Zed- I rolled out a patch on the JibJab cluster yesterday to address this and I haven't had to go after any dogs with a rubber hose since, and beating bad dogs has been a regular task for a while now. I have no idea where spaces or control characters could get into the keys, but I'm not the only monkey banging on a keyboard here so who knows. In case anybody wants a painless way to handle this, I added the following to my overrides: class MemCache protected def make_cache_key(key) key.gsub!(/[^\w:]/, '_') @namespace.nil? ? key.to_s : "#{@namespace}:#{key}" end end From jdz99 at hotmail.com Thu Jan 4 12:47:20 2007 From: jdz99 at hotmail.com (Jim Douglas) Date: Thu, 04 Jan 2007 17:47:20 +0000 Subject: [Mongrel] Frustrating Error In-Reply-To: <1907e2ca0701031756l36b7f74ax1ee2114ef41537ae@mail.gmail.com> Message-ID: >From: "Michael D'Auria" >Reply-To: mongrel-users at rubyforge.org >To: mongrel-users at rubyforge.org >Subject: Re: [Mongrel] Frustrating Error >Date: Wed, 3 Jan:56:18 -0500 > >>I still have to specify www.mysite.com:8000 to see the RoR app? >>How can I get it to come up without the "8000"? >> >>Thanks, >>Jim > > >Something is up with your apache config, i personally don't use Apache, try >following this guide: http://mongrel.rubyforge.org/docs/apache.html. > >Make sure you understand why you are using this configuration, like why are >you proxying requests and the like. It's important to understand what you >have going on rather than just copying and pasting everything. > >.: Michael :. > >On 1/3/07, Jim Douglas wrote: >> >> >From: "Michael D'Auria" >> >Reply-To: mongrel-users at rubyforge.org >> >To: mongrel-users at rubyforge.org >> >Subject: Re: [Mongrel] Frustrating Error >> >Date: Wed, 3 Jan:38:49 -0500 >> > >> >Because you have Mongrel set up to create 3 instances from port 3000 not >> >8000 as your Apache config is suggesting. >> > >> >.: Michael :. >> > >> > >> >On 1/3/07, Jim Douglas wrote: >> >> >> >> >From: "Luis Lavena" >> >> >Reply-To: mongrel-users at rubyforge.org >> >> >To: mongrel-users at rubyforge.org >> >> >Subject: Re: [Mongrel] Frustrating Error >> >> >Date: Wed, 3 Jan:24:38 -0300 >> >> > >> >> >On 1/3/07, Jim Douglas wrote: >> >> > > I am followint this article, >> >> > > >> >> > > >> >> > >> >> >>http://blog.codahale.com/2006/06/19/time-for-a-grown-up-server-rails-mongrel-apache-capistrano-and-you/ >> >> > > >> >> > > >> >> > > ...but I keep getting this error in the log...not sure what to try >> >> >next... >> >> > > >> >> > >> >> >Errno::EADDRINUSE refer to the address+port combination being used by >> >> >OTHER application (could be another mongrel already daemonized on >>that >> >> >port or webrick). >> >> > >> >> >you could check using ps: >> >> > >> >> >$ sudo ps ax | grep mongrel >> >> > >> >> >And if you get more than one grep mongrel process running, that means >> >> >you must kill them first. >> >> > >> >> > >> >> > > ** Daemonized, any open files are closed. Look at >> >>log/mongrel.8000.pid >> >> >and >> >> > > log/mongrel.log for info. >> >> > > ** Starting Mongrel listening at 127.0.0.1:8000 >> >> > > /usr/lib/ruby/gems/1.8/gems/mongrel-1.0 >>/lib/mongrel/tcphack.rb:12:in >> >> > > `initialize_without_backlog': Address already in use - bind(2) >> >> > > (Errno::EADDRINUSE) >> >> > > from >> >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/tcphack.rb:12:in >> >> > > `initialize' >> >> > > from >> >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:560:in `new' >> >> > > from >> >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:560:in >> >> > > `initialize' >> >> > > from >> >> > > >> >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0 >> >>/lib/mongrel/configurator.rb:128:in >> >> > > `new' >> >> > > from >> >> > > >> >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0 >> >>/lib/mongrel/configurator.rb:128:in >> >> > > `listener' >> >> > > from >> >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:98:in >> >> > > `cloaker_' >> >> > > from >> >> > > >> >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0 >>/lib/mongrel/configurator.rb:51:in >> >> > > `call' >> >> > > from >> >> > > >> >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0 >>/lib/mongrel/configurator.rb:51:in >> >> > > `initialize' >> >> > > from >> >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:83:in `new' >> >> > > from >> >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:83:in `run' >> >> > > from >> >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/command.rb:211:in >> >> > > `run' >> >> > > from >> >> >/usr/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:243 >> >> > > from /usr/bin/mongrel_rails:18:in `load' >> >> > > from /usr/bin/mongrel_rails:18 >> >> > > >> >> > > Thanks, >> >> > > Jim >> >> > > >> >> > > _________________________________________________________________ >> >> > > The MSN Entertainment Guide to Golden Globes is here. Get all the >> >> >scoop. >> >> > > http://tv.msn.com/tv/globes2007/ >> >> > > >> >> > > _______________________________________________ >> >> > > Mongrel-users mailing list >> >> > > Mongrel-users at rubyforge.org >> >> > > http://rubyforge.org/mailman/listinfo/mongrel-users >> >> > > >> >> > >> >> > >> >> >-- >> >> >Luis Lavena >> >> >Multimedia systems >> >> >- >> >> >Leaders are made, they are not born. They are made by hard effort, >> >> >which is the price which all of us must pay to achieve any goal that >> >> >is worthwhile. >> >> >Vince Lombardi >> >> >_______________________________________________ >> >> >Mongrel-users mailing list >> >> >Mongrel-users at rubyforge.org >> >> >http://rubyforge.org/mailman/listinfo/mongrel-users >> >> >> >> >> >>After killing all mongrels and re-starting w/o any errors in the log I >> >>cannot browse www.mysite.com:8000, only http://localhost:8000 works on >>the >> >>server.. >> >> >> >>...this is my comgrel.yml >> >> >> >>cwd: /usr/local/apache2/sites/mysite >> >>port: "3000" >> >>environment: production >> >>---address: 127.0.0.1 >> >>pid_file: log/mongrel.pid >> >>servers: 3 >> >> >> >>It seems like mongrel isn't passing off to apache, but why? >> >> >> >>This is my proxy_cluster.conf, >> >> >> >>BalancerMember http://127.0.0.1:8000 >> >>BalancerMember http://127.0.0.1:8001 >> >>BalancerMember http://127.0.0.1:8002 >> >> >> >> >> >>This is my mysite.conf, >> >> >> >> >> >>ServerName www.mysite.com >> >> >> >>DocumentRoot /usr/local/apache2/sites/mysite >> >> >> >>ServerAdmin p at yahoo.com >> >>ServerAlias mysit