Re: [Mongrel] Mongrel service
Yes, still correct. Sent from mobile. On Mar 23, 2011 4:57 AM, "Anita G." wrote: > Luis Lavena wrote in post #943008: > >>> Basically, it seems that there just isn't any way at all of running mongrel >>> as a service with Rails 3. Could you confirm this? >>> >> >> Correct. Noone has worked on fix that. >> -- >> Luis Lavena > > Is this still correct? > > thanks, Anita > > -- > Posted via http://www.ruby-forum.com/. > ___ > Mongrel-users mailing list > Mongrel-users@rubyforge.org > http://rubyforge.org/mailman/listinfo/mongrel-users ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel service
Luis Lavena wrote in post #943008: >> Basically, it seems that there just isn't any way at all of running mongrel >> as a service with Rails 3. Could you confirm this? >> > > Correct. Noone has worked on fix that. > -- > Luis Lavena Is this still correct? thanks, Anita -- Posted via http://www.ruby-forum.com/. ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel service
On Tue, Feb 1, 2011 at 5:35 PM, Edison Ting wrote: > My next questions is instead of creating multiple services, is there an > option to allow one service run multiple ports. Something like creating > a script file trigger all the ports when one service start? > What is the best practice? Thanks!! =) No, right now there isn't. mongrel_service was designed behind that goal, but the code that powers that part is missing. (single mode is the only mode available in the current codebase) -- Luis Lavena AREA 17 - Perfection in design is achieved not when there is nothing more to add, but rather when there is nothing more to take away. Antoine de Saint-Exupéry ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel service
Great, Thanks for confirmation! I've been confused by -d (daemon mode) -N (# of servers) parameter. I guess those won't work in Windows. Some post gives me the impression that pid file exist in windows so I keep trying. My next questions is instead of creating multiple services, is there an option to allow one service run multiple ports. Something like creating a script file trigger all the ports when one service start? What is the best practice? Thanks!! =) -- Posted via http://www.ruby-forum.com/. ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel service
On Tue, Feb 1, 2011 at 4:22 PM, Edison Ting wrote: > My question is are we suppose to see a pid file in windows? > and pid files are not created on Windows. > how are we allow the service to run multiple port like > -p 3000+3 ? > You need to create multiple services at different ports. -- Luis Lavena AREA 17 - Perfection in design is achieved not when there is nothing more to add, but rather when there is nothing more to take away. Antoine de Saint-Exupéry ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel service
My question is are we suppose to see a pid file in windows? and how are we allow the service to run multiple port like -p 3000+3 ? -- Posted via http://www.ruby-forum.com/. ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel service
Here are my notes: Prerequisites: upgrade ruby gems (gem update --system) verify that the currently installed version of mongrel is 1.1.5 or later and if it isn't: uninstall mongrel (gem uninstall mongrel) install mongrel (gem install mongrel) verify that the currently installed version of mongrel_service is 0.4.beta3 or later and if it isn't: uninstall mongrel_service (gem uninstall mongrel_service) install mongrel_service (gem install mongrel_service) use gem list and verify that the mongrel_service installed is 0.4 or later. If it isn't, you need to take these extra steps: uninstall mongrel_service (gem uninstall mongrel_service) install mongrel_service 0.4.beta3 (gem install mongrel_service --pre) verify that the correct mongrel service has been installed by typing mongrel_service at the dos prompt. Which should produce output like: Mongrel Windows Service, version 0.4.beta2 (c) 2006-2010 The Mongrel development team. mongrel_service is not designed to run form commandline, please use mongrel_rails service:: commands to create a win32 service. If the version is less than 0.4.beta2, you need to manually copy the new mongrel_service.exe. On my system, Ruby is installed in C:\Ruby and I would have to copy the file: C:\Ruby\lib\ruby\gems\1.8\gems\mongrel_service-0.4.beta3\resources\mongrel_s ervice.exe to folder: C:\Ruby\bin Finally, navigate to the folder holding the RoR application and invoke these commands to uninstall/install the service: mongrel_rails service::remove -N APALSvc mongrel_rails service::install -N APALSvc -D "AutoPallet/AutoLoader Service" -c "D:/Development/APAL6/APALUI" -e production -p 3035 --log log/mongrel.log Cheers Pete > -Original Message- > From: mongrel-users-boun...@rubyforge.org > [mailto:mongrel-users-boun...@rubyforge.org] On Behalf Of Edison Ting > Sent: Tuesday, 1 February 2011 5:44 p.m. > To: mongrel-users@rubyforge.org > Subject: Re: [Mongrel] Mongrel service > > Hi Luis, > I am trying to set up mongrel service on windows XP using > Rails 2.3.2 and mongrel 1.1.5. > I manage to run my app as windows services but I am unable to > go further with option such as -l, -P, or -C work. > I tried -l and give full log file path but there's no log file. > I tried -P but I don't see a pid file on the folder I specified. > I tried to do -p 4100+3 but unable to have the service run > for port 4100, 4101 and 4102. > I also would like to use -C so that I can use a yml config > file but I did not see any documentation of how to configure it. > I am familiar with mongrel_cluster in linux but I wish I > could get this working on windows machine as well. > I've read some of your post and indeed it helped me to get this far. > Please give me some light? > > -- > Posted via http://www.ruby-forum.com/. > ___ > Mongrel-users mailing list > Mongrel-users@rubyforge.org > http://rubyforge.org/mailman/listinfo/mongrel-users > ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel service
Hi Luis, I am trying to set up mongrel service on windows XP using Rails 2.3.2 and mongrel 1.1.5. I manage to run my app as windows services but I am unable to go further with option such as -l, -P, or -C work. I tried -l and give full log file path but there's no log file. I tried -P but I don't see a pid file on the folder I specified. I tried to do -p 4100+3 but unable to have the service run for port 4100, 4101 and 4102. I also would like to use -C so that I can use a yml config file but I did not see any documentation of how to configure it. I am familiar with mongrel_cluster in linux but I wish I could get this working on windows machine as well. I've read some of your post and indeed it helped me to get this far. Please give me some light? -- Posted via http://www.ruby-forum.com/. ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel service keeps re-starting ruby
You solved my problem ! It was amazing for a php devlopper like me to see the starting ruby service was parsing a yml file I edited one week ago in the redmine application whereas redmine was still working fine yesterday. Anyway thanks a lot for your help Luis, I would not think about searching in my redmine directory the solution. regards. -- Posted via http://www.ruby-forum.com/. ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel service keeps re-starting ruby
On Mon, Dec 13, 2010 at 10:30 AM, Sebastien Perret wrote: > Sorry, I have found many tabulation in this file replaced them with > space caracter but the problem remained. > Can you pastie the file that contains the authentication line I mentioned before? There must be a syntax error there you're not seeing. -- Luis Lavena AREA 17 - Perfection in design is achieved not when there is nothing more to add, but rather when there is nothing more to take away. Antoine de Saint-Exupéry ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel service keeps re-starting ruby
Sorry, I have found many tabulation in this file replaced them with space caracter but the problem remained. -- Posted via http://www.ruby-forum.com/. ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel service keeps re-starting ruby
On Mon, Dec 13, 2010 at 10:20 AM, Sebastien Perret wrote: > I have checked the .yml file. See attached to my post. The error refers > to a comment line. Nothing before the line 74 looks wrong. No tabulation > reached. You attached the ruby file from YAML, but if you look at the reference in the output: `load': syntax error on line 74, col 21: `authentication: : login' You have a YAML file that contains a ": login" that is not a symbol. There should not be spaces for symbols. Please check your yaml files, not the YAML parser. > I have moved the yml file and install again ruby with the installer.exe. > The old yml file and the new one matches, no différence found. Pretty > strange ... This has nothing to do with the YAML parser or Ruby, is one of your configuration files. -- Luis Lavena AREA 17 - Perfection in design is achieved not when there is nothing more to add, but rather when there is nothing more to take away. Antoine de Saint-Exupéry ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel service keeps re-starting ruby
I have checked the .yml file. See attached to my post. The error refers to a comment line. Nothing before the line 74 looks wrong. No tabulation reached. I have moved the yml file and install again ruby with the installer.exe. The old yml file and the new one matches, no différence found. Pretty strange ... Attachments: http://www.ruby-forum.com/attachment/5544/yaml.rb -- Posted via http://www.ruby-forum.com/. ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel service keeps re-starting ruby
On Mon, Dec 13, 2010 at 8:24 AM, Sebastien Perret wrote: > Hi All, > > I have exactly the same problem : mongrel keeps restarting the ruby > process. > I have installed the patch_for_mongrel.rb proposed by Jonathan. I have > ruby 1.8.7 (2010-06-23 patchlevel 299) [i386-mingw32] > My version of Gem is 1.3.7. Here is the result of my command : > > U:\>mongrel_rails start -e production -p 3001 -a 10.0.5.201 -l > "mongrel.log" -P "mongrel.pid" -c "D:/wamp/www/redmine" -t 0 -r "public" > -n 1024 > ** Starting Mongrel listening at 10.0.5.201:3001 > ** Starting Rails with production environment... > D:/wamp/www/redmine/config/../vendor/rails/railties/lib/rails/gem_dependency.rb:119:Warning: > Gem::Dependency#version_requirements is deprecated and will be remo > ved on or after August 2010. Use #requirement > d:/Ruby187/lib/ruby/1.8/yaml.rb:133:in `load': syntax error on line 74, > col 21: ` authentication: : login' (ArgumentError) > from d:/Ruby187/lib/ruby/1.8/yaml.rb:133:in `load' > > Any Idea ? > Yes, please read the exception: "syntax error on line 74, ..." that is reading a YAML file, check there is no tab or incorrect indentation in that file. -- Luis Lavena AREA 17 - Perfection in design is achieved not when there is nothing more to add, but rather when there is nothing more to take away. Antoine de Saint-Exupéry ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel service keeps re-starting ruby
Hi All, I have exactly the same problem : mongrel keeps restarting the ruby process. I have installed the patch_for_mongrel.rb proposed by Jonathan. I have ruby 1.8.7 (2010-06-23 patchlevel 299) [i386-mingw32] My version of Gem is 1.3.7. Here is the result of my command : U:\>mongrel_rails start -e production -p 3001 -a 10.0.5.201 -l "mongrel.log" -P "mongrel.pid" -c "D:/wamp/www/redmine" -t 0 -r "public" -n 1024 ** Starting Mongrel listening at 10.0.5.201:3001 ** Starting Rails with production environment... D:/wamp/www/redmine/config/../vendor/rails/railties/lib/rails/gem_dependency.rb:119:Warning: Gem::Dependency#version_requirements is deprecated and will be remo ved on or after August 2010. Use #requirement d:/Ruby187/lib/ruby/1.8/yaml.rb:133:in `load': syntax error on line 74, col 21: `authentication: : login' (ArgumentError) from d:/Ruby187/lib/ruby/1.8/yaml.rb:133:in `load' from d:/Ruby187/lib/ruby/1.8/yaml.rb:144:in `load_file' from d:/Ruby187/lib/ruby/1.8/yaml.rb:143:in `open' from d:/Ruby187/lib/ruby/1.8/yaml.rb:143:in `load_file' from D:/wamp/www/redmine/config/initializers/40-email.rb:6 from D:/wamp/www/redmine/vendor/rails/activesupport/lib/active_support/dependencies.rb:147:in `load_without_new_constant_marking' from D:/wamp/www/redmine/vendor/rails/activesupport/lib/active_support/dependencies.rb:147:in `load' from D:/wamp/www/redmine/config/../vendor/rails/railties/lib/initializer.rb:622:in `load_application_initializers' from D:/wamp/www/redmine/config/../vendor/rails/railties/lib/initializer.rb:621:in `each' from D:/wamp/www/redmine/config/../vendor/rails/railties/lib/initializer.rb:621:in `load_application_initializers' from D:/wamp/www/redmine/config/../vendor/rails/railties/lib/initializer.rb:176:in `process' from D:/wamp/www/redmine/config/../vendor/rails/railties/lib/initializer.rb:113:in `send' from D:/wamp/www/redmine/config/../vendor/rails/railties/lib/initializer.rb:113:in `run' from D:/wamp/www/redmine/config/environment.rb:20 from d:/Ruby187/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in `gem_original_require' from d:/Ruby187/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in `require' from d:/Ruby187/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mingw32/bin/../lib/mongrel/rails.rb:147:in `rails' from d:/Ruby187/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mingw32/bin/mongrel_rails:113:in `cloaker_' from d:/Ruby187/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mingw32/bin/../lib/mongrel/configurator.rb:149:in `call' from d:/Ruby187/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mingw32/bin/../lib/mongrel/configurator.rb:149:in `listener' from d:/Ruby187/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mingw32/bin/mongrel_rails:99:in `cloaker_' from d:/Ruby187/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mingw32/bin/../lib/mongrel/configurator.rb:50:in `call' from d:/Ruby187/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mingw32/bin/../lib/mongrel/configurator.rb:50:in `initialize' from d:/Ruby187/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mingw32/bin/mongrel_rails:84:in `new' from d:/Ruby187/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mingw32/bin/mongrel_rails:84:in `run' from d:/Ruby187/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mingw32/bin/../lib/mongrel/command.rb:212:in `run' from d:/Ruby187/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mingw32/bin/mongrel_rails:281 from d:/Ruby187/bin/mongrel_rails:19:in `load' from d:/Ruby187/bin/mongrel_rails:19 Any Idea ? -- Posted via http://www.ruby-forum.com/. ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel service
On Wed, Sep 22, 2010 at 11:12 AM, Gerhard Koekemoer wrote: > Hi Luis > > I have now switched over to Ruby 1.8.7 and Mongrel 1.1.5 and Mongrel Service > 0.4.3.beta3 just to make sure these gems are compatible with each other. > > Running the mongrel_rails start command: "mongrel_rails is not recognized as > an internal or external command", is this the error you spoke about? > No. Is Ruby in your PATH? > Basically, it seems that there just isn't any way at all of running mongrel > as a service with Rails 3. Could you confirm this? > Correct. Noone has worked on fix that. -- Luis Lavena AREA 17 - Perfection in design is achieved not when there is nothing more to add, but rather when there is nothing more to take away. Antoine de Saint-Exupéry ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel service
Hi Luis I have now switched over to Ruby 1.8.7 and Mongrel 1.1.5 and Mongrel Service 0.4.3.beta3 just to make sure these gems are compatible with each other. Running the mongrel_rails start command: "mongrel_rails is not recognized as an internal or external command", is this the error you spoke about? Basically, it seems that there just isn't any way at all of running mongrel as a service with Rails 3. Could you confirm this? -Original Message- From: mongrel-users-boun...@rubyforge.org [mailto:mongrel-users-boun...@rubyforge.org] On Behalf Of Gerhard Koekemoer Sent: 22 September 2010 03:36 PM To: mongrel-users@rubyforge.org Subject: Re: [Mongrel] Mongrel service Hi Luis Thanks for the info. The reason that I went for mongrel 1.1.5 is that the mongrel_service 0.4.2.beta3 gem requires it. If I understand you correctly: 1) Because we are runnig ruby 1.9.2 we should run mongrel 1.2.0.pre which does not play nicely with mongrel service (I get an error asking for 1.1.5). 2) The best solution would be to run 1.8.7 with mongrel 1.1.5 and mongrel_service 0.4.3.beta3 Regards, Gerhard -Original Message- From: mongrel-users-boun...@rubyforge.org [mailto:mongrel-users-boun...@rubyforge.org] On Behalf Of Luis Lavena Sent: 22 September 2010 02:51 PM To: mongrel-users@rubyforge.org Subject: Re: [Mongrel] Mongrel service On Wed, Sep 22, 2010 at 9:33 AM, Gerhard Koekemoer wrote: > Hi all > Environment: > > Windows 7 64 bit > Ruby 1.9.2.p0 > Rails 3 > > I am getting the following error when I run the following command > mongrel_rails service::install -N MyTestApp_4001 -p 4001 e production: > > Msvcrt-ruby18.dll is missing > You're attempting to run Ruby 1.9 with a version of mongrel that hasn't been compiled with Ruby 1.9 support. Please install the 1.2.0 prerelease version: gem install mongrel --pre Also note that "mongrel_rails start" will fail with Rails 3. Which means mongrel service will also fail. Before you report that back, see existing issues in relation to Rails 3: http://github.com/fauna/mongrel/issues -- Luis Lavena AREA 17 - Perfection in design is achieved not when there is nothing more to add, but rather when there is nothing more to take away. Antoine de Saint-Exupéry ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel service
Hi Luis Thanks for the info. The reason that I went for mongrel 1.1.5 is that the mongrel_service 0.4.2.beta3 gem requires it. If I understand you correctly: 1) Because we are runnig ruby 1.9.2 we should run mongrel 1.2.0.pre which does not play nicely with mongrel service (I get an error asking for 1.1.5). 2) The best solution would be to run 1.8.7 with mongrel 1.1.5 and mongrel_service 0.4.3.beta3 Regards, Gerhard -Original Message- From: mongrel-users-boun...@rubyforge.org [mailto:mongrel-users-boun...@rubyforge.org] On Behalf Of Luis Lavena Sent: 22 September 2010 02:51 PM To: mongrel-users@rubyforge.org Subject: Re: [Mongrel] Mongrel service On Wed, Sep 22, 2010 at 9:33 AM, Gerhard Koekemoer wrote: > Hi all > Environment: > > Windows 7 64 bit > Ruby 1.9.2.p0 > Rails 3 > > I am getting the following error when I run the following command > mongrel_rails service::install -N MyTestApp_4001 -p 4001 e production: > > Msvcrt-ruby18.dll is missing > You're attempting to run Ruby 1.9 with a version of mongrel that hasn't been compiled with Ruby 1.9 support. Please install the 1.2.0 prerelease version: gem install mongrel --pre Also note that "mongrel_rails start" will fail with Rails 3. Which means mongrel service will also fail. Before you report that back, see existing issues in relation to Rails 3: http://github.com/fauna/mongrel/issues -- Luis Lavena AREA 17 - Perfection in design is achieved not when there is nothing more to add, but rather when there is nothing more to take away. Antoine de Saint-Exupéry ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel service
On Wed, Sep 22, 2010 at 9:33 AM, Gerhard Koekemoer wrote: > Hi all > Environment: > > Windows 7 64 bit > Ruby 1.9.2.p0 > Rails 3 > > I am getting the following error when I run the following command > mongrel_rails service::install -N MyTestApp_4001 -p 4001 –e production: > > “Msvcrt-ruby18.dll is missing” > You're attempting to run Ruby 1.9 with a version of mongrel that hasn't been compiled with Ruby 1.9 support. Please install the 1.2.0 prerelease version: gem install mongrel --pre Also note that "mongrel_rails start" will fail with Rails 3. Which means mongrel service will also fail. Before you report that back, see existing issues in relation to Rails 3: http://github.com/fauna/mongrel/issues -- Luis Lavena AREA 17 - Perfection in design is achieved not when there is nothing more to add, but rather when there is nothing more to take away. Antoine de Saint-Exupéry ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
[Mongrel] Mongrel service
Hi all Environment: Windows 7 64 bit Ruby 1.9.2.p0 Rails 3 I am getting the following error when I run the following command mongrel_rails service::install -N MyTestApp_4001 -p 4001 -e production: "Msvcrt-ruby18.dll is missing" Thanks in advance Gerhard ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel service keeps re-starting ruby
It sure helped me. Thanks, Tiberiu -- Posted via http://www.ruby-forum.com/. ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel service keeps re-starting ruby
Hi Jonathan, Thanks a million, your fix worked like a charm! Everything is ok now. Thanks again for fast and superb response! Mike -Original Message- From: mongrel-users-boun...@rubyforge.org [mailto:mongrel-users-boun...@rubyforge.org] On Behalf Of Jonathan Rochkind Sent: Thursday, June 25, 2009 6:08 PM To: mongrel-users@rubyforge.org Subject: Re: [Mongrel] Mongrel service keeps re-starting ruby Ah, actually reading your stack trace, I see it is indeed the --prefix and modern versions of Rails issue. I still don't know why that consumes all CPU instead of just reporting an error. But mongrel is trying to call a method that no longer exists in RAils 2.3 like you have. (I think it dissappeared in Rails 2.2, but could be wrong, it's definitely gone in Rails 2.3). Try dropping this file in your app's config/initializers directory, to basically restore the method that mongrel is trying to call, as a wrapper for the new way to trigger this functionality. config/initializers/patch_for_mongrel.rb [name of file can be anything] # Fix for mongrel which still doesn't know about Rails 2.2's changes, grr. # We provide a backwards compatible wrapper around the new ActionController::base.relative_url_root, # so it can still be called off of the actually non-existing AbstractRequest class. module ActionController class AbstractRequest < ActionController::Request def self.relative_url_root=(path) ActionController::Base.relative_url_root=(path) end def self.relative_url_root ActionController::Base.relative_url_root end end end Michael Pliskin wrote: > Dear Luis, > > Thanks a lot for replying, I followed your advice and it revealed the > problem: it was the --prefix switch that caused it. When I start it like > E:\RailsApps\3vi>mongrel_rails start -e development -p 3001 -a 127.0.0.1 -l > "e:/RailsApps/3vi/log/1.log" -P "e:/RailsApps/3vi/log/mongrel.pid" -t 0 -r > "public" -n 1024 --prefix "/labelyzer" > I am given a ton of errors: > ** Starting Mongrel listening at 127.0.0.1:3001 > ** Starting Rails with development environment... > ** Mounting Rails at /labelyzer... > D:/Ruby/lib/ruby/gems/1.8/gems/activesupport-2.3.2/lib/active_support/dependencies.rb:440:in > `load_missing_constant': uninitialized constant > ActionController::AbstractRequest (NameError) > from > D:/Ruby/lib/ruby/gems/1.8/gems/activesupport-2.3.2/lib/active_support/dependencies.rb:80:in > `const_missing' > from > D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/../lib/mongrel/rails.rb:151:in > `rails' > from > D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/mongrel_rails:113:in > `cloaker_' > from > D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/../lib/mongrel/configurator.rb:149:in > `call' > from > D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/../lib/mongrel/configurator.rb:149:in > `listener' > from > D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/mongrel_rails:99:in > `cloaker_' > from > D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/../lib/mongrel/configurator.rb:50:in > `call' > from > D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/../lib/mongrel/configurator.rb:50:in > `initialize' > from > D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/mongrel_rails:84:in > `new' > from > D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/mongrel_rails:84:in > `run' > from > D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/../lib/mongrel/command.rb:212:in > `run' > from > D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/mongrel_rails:281 > from D:/Ruby/bin/mongrel_rails:19:in `load' > from D:/Ruby/bin/mongrel_rails:19 > > And if I skip --prefix, it's all fine. Any ideas? > > Thanks in advance, > Mike > > -Original Message- > From: mongrel-users-boun...@rubyforge.org > [mailto:mongrel-users-boun...@rubyforge.org] On Behalf Of Luis Lavena > Sent: Thursday, June 25, 2009 4:20 PM > To: mongrel-users@rubyforge.org > Subject: Re: [Mongrel] Mongrel service keeps re-starting ruby > > On Thu, Jun 25, 2009 at 2:07 AM, Michael Pliskin wrote: > >> Hi all, >> >> >> >> Some disclaimer first: I am a complete newbie in mongrel and this list, so >> please forgive me if I say something weird. I have a problem, I've googled >> for a solution for quite a while and failed so far, so decided to ask here. >>
Re: [Mongrel] Mongrel service keeps re-starting ruby
On Thu, Jun 25, 2009 at 11:04 AM, Jonathan Rochkind wrote: > Are you using Rails 2.2? > The latest version of mongrel available by gem is broken with --prefix and > Rails 2.2. I'd still expect it to simply report an error instead of > consuming all CPU, so that's odd (but I've never developed Rails on Windows > before either). > Is consuming the CPU since mongrel_service is trying to restart the ruby process once it failed. Mea culpa,ruby 1.8.5 used to segfault from time to time and I've implemented that automatic restart at that time to workaround it. Since ruby is raising an error and exiting, mongrel_service is trying to restart it :P > But if you are using Rails 2.2 that could still be it, since I too have > discovered that you can't use --prefix with a Rails 2.2 app, without either > patching mongrel or patching your rails app. (I find patching the Rails app > to be easier and less scary, and can tell you how I've done it if this is > indeed your issue). > > I do think it's a big odd that Rails 2.2 has been out for so long, but > mongrel hasn't released a gem that's compatible with it, or warned people on > the project page that there's a problem, or what have you. Makes me kind of > worried that there aren't very many (any?) people on the mongrel development > team, and one shouldn't count on future versions. > I'm here, but basically being focused on updated One-Click Ruby Installer project, which will make life more easy at least for me on Windows ;-) I think there is time for a 1.1.6 release with fixes for this and other details. -- Luis Lavena AREA 17 - Perfection in design is achieved not when there is nothing more to add, but rather when there is nothing more to take away. Antoine de Saint-Exupéry ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel service keeps re-starting ruby
Ah, actually reading your stack trace, I see it is indeed the --prefix and modern versions of Rails issue. I still don't know why that consumes all CPU instead of just reporting an error. But mongrel is trying to call a method that no longer exists in RAils 2.3 like you have. (I think it dissappeared in Rails 2.2, but could be wrong, it's definitely gone in Rails 2.3). Try dropping this file in your app's config/initializers directory, to basically restore the method that mongrel is trying to call, as a wrapper for the new way to trigger this functionality. config/initializers/patch_for_mongrel.rb [name of file can be anything] # Fix for mongrel which still doesn't know about Rails 2.2's changes, grr. # We provide a backwards compatible wrapper around the new ActionController::base.relative_url_root, # so it can still be called off of the actually non-existing AbstractRequest class. module ActionController class AbstractRequest < ActionController::Request def self.relative_url_root=(path) ActionController::Base.relative_url_root=(path) end def self.relative_url_root ActionController::Base.relative_url_root end end end Michael Pliskin wrote: Dear Luis, Thanks a lot for replying, I followed your advice and it revealed the problem: it was the --prefix switch that caused it. When I start it like E:\RailsApps\3vi>mongrel_rails start -e development -p 3001 -a 127.0.0.1 -l "e:/RailsApps/3vi/log/1.log" -P "e:/RailsApps/3vi/log/mongrel.pid" -t 0 -r "public" -n 1024 --prefix "/labelyzer" I am given a ton of errors: ** Starting Mongrel listening at 127.0.0.1:3001 ** Starting Rails with development environment... ** Mounting Rails at /labelyzer... D:/Ruby/lib/ruby/gems/1.8/gems/activesupport-2.3.2/lib/active_support/dependencies.rb:440:in `load_missing_constant': uninitialized constant ActionController::AbstractRequest (NameError) from D:/Ruby/lib/ruby/gems/1.8/gems/activesupport-2.3.2/lib/active_support/dependencies.rb:80:in `const_missing' from D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/../lib/mongrel/rails.rb:151:in `rails' from D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/mongrel_rails:113:in `cloaker_' from D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/../lib/mongrel/configurator.rb:149:in `call' from D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/../lib/mongrel/configurator.rb:149:in `listener' from D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/mongrel_rails:99:in `cloaker_' from D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/../lib/mongrel/configurator.rb:50:in `call' from D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/../lib/mongrel/configurator.rb:50:in `initialize' from D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/mongrel_rails:84:in `new' from D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/mongrel_rails:84:in `run' from D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/../lib/mongrel/command.rb:212:in `run' from D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/mongrel_rails:281 from D:/Ruby/bin/mongrel_rails:19:in `load' from D:/Ruby/bin/mongrel_rails:19 And if I skip --prefix, it's all fine. Any ideas? Thanks in advance, Mike -Original Message- From: mongrel-users-boun...@rubyforge.org [mailto:mongrel-users-boun...@rubyforge.org] On Behalf Of Luis Lavena Sent: Thursday, June 25, 2009 4:20 PM To: mongrel-users@rubyforge.org Subject: Re: [Mongrel] Mongrel service keeps re-starting ruby On Thu, Jun 25, 2009 at 2:07 AM, Michael Pliskin wrote: Hi all, Some disclaimer first: I am a complete newbie in mongrel and this list, so please forgive me if I say something weird. I have a problem, I've googled for a solution for quite a while and failed so far, so decided to ask here. I am trying to set up my Rails application on Windows according to this manual: http://nlakkakula.wordpress.com/2008/11/24/10-steps-for-deploying-your-ruby-on-rails-application-on-a-windows-server-2008-apache-mongrel-cluster/ . Everything is ok however when I completed all the steps, Apache complains that it cannot contact proxy - meaning there is something wrong with mongrel. I digged further and found mongrel keeping re-starting the ruby process. If I look into a task manager, the picture is like: - A ruby.exe process is started - It eats 100% CPU for 5 seconds - It also eats about 25MB RAM - It dies then And the process repeats forever. It looks like there is some error happening but I don't know any way to capture it. My OS is Win2k Advanced Serv
Re: [Mongrel] Mongrel service keeps re-starting ruby
Are you using Rails 2.2? The latest version of mongrel available by gem is broken with --prefix and Rails 2.2. I'd still expect it to simply report an error instead of consuming all CPU, so that's odd (but I've never developed Rails on Windows before either). But if you are using Rails 2.2 that could still be it, since I too have discovered that you can't use --prefix with a Rails 2.2 app, without either patching mongrel or patching your rails app. (I find patching the Rails app to be easier and less scary, and can tell you how I've done it if this is indeed your issue). I do think it's a big odd that Rails 2.2 has been out for so long, but mongrel hasn't released a gem that's compatible with it, or warned people on the project page that there's a problem, or what have you. Makes me kind of worried that there aren't very many (any?) people on the mongrel development team, and one shouldn't count on future versions. Jonathan Michael Pliskin wrote: Dear Luis, Thanks a lot for replying, I followed your advice and it revealed the problem: it was the --prefix switch that caused it. When I start it like E:\RailsApps\3vi>mongrel_rails start -e development -p 3001 -a 127.0.0.1 -l "e:/RailsApps/3vi/log/1.log" -P "e:/RailsApps/3vi/log/mongrel.pid" -t 0 -r "public" -n 1024 --prefix "/labelyzer" I am given a ton of errors: ** Starting Mongrel listening at 127.0.0.1:3001 ** Starting Rails with development environment... ** Mounting Rails at /labelyzer... D:/Ruby/lib/ruby/gems/1.8/gems/activesupport-2.3.2/lib/active_support/dependencies.rb:440:in `load_missing_constant': uninitialized constant ActionController::AbstractRequest (NameError) from D:/Ruby/lib/ruby/gems/1.8/gems/activesupport-2.3.2/lib/active_support/dependencies.rb:80:in `const_missing' from D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/../lib/mongrel/rails.rb:151:in `rails' from D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/mongrel_rails:113:in `cloaker_' from D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/../lib/mongrel/configurator.rb:149:in `call' from D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/../lib/mongrel/configurator.rb:149:in `listener' from D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/mongrel_rails:99:in `cloaker_' from D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/../lib/mongrel/configurator.rb:50:in `call' from D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/../lib/mongrel/configurator.rb:50:in `initialize' from D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/mongrel_rails:84:in `new' from D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/mongrel_rails:84:in `run' from D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/../lib/mongrel/command.rb:212:in `run' from D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/mongrel_rails:281 from D:/Ruby/bin/mongrel_rails:19:in `load' from D:/Ruby/bin/mongrel_rails:19 And if I skip --prefix, it's all fine. Any ideas? Thanks in advance, Mike -Original Message- From: mongrel-users-boun...@rubyforge.org [mailto:mongrel-users-boun...@rubyforge.org] On Behalf Of Luis Lavena Sent: Thursday, June 25, 2009 4:20 PM To: mongrel-users@rubyforge.org Subject: Re: [Mongrel] Mongrel service keeps re-starting ruby On Thu, Jun 25, 2009 at 2:07 AM, Michael Pliskin wrote: Hi all, Some disclaimer first: I am a complete newbie in mongrel and this list, so please forgive me if I say something weird. I have a problem, I've googled for a solution for quite a while and failed so far, so decided to ask here. I am trying to set up my Rails application on Windows according to this manual: http://nlakkakula.wordpress.com/2008/11/24/10-steps-for-deploying-your-ruby-on-rails-application-on-a-windows-server-2008-apache-mongrel-cluster/ . Everything is ok however when I completed all the steps, Apache complains that it cannot contact proxy - meaning there is something wrong with mongrel. I digged further and found mongrel keeping re-starting the ruby process. If I look into a task manager, the picture is like: - A ruby.exe process is started - It eats 100% CPU for 5 seconds - It also eats about 25MB RAM - It dies then And the process repeats forever. It looks like there is some error happening but I don't know any way to capture it. My OS is Win2k Advanced Server SP4. Any ideas? Thanks, Mike Pliskin That behavior is normal with mongrel_service. has been implemented in a way that the ruby process automatically restart in case of a failure, w
Re: [Mongrel] Mongrel service keeps re-starting ruby
Dear Luis, Thanks a lot for replying, I followed your advice and it revealed the problem: it was the --prefix switch that caused it. When I start it like E:\RailsApps\3vi>mongrel_rails start -e development -p 3001 -a 127.0.0.1 -l "e:/RailsApps/3vi/log/1.log" -P "e:/RailsApps/3vi/log/mongrel.pid" -t 0 -r "public" -n 1024 --prefix "/labelyzer" I am given a ton of errors: ** Starting Mongrel listening at 127.0.0.1:3001 ** Starting Rails with development environment... ** Mounting Rails at /labelyzer... D:/Ruby/lib/ruby/gems/1.8/gems/activesupport-2.3.2/lib/active_support/dependencies.rb:440:in `load_missing_constant': uninitialized constant ActionController::AbstractRequest (NameError) from D:/Ruby/lib/ruby/gems/1.8/gems/activesupport-2.3.2/lib/active_support/dependencies.rb:80:in `const_missing' from D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/../lib/mongrel/rails.rb:151:in `rails' from D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/mongrel_rails:113:in `cloaker_' from D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/../lib/mongrel/configurator.rb:149:in `call' from D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/../lib/mongrel/configurator.rb:149:in `listener' from D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/mongrel_rails:99:in `cloaker_' from D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/../lib/mongrel/configurator.rb:50:in `call' from D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/../lib/mongrel/configurator.rb:50:in `initialize' from D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/mongrel_rails:84:in `new' from D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/mongrel_rails:84:in `run' from D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/../lib/mongrel/command.rb:212:in `run' from D:/Ruby/lib/ruby/gems/1.8/gems/mongrel-1.1.5-x86-mswin32-60/bin/mongrel_rails:281 from D:/Ruby/bin/mongrel_rails:19:in `load' from D:/Ruby/bin/mongrel_rails:19 And if I skip --prefix, it's all fine. Any ideas? Thanks in advance, Mike -Original Message- From: mongrel-users-boun...@rubyforge.org [mailto:mongrel-users-boun...@rubyforge.org] On Behalf Of Luis Lavena Sent: Thursday, June 25, 2009 4:20 PM To: mongrel-users@rubyforge.org Subject: Re: [Mongrel] Mongrel service keeps re-starting ruby On Thu, Jun 25, 2009 at 2:07 AM, Michael Pliskin wrote: > Hi all, > > > > Some disclaimer first: I am a complete newbie in mongrel and this list, so > please forgive me if I say something weird. I have a problem, I've googled > for a solution for quite a while and failed so far, so decided to ask here. > > > > I am trying to set up my Rails application on Windows according to this > manual: > http://nlakkakula.wordpress.com/2008/11/24/10-steps-for-deploying-your-ruby-on-rails-application-on-a-windows-server-2008-apache-mongrel-cluster/ > . Everything is ok however when I completed all the steps, Apache complains > that it cannot contact proxy - meaning there is something wrong with > mongrel. I digged further and found mongrel keeping re-starting the ruby > process. If I look into a task manager, the picture is like: > > - A ruby.exe process is started > > - It eats 100% CPU for 5 seconds > > - It also eats about 25MB RAM > > - It dies then > > And the process repeats forever. It looks like there is some error happening > but I don't know any way to capture it. > > > > My OS is Win2k Advanced Server SP4. Any ideas? > > > > Thanks, > > Mike Pliskin > That behavior is normal with mongrel_service. has been implemented in a way that the ruby process automatically restart in case of a failure, which is seems is happening in the background. To debug this, please start mongrel standalone: cd my_app mongrel_rails start Doing that, you should see, on the console, what is happening. Please paste the results on your reply so I can help you out. Cheers, -- Luis Lavena AREA 17 - Perfection in design is achieved not when there is nothing more to add, but rather when there is nothing more to take away. Antoine de Saint-Exupéry ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel service keeps re-starting ruby
On Thu, Jun 25, 2009 at 2:07 AM, Michael Pliskin wrote: > Hi all, > > > > Some disclaimer first: I am a complete newbie in mongrel and this list, so > please forgive me if I say something weird. I have a problem, I’ve googled > for a solution for quite a while and failed so far, so decided to ask here. > > > > I am trying to set up my Rails application on Windows according to this > manual: > http://nlakkakula.wordpress.com/2008/11/24/10-steps-for-deploying-your-ruby-on-rails-application-on-a-windows-server-2008-apache-mongrel-cluster/ > . Everything is ok however when I completed all the steps, Apache complains > that it cannot contact proxy – meaning there is something wrong with > mongrel. I digged further and found mongrel keeping re-starting the ruby > process. If I look into a task manager, the picture is like: > > - A ruby.exe process is started > > - It eats 100% CPU for 5 seconds > > - It also eats about 25MB RAM > > - It dies then > > And the process repeats forever. It looks like there is some error happening > but I don’t know any way to capture it. > > > > My OS is Win2k Advanced Server SP4. Any ideas? > > > > Thanks, > > Mike Pliskin > That behavior is normal with mongrel_service. has been implemented in a way that the ruby process automatically restart in case of a failure, which is seems is happening in the background. To debug this, please start mongrel standalone: cd my_app mongrel_rails start Doing that, you should see, on the console, what is happening. Please paste the results on your reply so I can help you out. Cheers, -- Luis Lavena AREA 17 - Perfection in design is achieved not when there is nothing more to add, but rather when there is nothing more to take away. Antoine de Saint-Exupéry ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
[Mongrel] Mongrel service keeps re-starting ruby
Hi all, Some disclaimer first: I am a complete newbie in mongrel and this list, so please forgive me if I say something weird. I have a problem, I've googled for a solution for quite a while and failed so far, so decided to ask here. I am trying to set up my Rails application on Windows according to this manual: http://nlakkakula.wordpress.com/2008/11/24/10-steps-for-deploying-your-ruby-on-rails-application-on-a-windows-server-2008-apache-mongrel-cluster/ . Everything is ok however when I completed all the steps, Apache complains that it cannot contact proxy - meaning there is something wrong with mongrel. I digged further and found mongrel keeping re-starting the ruby process. If I look into a task manager, the picture is like: - A ruby.exe process is started - It eats 100% CPU for 5 seconds - It also eats about 25MB RAM - It dies then And the process repeats forever. It looks like there is some error happening but I don't know any way to capture it. My OS is Win2k Advanced Server SP4. Any ideas? Thanks, Mike Pliskin ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] mongrel service security needs on Win2k3
On 6/12/07, Matthew McKnight <[EMAIL PROTECTED]> wrote: > Hello all, > > I have mongrel service 0.3.2 running on Win2003 64-bit, special thanks to > Luis for getting that running. You are a great asset! > Good to know its working ;-) > I am trying to figure out exactly what rights are needed by the account that > is running the service. It works if I give it a domain account with local > admin privileges, but it doesn't work if I give it a domain account without > local admin. I was tracing things and it looked like it was checking for > access to the system32 directory and the ntdll.dll file. I gave the account > modify access to system32, but no dice. No errors in the mongrel_service.log > or servicefb.log. > This is often called LUA Bug [1] > My security guy is wanting me to trace through the code to see what it's > touching, he's not going to let the service account run with local admin > privileges for long. > I will suggest you take a look at the link I just passed as reference ([1]) and also perform some testing with psexec [2] with -l option (privileges stripped mode). do "mongrel_rails start" in the new console window. If everything worked, then perform the same with "mongrel_service" in console mode, which will emulate running as service, perform the same actions, and log everything in expected log files (please, clear them first). I guess I'm starting to repeat my self too often on this topic, so something could be documented and added to DOCs (patches with this are welcome ;-) [3] and [4] are useful threads that contains information about tracking down the problem. > For reference, I can run the thing under srvany.exe without local admin > rights, and it runs just fine. But that solution is unacceptable because it > doesn't kill the processes, making me do my own imitation of mongrel service > and write down the process ids of the processes as they start up, so I know > which service goes with which process when I try to have an orderly > shutdown. I only have about 8 mongrels running on the server, but it's an 8 > core beasty, so I am looking to add more once I get this straight. > mongrel_service isn't doing anything out of usual, even getting information about their "host" process is safer inside Local Service account (not even admin). I know the srvany pain. That's why I created mongrel_service. Orphaned process are like FastCGI ones, which don't seems quite right, even on a Windows environment ;-) Hope this information helps, [1] http://blogs.msdn.com/aaron_margosis/archive/2006/02/06/525455.aspx [2] http://www.microsoft.com/technet/sysinternals/utilities/psexec.mspx [3] http://rubyforge.org/pipermail/mongrel-users/2007-March/003364.html [4] http://rubyforge.org/pipermail/mongrel-users/2007-February/003006.html -- 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@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
[Mongrel] mongrel service security needs on Win2k3
Hello all, I have mongrel service 0.3.2 running on Win2003 64-bit, special thanks to Luis for getting that running. You are a great asset! I am trying to figure out exactly what rights are needed by the account that is running the service. It works if I give it a domain account with local admin privileges, but it doesn't work if I give it a domain account without local admin. I was tracing things and it looked like it was checking for access to the system32 directory and the ntdll.dll file. I gave the account modify access to system32, but no dice. No errors in the mongrel_service.log or servicefb.log. My security guy is wanting me to trace through the code to see what it's touching, he's not going to let the service account run with local admin privileges for long. For reference, I can run the thing under srvany.exe without local admin rights, and it runs just fine. But that solution is unacceptable because it doesn't kill the processes, making me do my own imitation of mongrel service and write down the process ids of the processes as they start up, so I know which service goes with which process when I try to have an orderly shutdown. I only have about 8 mongrels running on the server, but it's an 8 core beasty, so I am looking to add more once I get this straight. -- -Matt McKnight- www.lmnsolutions.com ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel Service won't start on windows
On 3/30/07, Luis Lavena <[EMAIL PROTECTED]> wrote: > > What about mongrel_service.log? > Sorry, asking again and you don't have it :-P -- 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@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel Service won't start on windows
On 3/30/07, Matthew McKnight <[EMAIL PROTECTED]> wrote: > Luis, here's what we're seeing in servicefb.log under c:\ruby\bin > > _initialize() constructor > _initialize() constructor done > ServiceProcess(new_name) > ServiceProcess(new_name) done > ServiceHost() > ServiceHost() done > ServiceHost.Add() > _add_to_references() > _add_to_references() done > ServiceHost.Add() done > ServiceController.RunMode() > CurrentPID: 3400 > ParentPID: 584 > Parent Name: > ServiceController.RunMode() done > ServiceHost() destructor > ServiceHost() destructor done > ServiceProcess() destructor > ServiceProcess() destructor done > _terminate() destructor > _terminate() destructor done > > What about mongrel_service.log? Also, is Ruby executable in your path? It seems that somehow ServiceFB couldn't get parent process name, which could be WinAPI differences between platforms, must confirm this. I'll be rolling a few fixes to mongrel_service in the following hours, please be alert :-) -- 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@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel Service won't start on windows
Luis, here's what we're seeing in servicefb.log under c:\ruby\bin _initialize() constructor _initialize() constructor done ServiceProcess(new_name) ServiceProcess(new_name) done ServiceHost() ServiceHost() done ServiceHost.Add() _add_to_references() _add_to_references() done ServiceHost.Add() done ServiceController.RunMode() CurrentPID: 3400 ParentPID: 584 Parent Name: ServiceController.RunMode() done ServiceHost() destructor ServiceHost() destructor done ServiceProcess() destructor ServiceProcess() destructor done _terminate() destructor _terminate() destructor done On 3/29/07, Luis Lavena <[EMAIL PROTECTED]> wrote: > On 3/30/07, Matthew McKnight <[EMAIL PROTECTED]> wrote: > > Has anyone had much luck with using the srvany.exe approach with > > mongrel? I see some scattered references to it in the archives... > > We've used it for Java processes, but they generally don't stop > > gracefully with srvany. > > Matthew. > > One question I have, also raised in previous mails in this list, where > is your ruby.exe located? > > Please see the bug post here [1] and my previous mail with Kaushik [2] > > srvany is the oposite mongrel_service tries to do: stop gracefully the > service. > > That way is the same like send kill -9 to your process in linux, they > will stop, but nasty things could happen. > > I'll apply the patch provided by David Esposito and pack a release in > the next days with proper handling of logging capabilities. > > [1] > http://rubyforge.org/tracker/index.php?func=detail&aid=8372&group_id=1306&atid=5147 > [2] http://rubyforge.org/pipermail/mongrel-users/2007-March/003370.html > > -- > 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@rubyforge.org > http://rubyforge.org/mailman/listinfo/mongrel-users > -- -Matt McKnight- www.lmnsolutions.com ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel Service won't start on windows
On 3/30/07, Matthew McKnight <[EMAIL PROTECTED]> wrote: > Has anyone had much luck with using the srvany.exe approach with > mongrel? I see some scattered references to it in the archives... > We've used it for Java processes, but they generally don't stop > gracefully with srvany. Matthew. One question I have, also raised in previous mails in this list, where is your ruby.exe located? Please see the bug post here [1] and my previous mail with Kaushik [2] srvany is the oposite mongrel_service tries to do: stop gracefully the service. That way is the same like send kill -9 to your process in linux, they will stop, but nasty things could happen. I'll apply the patch provided by David Esposito and pack a release in the next days with proper handling of logging capabilities. [1] http://rubyforge.org/tracker/index.php?func=detail&aid=8372&group_id=1306&atid=5147 [2] http://rubyforge.org/pipermail/mongrel-users/2007-March/003370.html -- 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@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel Service won't start on windows
Has anyone had much luck with using the srvany.exe approach with mongrel? I see some scattered references to it in the archives... We've used it for Java processes, but they generally don't stop gracefully with srvany. ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel Service won't start on windows
On 3/29/07, Luis Lavena <[EMAIL PROTECTED]> wrote: On 3/29/07, Matthew McKnight <[EMAIL PROTECTED]> wrote: > 64bit Intel 8 CPU server > Windows 2003 Server > Service set to run as LocalSystem, doesn't work as user account either > > The error we see is: > "Service failed to start in a timely..." > Which I have seen in the past email trails as working > In the past? under which configuration? Ruby version, same os, which gems? Ruby is 1.8.5-21 gems rails-1.2.3 gem_plugin-0.2.2 mongrel-1.0.1-mswin32 mongrel_service-0.3.1-mswin32 win32-process-0.5.1 win32-service-0.5.2-mswin32 windows-pr-0.5.3 Everything was working fine on ruby 1.8.4, rails 1.1.6 and the old versions of mongrel and mongrel service. The upgrade process went okay in dev and test. > We upgraded to Mongrel 1.0.1, Mongrel Service 0.3.1 > > It looks like updates to win32-process and win32-service came with the gem > updates for those. Which versions are good to go with > mongrel_service-0.3.1-mswin32? > Only needed by mongrel_service is win32-service (latest guess is 0.5.2). Okay, I was persuing the archives and there seemed to be a lot of back and forth about various versions of that gem. Is there a best version to use? Is the mswin32 version good? First, start a debug session with psexec [1] with lowered privileges as current user: psexec -l cmd.exe In this new console, chdir to c:\rails_app\appname and start mongrel with: mongrel_rails start -e production -p 3000 Check the info it dumps to the screen. If it worked, then is not a LUA bug but something else. Also will be useful the servicefb.log and mongrel_service.log files located in your ruby\bin folder. I am not getting the mongrel_service.log- maybe it's not getting that far. It dies extremely quickly. I'll dump servicegb.log when my sysadmin gets me back on the server. Thanks so much for the assistance, going to try the advanced debug stuff, now, will report back. Matt ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel Service won't start on windows
On 3/29/07, Luis Lavena <[EMAIL PROTECTED]> wrote: On 3/29/07, Matthew McKnight <[EMAIL PROTECTED]> wrote: > Forgot to mention it was working swell before upgrade to install of > 1.8.5-21 which cleaned out my gems and then gem install of latest > Mongrel/Mongrel Service. Which version of rails was you using? were on 1.1.6, now on 1.2.3 > Are these pulling the right win32-service gem? > win32-service gem is only used for installing - removing the service. Will be safer if you remove previous version of mongrel_service since mongrel_service.exe could clash with mongrel_service script, both located in ruby\bin folder. We did a fresh install of 1.85-21, so the old stuff is archived in our backups. Will also be good to know if you're running a 32bits or x64 bits version of Windows, since WinAPI shown some issues between platforms. This is the 64bit OS, we've been running on it fine for about 6 months with the older versions of stuff. Thanks again for the help... ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel Service won't start on windows
On 3/29/07, Matthew McKnight <[EMAIL PROTECTED]> wrote: > Forgot to mention it was working swell before upgrade to install of > 1.8.5-21 which cleaned out my gems and then gem install of latest > Mongrel/Mongrel Service. Which version of rails was you using? > > Are these pulling the right win32-service gem? > win32-service gem is only used for installing - removing the service. Will be safer if you remove previous version of mongrel_service since mongrel_service.exe could clash with mongrel_service script, both located in ruby\bin folder. > Would love for there to be a good way to get back > I know how you feel. Will also be good to know if you're running a 32bits or x64 bits version of Windows, since WinAPI shown some issues between platforms. -- 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@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel Service won't start on windows
On 3/29/07, Matthew McKnight <[EMAIL PROTECTED]> wrote: > 64bit Intel 8 CPU server > Windows 2003 Server > Service set to run as LocalSystem, doesn't work as user account either > > The error we see is: > "Service failed to start in a timely..." > Which I have seen in the past email trails as working > In the past? under which configuration? Ruby version, same os, which gems? > The app works from mongrel_rails start and from mongrel_service console -N > servicename -p 3000 -c c:\rails_apps\appname -e production > the actual command line should be: mongrel_service console -c C:\rails_apps\appname -e production -p 3000 No service name parameters is needed. > We upgraded to Mongrel 1.0.1, Mongrel Service 0.3.1 > > It looks like updates to win32-process and win32-service came with the gem > updates for those. Which versions are good to go with > mongrel_service-0.3.1-mswin32? > Only needed by mongrel_service is win32-service (latest guess is 0.5.2). > This is working on our test and development servers, which are both VMWare > sessions. > > I currently have a pack of mongrels running in command line windows under > our sysadmin's user account- any ideas what to do? > First, start a debug session with psexec [1] with lowered privileges as current user: psexec -l cmd.exe In this new console, chdir to c:\rails_app\appname and start mongrel with: mongrel_rails start -e production -p 3000 Check the info it dumps to the screen. If it worked, then is not a LUA bug but something else. Also will be useful the servicefb.log and mongrel_service.log files located in your ruby\bin folder. [1] http://www.microsoft.com/technet/sysinternals/utilities/psexec.mspx -- 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@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel Service won't start on windows
Forgot to mention it was working swell before upgrade to install of 1.8.5-21 which cleaned out my gems and then gem install of latest Mongrel/Mongrel Service. Are these pulling the right win32-service gem? Would love for there to be a good way to get back - 64bit Intel 8 CPU server Windows 2003 Server Service set to run as LocalSystem, doesn't work as user account either The error we see is: "Service failed to start in a timely..." Which I have seen in the past email trails as working The app works from mongrel_rails start and from mongrel_service console -N servicename -p 3000 -c c:\rails_apps\appname -e production We upgraded to Mongrel 1.0.1, Mongrel Service 0.3.1 It looks like updates to win32-process and win32-service came with the gem updates for those. Which versions are good to go with mongrel_service- 0.3.1-mswin32? This is working on our test and development servers, which are both VMWare sessions. I currently have a pack of mongrels running in command line windows under our sysadmin's user account- any ideas what to do? -- -Matt McKnight- www.lmnsolutions.com ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
[Mongrel] Mongrel Service won't start on windows
64bit Intel 8 CPU server Windows 2003 Server Service set to run as LocalSystem, doesn't work as user account either The error we see is: "Service failed to start in a timely..." Which I have seen in the past email trails as working The app works from mongrel_rails start and from mongrel_service console -N servicename -p 3000 -c c:\rails_apps\appname -e production We upgraded to Mongrel 1.0.1, Mongrel Service 0.3.1 It looks like updates to win32-process and win32-service came with the gem updates for those. Which versions are good to go with mongrel_service- 0.3.1-mswin32? This is working on our test and development servers, which are both VMWare sessions. I currently have a pack of mongrels running in command line windows under our sysadmin's user account- any ideas what to do? -- -Matt McKnight- www.lmnsolutions.com ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel service will not start on win32 w/ --prefix option
Updating the mongrel gem ($ gem update mongrel --include-dependencies) did the trick. Thanks again for your help. I definitely owe you a drink! -BR :) On 2/6/07, Luis Lavena <[EMAIL PROTECTED]> wrote: On 2/6/07, Guy Ridout <[EMAIL PROTECTED]> wrote: > Luis, I truly appreciate the quick reply and your eagerness to help. It's > refreshing to have software w/ service! Thank you. > > I tried running the command you suggest: > > C:\projects\rails-prod\wingate>ruby.exe c:\ruby\bin\mongrel_rails start -e > production -p 4001 -a 0.0.0.0 -l log/mongrel.log -P log/mongrel.pid -c c > :/projects/rails-prod/wingate -t 0 -r public -n 1024 --prefix /wingate > INVALID COMMAND: invalid option: --prefix > > It fails saying there is no --prefix option. Thinking maybe I don't have the > latest version, I did the following: > > C:\projects\rails-prod\wingate>gem update mongrel_service > Updating installed gems... > Need to update 23 gems from http://gems.rubyforge.org > ... > complete > Attempting remote update of mongrel_service > Select which gem to install for your platform (i386-mswin32) > 1. mongrel_service 0.3.1 (mswin32) > 2. mongrel_service 0.1 (ruby) > 3. Cancel installation > > 1 > Successfully installed mongrel_service-0.3.1-mswin32 > Installing ri documentation for mongrel_service-0.3.1-mswin32.. . > Installing RDoc documentation for mongrel_service-0.3.1-mswin32... > Gems: [mongrel_service] updated > > Following this update, the command fails with the same message. Any ideas? > Mmm, did you update mongrel gem too? $ gem install mongrel --include-dependencies Mongrel version should be 1.0.1 You should notice the "Mounting Rails at ..." line in the output: >mongrel_rails start --prefix /test ** Starting Mongrel listening at 0.0.0.0:3000 ** Starting Rails with development environment... ** Mounting Rails at /test... D:0:Warning: require_gem is obsolete. Use gem instead. ** Rails loaded. ** Loading any Rails specific GemPlugins ** Signals ready. INT => stop (no restart). ** Mongrel available at 0.0.0.0:3000 ** Use CTRL-C to stop. I tried the same here and it worked, maybe you have an older mongrel version. > Btw, I apologize if this post breaks the original thread. I'm a mailing list > newbie, and I didn't have my email settings correct, so there is nothing I > can reply to (assuming that is what I'm supposed to do!). > Its good that you bring this to mongrel list, we all started as newbies ;-) try replying to the last mail you get in the same thread (ex, mine, no mater it the Topic get modified with 're:' by your mail software). -- 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@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel service will not start on win32 w/ --prefix option
On 2/6/07, Guy Ridout <[EMAIL PROTECTED]> wrote: > Luis, I truly appreciate the quick reply and your eagerness to help. It's > refreshing to have software w/ service! Thank you. > > I tried running the command you suggest: > > C:\projects\rails-prod\wingate>ruby.exe c:\ruby\bin\mongrel_rails start -e > production -p 4001 -a 0.0.0.0 -l log/mongrel.log -P log/mongrel.pid -c c > :/projects/rails-prod/wingate -t 0 -r public -n 1024 --prefix /wingate > INVALID COMMAND: invalid option: --prefix > > It fails saying there is no --prefix option. Thinking maybe I don't have the > latest version, I did the following: > > C:\projects\rails-prod\wingate>gem update mongrel_service > Updating installed gems... > Need to update 23 gems from http://gems.rubyforge.org > ... > complete > Attempting remote update of mongrel_service > Select which gem to install for your platform (i386-mswin32) > 1. mongrel_service 0.3.1 (mswin32) > 2. mongrel_service 0.1 (ruby) > 3. Cancel installation > > 1 > Successfully installed mongrel_service-0.3.1-mswin32 > Installing ri documentation for mongrel_service-0.3.1-mswin32.. . > Installing RDoc documentation for mongrel_service-0.3.1-mswin32... > Gems: [mongrel_service] updated > > Following this update, the command fails with the same message. Any ideas? > Mmm, did you update mongrel gem too? $ gem install mongrel --include-dependencies Mongrel version should be 1.0.1 You should notice the "Mounting Rails at ..." line in the output: >mongrel_rails start --prefix /test ** Starting Mongrel listening at 0.0.0.0:3000 ** Starting Rails with development environment... ** Mounting Rails at /test... D:0:Warning: require_gem is obsolete. Use gem instead. ** Rails loaded. ** Loading any Rails specific GemPlugins ** Signals ready. INT => stop (no restart). ** Mongrel available at 0.0.0.0:3000 ** Use CTRL-C to stop. I tried the same here and it worked, maybe you have an older mongrel version. > Btw, I apologize if this post breaks the original thread. I'm a mailing list > newbie, and I didn't have my email settings correct, so there is nothing I > can reply to (assuming that is what I'm supposed to do!). > Its good that you bring this to mongrel list, we all started as newbies ;-) try replying to the last mail you get in the same thread (ex, mine, no mater it the Topic get modified with 're:' by your mail software). -- 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@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
[Mongrel] Mongrel service will not start on win32 w/ --prefix option
Luis, I truly appreciate the quick reply and your eagerness to help. It's refreshing to have software w/ service! Thank you. I tried running the command you suggest: C:\projects\rails-prod\wingate>ruby.exe c:\ruby\bin\mongrel_rails start -e production -p 4001 -a 0.0.0.0 -l log/mongrel.log -P log/mongrel.pid -c c :/projects/rails-prod/wingate -t 0 -r public -n 1024 --prefix /wingate INVALID COMMAND: invalid option: --prefix It fails saying there is no --prefix option. Thinking maybe I don't have the latest version, I did the following: C:\projects\rails-prod\wingate>gem update mongrel_service Updating installed gems... Need to update 23 gems from http://gems.rubyforge.org ... complete Attempting remote update of mongrel_service Select which gem to install for your platform (i386-mswin32) 1. mongrel_service 0.3.1 (mswin32) 2. mongrel_service 0.1 (ruby) 3. Cancel installation 1 Successfully installed mongrel_service-0.3.1-mswin32 Installing ri documentation for mongrel_service-0.3.1-mswin32... Installing RDoc documentation for mongrel_service-0.3.1-mswin32... Gems: [mongrel_service] updated Following this update, the command fails with the same message. Any ideas? Btw, I apologize if this post breaks the original thread. I'm a mailing list newbie, and I didn't have my email settings correct, so there is nothing I can reply to (assuming that is what I'm supposed to do!). -BR ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel service will not start on win32 w/ --prefix option
Hello Guy, I'll try to answer your questions: On 2/6/07, Guy Ridout <[EMAIL PROTECTED]> wrote: > All, I am in need of some help. I've run into a problem that I am not able > to fix or even troubleshoot. I am trying to run Mongrel as a service on > Win32. > > Basically, my problem is that running Mongrel as a service works fine. Fine > until I change the configuration (using service::remove and > service::install) to use --prefix. I must have this as I am running multiple > webapps and app servers all behind apache. > I see that you're using latest mongrel_service, that's good. I'll snip the content now, but so far, this is the best report of a problem someone made under Win32! Congrats! > > So, here is the config that works. It does not use the --prefix option: > #1 (works) > mongrel_rails service::install -N mongrel_app_service -c > c:\projects\rails-prod\myapp -p 4001 -e production > > (The service "path to executable" displayed under properties:) > "c:/ruby/bin/mongrel_service.exe" single -e production -p > 4001 -a 0.0.0.0 -l "log/mongrel.log" -P "log/mongrel.pid" -c > "c:/projects/rails-prod/myapp" -t 0 -r "public" -n 1024 > > > > Here is the config that is not working It *does* use the --prefix option. > That is the only difference: > #2 (does not work) > mongrel_rails service::install -N mongrel_app_service -c > c:\projects\rails-prod\myapp -p 4001 -e production --prefix /myapproot > > (The service "path to executable" displayed under properties:) > "c:/ruby/bin/mongrel_service.exe" single -e production -p > 4001 -a 0.0.0.0 -l "log/mongrel.log" -P "log/mongrel .pid" -c > "c:/projects/rails-prod/myapp" -t 0 -r "public" -n 1024 --prefix > "/myapproot" > > As you can see, the only params that fails (based on mongrel_service.log) is --prefix. > ## This is where they start to diverge! > (#1) wait_code: 258 > (#2) wait_code: 0 > (#2) native/process.bas:147, fb.process.spawn: > (#2) failed, the process terminate earlier. > (#2) native/process.bas:156, fb.process.spawn: > (#2) Spawn() done > (#2) native/mongrel_service.bas:88, mongrel_service.single_oninit: > (#2) single_onInit() done > > Can anyone shed any light on the wait_code bit? Is it not waiting long > enough or is that jsut a return code? I've re-booted, cleared my logs, > created user accounts, treid passing --prefix as a start parm in the > properties view of the service. Nothing seems to work. I would really > appreciate some advice. > The wait code indicates that process is starting, and wait_code = 0 means something is wrong during process spawning. My advice will be try running plain mongrel command and see what ruby process dump to the screen, so the command you can run in a command prompt window (cmd) will be: ruby.exe c:\ruby\bin\mongrel_rails start -e production -p 4001 -a 0.0.0.0 -l log/mongrel.log -P log/mongrel.pid -c c:/projects/rails-prod/wingate -t 0 -r public -n 1024 --prefix /wingate The bad thing is in the current implementation, mongrel_service isn't logging the console output of the child process, so this is the only way to pin-point the problem. Please copy the output you get from this in your next reply. So far, mongrel process is failing to start, guess is directly related to prefix option, and if thats the case, a prefix test under win32 should be added. Regards, -- 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@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
[Mongrel] Mongrel service will not start on win32 w/ --prefix option
All, I am in need of some help. I've run into a problem that I am not able to fix or even troubleshoot. I am trying to run Mongrel as a service on Win32. Basically, my problem is that running Mongrel as a service works fine. Fine until I change the configuration (using service::remove and service::install) to use --prefix. I must have this as I am running multiple webapps and app servers all behind apache. So, here is the config that works. It does not use the --prefix option: #1 (works) mongrel_rails service::install -N mongrel_app_service -c c:\projects\rails-prod\myapp -p 4001 -e production (The service "path to executable" displayed under properties:) "c:/ruby/bin/mongrel_service.exe" single -e production -p 4001 -a 0.0.0.0-l "log/mongrel.log" -P "log/mongrel.pid" -c "c:/projects/rails-prod/myapp" -t 0 -r "public" -n 1024 Here is the config that is not working It *does* use the --prefix option. That is the only difference: #2 (does not work) mongrel_rails service::install -N mongrel_app_service -c c:\projects\rails-prod\myapp -p 4001 -e production --prefix /myapproot (The service "path to executable" displayed under properties:) "c:/ruby/bin/mongrel_service.exe" single -e production -p 4001 -a 0.0.0.0-l "log/mongrel.log" -P "log/mongrel .pid" -c "c:/projects/rails-prod/myapp" -t 0 -r "public" -n 1024 --prefix "/myapproot" The working version (#1) starts normally and serves requests as expected. When I start the --prefix version of the service (#2), Windows displays a dialog with the following: "The mongrel_app_service service on Local Computer started and then stopped. Some services stop automatically if they have no work to do, for example, the Performance Logs and Alerts service." I have researched this error and found vague references ( http://rubyforge.org/pipermail/mongrel-users/2006-December/002513.html) that running the service as another user, or clearing the "app logs" may resolve this. I have not had any luck. I tried creating a dedicated user account, but I get the same error. I am not sure what logs I would clear, but I tried my rails/mongrel logs with no luck. My biggest lead is the mongrel_service.log file which I think hints at the root issue. I have captured the logging from a start of both the working service config (#1) and the non-working config (#2). They are listed below intact (all of #1, then all of #2), and then interleaved for easier comparison (up until they diverge): *** Good start (no prefix) ***native/mongrel_service.bas:120, mongrel_service.single_onstop: (#1) # Logfile created on 05/02/2007 23:37:42 (#1) native/mongrel_service.bas:148, mongrel_service.application: (#1)ServiceHost RunAsService (#1) native/mongrel_service.bas:54, mongrel_service.single_oninit: (#1)single_onInit() (#1) native/mongrel_service.bas:71, mongrel_service.single_oninit: (#1)starting child process with cmdline: ruby.exec:\ruby\bin\mongrel_rails start -e production -p 4001 -a 0.0.0.0 -l log/mongrel.log -P log/mongrel.pid -c c:/projects/rails-prod/wingate -t 0 -r public -n 1024 (#1) # Logfile created on 05/02/2007 23:37:42 (#1) native/process.bas:44, fb.process.spawn: (#1) Spawn() init (#1) native/process.bas:52, fb.process.spawn: (#1) AllocConsole failed, maybe already allocated, safely to discart. (#1) native/process.bas:105, fb.process.spawn: (#1) Creating child process with cmdline: ruby.exec:\ruby\bin\mongrel_rails start -e production -p 4001 -a 0.0.0.0 -l log/mongrel.log -P log/mongrel.pid -c c:/projects/rails-prod/wingate -t 0 -r public -n 1024 (#1) native/process.bas:121, fb.process.spawn: (#1) Closing handles. (#1) native/process.bas:136, fb.process.spawn: (#1) wait_code: 258 (#1) native/process.bas:141, fb.process.spawn: (#1) New children PID: 3984 (#1) native/process.bas:156, fb.process.spawn: (#1) Spawn() done (#1) native/mongrel_service.bas:79, mongrel_service.single_oninit: (#1) child process pid: 3984 (#1) native/mongrel_service.bas:88, mongrel_service.single_oninit: (#1) single_onInit() done (#1) native/mongrel_service.bas:93, mongrel_service.single_onstart: (#1) single_onStart() *** Ok, now a bad start (w/ prefix) *** (#2) # Logfile created on 05/02/2007 23:38:28 (#2) native/mongrel_service.bas:148, mongrel_service.application: (#2) ServiceHost RunAsService (#2) native/mongrel_service.bas:54, mongrel_service.single_oninit: (#2) single_onInit() (#2) native/mongrel_service.bas:71, mongrel_service.single_oninit: (#2) starting child process with cmdline: ruby.exec:\ruby\bin\mongrel_rails start -e production -p 4001 -a 0.0.0.0 -l log/mongrel.log -P log/mongrel.pid -c c:/projects/rails-prod/wingate -t 0 -r public -n 1024 --prefix /wingate (#2) # Logfile created on 05/02/2007 23:38:28 (#2) native/process.bas:44, fb.process.spawn: (#2) Spawn() init (#2) native/process.bas:52, fb.process.spawn: (#2) AllocConsole failed, maybe already allocated, safely to discart. (#2) native/process.bas:105, fb.process.spawn: (#2) C
Re: [Mongrel] Mongrel service never starts
heyThanks guysThe problem was with a conflict of versions with my rails project and the rails gem on the deployement server.I love this communityThanks againGuillaume Carbonneau On 8/30/06, Jay Turpin <[EMAIL PROTECTED]> wrote: Definitely try it with mongrel_rails start first. For me, my server was missing the version of Rails that my app was expecting.-- -- Jay Turpin "One test is worth a thousand expert opinions." - Bill Nye (The Science Guy) ___Mongrel-users mailing listMongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel service never starts
Definitely try it with mongrel_rails start first. For me, my server was missing the version of Rails that my app was expecting.-- -- Jay Turpin"One test is worth a thousand expert opinions." - Bill Nye (The Science Guy) ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel service never starts
On 8/30/06, Guillaume Carbonneau <[EMAIL PROTECTED]> wrote: > > I'm on a Win2K server environnement running ruby 1.8.5 and mongrel > > I've followed the tutorial and everything went fine until I start the > service... > > Here is the output I'm getting : > > C:\ruby\bin>mongrel_rails service::start -N inventaire > One moment, start pending > One moment, stopped > > One moment, stopped > > One moment, stopped > > One moment, stopped > > One moment, stopped > > and so on ( "One moment, stopped" message keeps popping) > > any idea? Look in the log/service.log I suspect there is an exception. I've heard of two possible problems with rails and 1.8.5: One, the breakpointer works no more, and other is deprecation of when XXX: YYY over when XXX; YYY or when XXX then YYY. Start the thing as normal rails app with mongrel or webrick to see more of the problem until it works fine. (non-service version has obviously shorter roundtrip edit-start-crash-diagnose) ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
Re: [Mongrel] Mongrel service never starts
On 8/30/06, Guillaume Carbonneau <[EMAIL PROTECTED]> wrote: > > I'm on a Win2K server environnement running ruby 1.8.5 and mongrel > > I've followed the tutorial and everything went fine until I start the > service... > > Here is the output I'm getting : > > C:\ruby\bin>mongrel_rails service::start -N inventaire > One moment, start pending > One moment, stopped > > One moment, stopped > > One moment, stopped > > One moment, stopped > > One moment, stopped > > and so on ( "One moment, stopped" message keeps popping) > > any idea? > Hi Guillaume, That often means your application crashed. Have you tried running it with mongrel_rails first? Mongrel is compatible with 1.8.4, no official testing was made with 1.8.5, nor for Rails (which seems to brake some things). As I said, try running from command line "mongrel_rails start" and check if your application start ok, if so, the problem could be checked from the log/service.log file into your application directory. Hope that helps, -- 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@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users
[Mongrel] Mongrel service never starts
I'm on a Win2K server environnement running ruby 1.8.5 and mongrel I've followed the tutorial and everything went fine until I start the service... Here is the output I'm getting : C:\ruby\bin>mongrel_rails service::start -N inventaire One moment, start pending One moment, stopped One moment, stopped One moment, stopped One moment, stopped One moment, stopped and so on ( "One moment, stopped" message keeps popping) any idea? Guillaume Carbonneau ___ Mongrel-users mailing list Mongrel-users@rubyforge.org http://rubyforge.org/mailman/listinfo/mongrel-users