Hello, I''m trying to switch to FastCGI. With CGI everything works, but after have done all the steps of the wiki here (http://wiki.rubyonrails.org/rails/pages/RailsOnUbuntuDebianTestingAndUnstable) My application started to give me "Error 500" Looking at the Apache logs I can see : [notice] mod_fcgid: server /rails/public/dispatch.fcgi(6127) started /usr/lib/ruby/gems/1.8/gems/activesupport-1.2.5/lib/active_support/dependencies.rb:200:in `const_missing'': uninitialized constant RailsFCGIHandler (NameError) from /rails/public/dispatch.fcgi:25 [notice] mod_fcgid: process /rails/public/dispatch.fcgi(6127) exit(communication error), terminated by calling exit(), return code: 1 The environment is : Ubuntu - Apache 2 - Gem 0.8.11 - Ruby 1.8.3 Any ideas ? Simone -- Posted via http://www.ruby-forum.com/.
On 19 Feb 2006, at 16:57, Simone Fumagalli wrote:> > The environment is : > Ubuntu - Apache 2 - Gem 0.8.11 - Ruby 1.8.3Ubuntu likes you to call the "fastcgi-script" "fcgid-script .fcgi". so go to the public/.htaccess file and change the line: => AddHandler fastcgi-script .fcgi at the top of the file to: => AddHandler fcgid-script .fcgi thats what I have to do on my Ubuntu breezy dev. server. David Smalley w: http://davidsmalley.com/blog
Simone Fumagalli
2006-Feb-20 08:36 UTC
[Rails] Re: uninitialized constant RailsFCGIHandler
David Smalley wrote:> Ubuntu likes you to call the "fastcgi-script" "fcgid-script .fcgi". > > so go to the public/.htaccess file and change the line: > => AddHandler fastcgi-script .fcgi > > at the top of the file to: > => AddHandler fcgid-script .fcgiIt''s already like this :-( Any other advice ? Simone -- Posted via http://www.ruby-forum.com/.
On 20 Feb 2006, at 08:36, Simone Fumagalli wrote:> David Smalley wrote: >> Ubuntu likes you to call the "fastcgi-script" "fcgid-script .fcgi". >> >> so go to the public/.htaccess file and change the line: >> => AddHandler fastcgi-script .fcgi >> >> at the top of the file to: >> => AddHandler fcgid-script .fcgi > > It''s already like this :-(Have you done "gem install fcgi"? David Smalley w: http://davidsmalley.com/blog
Simone Fumagalli
2006-Feb-20 19:54 UTC
[Rails] Re: Re: uninitialized constant RailsFCGIHandler
David Smalley wrote:> On 20 Feb 2006, at 08:36, Simone Fumagalli wrote: > Have you done "gem install fcgi"?Yes, I did this as well ... :-( Simone -- Posted via http://www.ruby-forum.com/.
Greg Freemyer
2006-Feb-20 21:43 UTC
[Rails] Re: Re: uninitialized constant RailsFCGIHandler
On 2/20/06, Simone Fumagalli <simone@tomato.it> wrote:> David Smalley wrote: > > On 20 Feb 2006, at 08:36, Simone Fumagalli wrote: > > Have you done "gem install fcgi"? > > Yes, I did this as well ... :-( > > SimoneIf you run "ruby dispatch.fcgi" directly from the command line you should get "Status: 500 Internal Server Error." due to the lack of a webserver driving dispatch.fcgi. If instead it blows up, you have a basic fcgi setup issue. If you are getting the above, then I think you are having a website configuration issue. Greg -- Greg Freemyer The Norcross Group Forensics for the 21st Century
Simone Fumagalli
2006-Feb-21 08:27 UTC
[Rails] Re: Re: Re: uninitialized constant RailsFCGIHandler
Greg Freemyer wrote:> If you run "ruby dispatch.fcgi" directly from the command line you > should get "Status: 500 Internal Server Error." due to the lack of a > webserver driving dispatch.fcgi. > > If instead it blows up, you have a basic fcgi setup issue. > > If you are getting the above, then I think you are having a website > configuration issue.Hej, I create a new rails app on my system and that error disappeared ... but a new one came out :-( I posted it here : http://www.ruby-forum.com/topic/55353#37588 Simone -- Posted via http://www.ruby-forum.com/.
David Smalley
2006-Feb-21 10:43 UTC
[Rails] Re: Re: Re: uninitialized constant RailsFCGIHandler
On 21 Feb 2006, at 08:27, Simone Fumagalli wrote:> Greg Freemyer wrote: >> If you run "ruby dispatch.fcgi" directly from the command line you >> should get "Status: 500 Internal Server Error." due to the lack of a >> webserver driving dispatch.fcgi. >>This is what I do to debug a new application when I set it up and something goes wrong. Normally a bit more verbose than looking in apache logs> > Hej, I create a new rails app on my system and that error disappeared > ... but a new one came out :-( >I know that on my mac some modules put themselves into /usr/lib/ruby/site_ruby/1.8/... but the main ruby install is in /usr/lib/ruby/1.8 As its just a few extra modules in /site_ruby i have symlinked them into the /1.8 folder. Have a look in /usr/lib/ruby (or /usr/local/lib/ruby ) and see what your setup is. Perhaps your app is looking in site_ruby but your ruby install is in 1.8? David David Smalley w: http://davidsmalley.com/blog
> If you run "ruby dispatch.fcgi" directly from the command line you > should get "Status: 500 Internal Server Error." due to the lack of a > webserver driving dispatch.fcgi. > > If instead it blows up, you have a basic fcgi setup issue. > > If you are getting the above, then I think you are having a website > configuration issue.And what would that basic fcgi setup issue be? When I run dispatch.fcgi or try to run the script from my browser this appears in my apache error logs: [notice] mod_fcgid: process /usr/local/www/vhosts/shallotsanctuary.com/httpdocs/dispatch.fcgi(79949) exit(communication error), terminated by calling exit(), return code: 120 And if I run from the commandline, I get: /usr/local/lib/ruby/gems/1.8/gems/activesupport-1.4.2/lib/active_support/dependencies.rb:266:in `load_missing_constant'': uninitialized constant RailsFCGIHandler (NameError) Of course, if I use ruby -d, it certainly does "blow up". -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---