I’ve poured over many docs online and thought it would be wonderful to
get RoR running in 15 minutes. Well after 15 hours, I’m completely
stuck and ready to give up on RoR. I’m hoping somebody can give me
some guidance. I’ve pulled out my hair and am bald like others who
have tried to get RoR running without any luck.
When I run http://71.159.224.53/say/hello, I keep get application error:
Change this error message for exceptions thrown outside of an action
(like in Dispatcher setups or broken Ruby code) in public/500.html
I’m trying to get RoR running on Apache2 on Red Hat Enterprise 4. By
the way if Apache2 is no good with RoR, I can switch to Apache 1.3. In
any case, I have the standard set up as you can see at the very bottom
of this post.
The interesting thing is that I output the rewrite.log and it shows
that for some reason RoR is trying to access:
/var/www/rails/demo/public/say/hello.html/hello → say/hello.html/hello
And it fails when it doesn’t find this file:
/var/www/rails/demo/public/say/hello.html’ pattern=‘!-f’ => matched
However, my “say” controller is located here:
/var/www/rails/demo/app/controllers/say_controller.rb
Here is the output of the rewrite log. Something is not write here:
68.111.180.250 - - [24/Jun/2006:02:22:29 --0700]
[71.159.224.53/sid#81d3230][rid#81e2a98/initial] (2) init rewrite
engine with requested uri /say/hello
68.111.180.250 - - [24/Jun/2006:02:22:29 --0700]
[71.159.224.53/sid#81d3230][rid#81e2a98/initial] (1) pass through
/say/hello
68.111.180.250 - - [24/Jun/2006:02:22:29 --0700]
[71.159.224.53/sid#81d3230][rid#81e2a98/initial] (3) [per-dir
/var/www/rails/demo/public/] add path info postfix:
/var/www/rails/demo/public/say → /var/www/rails/demo/public/say/hello
68.111.180.250 - - [24/Jun/2006:02:22:29 --0700]
[71.159.224.53/sid#81d3230][rid#81e2a98/initial] (3) [per-dir
/var/www/rails/demo/public/] strip per-dir prefix:
/var/www/rails/demo/public/say/hello → say/hello
68.111.180.250 - - [24/Jun/2006:02:22:29 --0700]
[71.159.224.53/sid#81d3230][rid#81e2a98/initial] (3) [per-dir
/var/www/rails/demo/public/] applying pattern ‘^$’ to uri ‘say/hello’
68.111.180.250 - - [24/Jun/2006:02:22:29 --0700]
[71.159.224.53/sid#81d3230][rid#81e2a98/initial] (3) [per-dir
/var/www/rails/demo/public/] add path info postfix:
/var/www/rails/demo/public/say → /var/www/rails/demo/public/say/hello
68.111.180.250 - - [24/Jun/2006:02:22:29 --0700]
[71.159.224.53/sid#81d3230][rid#81e2a98/initial] (3) [per-dir
/var/www/rails/demo/public/] strip per-dir prefix:
/var/www/rails/demo/public/say/hello → say/hello
68.111.180.250 - - [24/Jun/2006:02:22:29 --0700]
[71.159.224.53/sid#81d3230][rid#81e2a98/initial] (3) [per-dir
/var/www/rails/demo/public/] applying pattern ‘^([^.]+)$’ to uri
‘say/hello’
68.111.180.250 - - [24/Jun/2006:02:22:29 --0700]
[71.159.224.53/sid#81d3230][rid#81e2a98/initial] (2) [per-dir
/var/www/rails/demo/public/] rewrite say/hello → say/hello.html
68.111.180.250 - - [24/Jun/2006:02:22:29 --0700]
[71.159.224.53/sid#81d3230][rid#81e2a98/initial] (3) [per-dir
/var/www/rails/demo/public/] add per-dir prefix: say/hello.html →
/var/www/rails/demo/public/say/hello.html
68.111.180.250 - - [24/Jun/2006:02:22:29 --0700]
[71.159.224.53/sid#81d3230][rid#81e2a98/initial] (3) [per-dir
/var/www/rails/demo/public/] add path info postfix:
/var/www/rails/demo/public/say/hello.html →
/var/www/rails/demo/public/say/hello.html/hello
68.111.180.250 - - [24/Jun/2006:02:22:29 --0700]
[71.159.224.53/sid#81d3230][rid#81e2a98/initial] (3) [per-dir
/var/www/rails/demo/public/] strip per-dir prefix:
/var/www/rails/demo/public/say/hello.html/hello → say/hello.html/hello
68.111.180.250 - - [24/Jun/2006:02:22:29 --0700]
[71.159.224.53/sid#81d3230][rid#81e2a98/initial] (3) [per-dir
/var/www/rails/demo/public/] applying pattern ‘^(.*)$’ to uri
‘say/hello.html/hello’
68.111.180.250 - - [24/Jun/2006:02:22:29 --0700]
[71.159.224.53/sid#81d3230][rid#81e2a98/initial] (4) RewriteCond:
input=‘/var/www/rails/demo/public/say/hello.html’ pattern=‘!-f’ =>
matched
68.111.180.250 - - [24/Jun/2006:02:22:29 --0700]
[71.159.224.53/sid#81d3230][rid#81e2a98/initial] (2)…
----------------- APACHE2 CONF VIRTUAL HOST --------------------------
NameVirtualHost 71.159.224.53
<VirtualHost 71.159.224.53>
ServerAdmin [email protected]
DocumentRoot /var/www/rails/demo/public
#ServerName www.example.com
ErrorLog /var/log/httpd/rail-error_log
CustomLog /var/log/httpd/rail-access_log common
Options Indexes ExecCGI FollowSymLinks
RewriteEngine On
RewriteLog "/var/log/httpd/rewrite.log"
RewriteLogLevel 4
------------------------ .htaccess --------------------------------
General Apache options
AddHandler fastcgi-script .fcgi
AddHandler cgi-script .cgi
Options +FollowSymLinks +ExecCGI
RewriteEngine On
RewriteRule ^$ index.html [QSA]
RewriteRule ^([^.]+)$ $1.html [QSA]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.*)$ dispatch.cgi [QSA,L]
–
[email protected]
Position Research, Inc.
Search engine results by research
tel: (760) 480-8291 fax: (760) 480-8271
www.PositionResearch.com