I''m trying to migrate a rails app I developed on my WinXP box over to a Redhat Enterprise Linux box. So far I''ve compiled and installed Apache 2.0, mod_fastcgi, ruby 1.8.2, and ruby-fcgi. If I try to access the rails web app using the cgi dispatcher, everything is fine. As soon as I change the .htaccess file to use the dispatch.fcgi Apache keeps logging errors saying that the file "/var/www/rails/public/dispatch.fcgi/" does not exist. What could I be doing wrong here? Is it not finding the file because of that last slash? I tried going to http://localhost/dispatch.fcgi and Apache just renders the text of the script, rather than executing it. I have the applicable lines added to my httpd.conf and .htaccess to load the fastcgi module and handle .fcgi files. Any ideas? Thanks, Chris _______________________________________________ Rails mailing list Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org http://lists.rubyonrails.org/mailman/listinfo/rails
Do you have something like this in your apache config? If not, you probably need to put it there. ----- LoadModule fastcgi_module modules/mod_fastcgi.so AddModule mod_fastcgi.c <IfModule mod_fastcgi.c> FastCgiIpcDir /tmp/fcgi_ipc/ AddHandler fastcgi-script .fcgi </IfModule> ----- It sounds like apache isn''t configured to use fcgi. If that AddHandler line isn''t there then it won''t know what to do with files with a .fcgi extension. Brian On Tue, 1 Feb 2005 16:53:54 -0500, Williams, Chris <Chris.Williams-yLTBD9Em4aGakBO8gow8eQ@public.gmane.org> wrote:> > > I''m trying to migrate a rails app I developed on my WinXP box over to a > Redhat Enterprise Linux box. So far I''ve compiled and installed Apache 2.0, > mod_fastcgi, ruby 1.8.2, and ruby-fcgi. > > If I try to access the rails web app using the cgi dispatcher, everything is > fine. As soon as I change the .htaccess file to use the dispatch.fcgi Apache > keeps logging errors saying that the file > "/var/www/rails/public/dispatch.fcgi/" does not exist. > > What could I be doing wrong here? Is it not finding the file because of that > last slash? I tried going to http://localhost/dispatch.fcgi and Apache just > renders the text of the script, rather than executing it. I have the > applicable lines added to my httpd.conf and .htaccess to load the fastcgi > module and handle .fcgi files. > > Any ideas? > > Thanks, > Chris > _______________________________________________ > Rails mailing list > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > http://lists.rubyonrails.org/mailman/listinfo/rails > > >-- The years ahead pick up their dark bags. They move closer. There''s a slight rise in the silence then nothing. -- (If you''re receiving this in response to mail sent to bluczkie-OM76b2Iv3yLQjUSlxSEPGw@public.gmane.org, don''t be concerned This is my new address, but mail will be forwarded here indefinitely)
Brian,> Do you have something like this in your apache config? If not, you > probably need to put it there. > ----- > > LoadModule fastcgi_module modules/mod_fastcgi.so > AddModule mod_fastcgi.c > > <IfModule mod_fastcgi.c> > FastCgiIpcDir /tmp/fcgi_ipc/ > AddHandler fastcgi-script .fcgi > </IfModule> > > ----- > It sounds like apache isn''t configured to use fcgi. If that AddHandler > line isn''t there then it won''t know what to do with files with a .fcgi > extension.That''s exactly what I have in my config - so I don''t think that''s the problem. Thanks, Chris
On Wed, Feb 02, 2005 at 10:13:11AM -0500, Williams, Chris wrote:> Brian wrote: > > It sounds like apache isn''t configured to use fcgi. If that AddHandler > > line isn''t there then it won''t know what to do with files with a .fcgi > > extension. > > That''s exactly what I have in my config - so I don''t think that''s the > problem.Has apache been restarted since changing the config? Sorry - I''m sure it has, but I often forget that bit. -- Mick Brooks
> > Brian wrote: > > > It sounds like apache isn''t configured to use fcgi. If thatAddHandler> > > line isn''t there then it won''t know what to do with files with a.fcgi> > > extension. > > > > That''s exactly what I have in my config - so I don''t think that''sthe> > problem. > > Has apache been restarted since changing the config? Sorry - I''m sureit> has, but I often forget that bit.Yes. I''ve restarted Apache.
> > LoadModule fastcgi_module modules/mod_fastcgi.so > > AddModule mod_fastcgi.c > > > > <IfModule mod_fastcgi.c> > > FastCgiIpcDir /tmp/fcgi_ipc/ > > AddHandler fastcgi-script .fcgi > > </IfModule> > > > > ----- > > It sounds like apache isn''t configured to use fcgi. If that AddHandler > > line isn''t there then it won''t know what to do with files with a .fcgi > > extension. > > That''s exactly what I have in my config - so I don''t think that''s the > problem.Interesting, the AddHandler is added in the IfModule block. The handler isn''t in turned on which is why you see the script source when you browse to it. Perhaps mod_fastcgi isn''t being found by apache. Is mod_fastcgi.so in the same directory as the other DSOs?> Thanks, > Chris > _______________________________________________ > Rails mailing list > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > http://lists.rubyonrails.org/mailman/listinfo/rails >-- Cheers Koz
> > > LoadModule fastcgi_module modules/mod_fastcgi.so > > > AddModule mod_fastcgi.c > > > > > > <IfModule mod_fastcgi.c> > > > FastCgiIpcDir /tmp/fcgi_ipc/ > > > AddHandler fastcgi-script .fcgi > > > </IfModule> > > > > > > ----- > > > It sounds like apache isn''t configured to use fcgi. If thatAddHandler> > > line isn''t there then it won''t know what to do with files with a.fcgi> > > extension. > > > > That''s exactly what I have in my config - so I don''t think that''sthe> > problem. > > Interesting, the AddHandler is added in the IfModule block. The > handler isn''t in turned on which is why you see the script source when > you browse to it. > > Perhaps mod_fastcgi isn''t being found by apache. Is mod_fastcgi.so in > the same directory as the other DSOs?Ack, this is one of those moments where you seriously question your own intelligence. My sysadmin set up Apache to run on boot and I had asked her to remove that copy of Apache so I could recompile a newer version with fastCGI. Well she never removed it, and so all the changes I had made to my new copy weren''t doing anything. Once I stopped the old server and started the new one, everything was OK. Sorry! Chris