Hi everyone, I used some HowTo''s to get RoR running on my Debian (etch) and Apache 2 system. None of them work for me. I always get a 500 Error. When I start Webrick, all is working just fine but I just don''t get it working with Apache. Ruby- and Apache-Log just tell me that I got a 500 Error. These are my activated modules from Apache: lrwxrwxrwx 1 root root 40 2005-12-10 13:35 actions.load -> /etc/apache2/mods-available/actions.load lrwxrwxrwx 1 root root 28 2007-12-15 11:32 alias.load -> ../mods-available/alias.load lrwxrwxrwx 1 root root 33 2007-12-15 11:32 auth_basic.load -> ../mods-available/auth_basic.load lrwxrwxrwx 1 root root 33 2007-12-15 11:32 authn_file.load -> ../mods-available/authn_file.load lrwxrwxrwx 1 root root 36 2007-12-15 11:32 authz_default.load -> ../mods-available/authz_default.load lrwxrwxrwx 1 root root 38 2007-12-15 11:32 authz_groupfile.load -> ../mods-available/authz_groupfile.load lrwxrwxrwx 1 root root 33 2007-12-15 11:32 authz_host.load -> ../mods-available/authz_host.load lrwxrwxrwx 1 root root 33 2007-12-15 11:32 authz_user.load -> ../mods-available/authz_user.load lrwxrwxrwx 1 root root 32 2007-12-15 11:32 autoindex.load -> ../mods-available/autoindex.load lrwxrwxrwx 1 root root 36 2005-12-10 00:58 cgi.load -> /etc/apache2/mods-available/cgi.load lrwxrwxrwx 1 root root 29 2008-01-09 16:11 dav_fs.conf -> ../mods-available/dav_fs.conf lrwxrwxrwx 1 root root 29 2008-01-09 16:11 dav_fs.load -> ../mods-available/dav_fs.load lrwxrwxrwx 1 root root 26 2008-01-09 14:52 dav.load -> ../mods-available/dav.load lrwxrwxrwx 1 root root 30 2008-01-09 14:52 dav_svn.conf -> ../mods-available/dav_svn.conf lrwxrwxrwx 1 root root 30 2008-01-09 14:52 dav_svn.load -> ../mods-available/dav_svn.load lrwxrwxrwx 1 root root 26 2007-12-15 11:32 dir.conf -> ../mods-available/dir.conf lrwxrwxrwx 1 root root 26 2007-12-15 11:32 dir.load -> ../mods-available/dir.load lrwxrwxrwx 1 root root 26 2007-12-15 11:32 env.load -> ../mods-available/env.load lrwxrwxrwx 1 root root 30 2008-01-10 19:35 fastcgi.conf -> ../mods-available/fastcgi.conf lrwxrwxrwx 1 root root 30 2008-01-10 19:35 fastcgi.load -> ../mods-available/fastcgi.load lrwxrwxrwx 1 root root 30 2008-01-10 20:00 include.load -> ../mods-available/include.load lrwxrwxrwx 1 root root 27 2007-12-15 11:32 mime.load -> ../mods-available/mime.load lrwxrwxrwx 1 root root 34 2007-12-15 11:32 negotiation.load -> ../mods-available/negotiation.load lrwxrwxrwx 1 root root 27 2007-12-28 15:43 php5.conf -> ../mods-available/php5.conf lrwxrwxrwx 1 root root 27 2007-12-28 15:43 php5.load -> ../mods-available/php5.load lrwxrwxrwx 1 root root 30 2005-12-13 21:52 rewrite.load -> ../mods-available/rewrite.load lrwxrwxrwx 1 root root 31 2007-12-15 11:32 setenvif.load -> ../mods-available/setenvif.load lrwxrwxrwx 1 root root 36 2006-02-23 11:30 ssl.conf -> /etc/apache2/mods-available/ssl.conf lrwxrwxrwx 1 root root 36 2006-02-23 11:30 ssl.load -> /etc/apache2/mods-available/ssl.load lrwxrwxrwx 1 root root 29 2007-12-15 11:32 status.load -> ../mods-available/status.load lrwxrwxrwx 1 root root 29 2008-01-10 20:00 suexec.load -> ../mods-available/suexec.load This is what I added to the apache.conf: <Directory /var/www/rubyproject/public> Options ExecCGI FollowSymlinks AllowOverride all Order allow,deny Allow from all </Directory> And this is how my .htaccess in /public looks like: 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] ErrorDocument 500 "<h2>Application error</h2>Rails application failed to start properly" If you need more logs/confs, tell me. I''m trying to solve this problem for 2 days now and I''m absolutely desperate. Thanks in advance! -- 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 -~----------~----~----~----~------~----~------~--~---
maybe test with a simple dispatch.fcgi one that just prints hello? Looks like it''s an apache error mostly (?) check your logs, rails logs, error logs. GL! -Roger Heinz Strunk wrote:> If you need more logs/confs, tell me. > > I''m trying to solve this problem for 2 days now and I''m absolutely > desperate. Thanks in advance!-- 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 -~----------~----~----~----~------~----~------~--~---
Well, it all works with Webrick so I guess dispatch files are alright? Apache access.log: 88.3.237.x - - [12/Jan/2008:19:16:42 +0100] "GET / HTTP/1.1" 500 309 "-" "Mozilla/5.0 (Windows; U; Windows NT 6.0; de; rv:1.8.1.11) Gecko/20071127 Firefox/2.0.0.11" 88.3.237.x - - [12/Jan/2008:19:16:50 +0100] "GET /favicon.ico HTTP/1.1" 200 - "-" "Mozilla/5.0 (Windows; U; Windows NT 6.0; de; rv:1.8.1.11) Gecko/20071127 Firefox/2.0.0.11" Ruby log: Recognition failed for "/" /var/www/virtual/ps-lifestyle.de/new/htdocs/public/../config/../vendor/rails/actionpack/lib/action_controller/routing.rb:522:in `recognition_failed'' /var/www/virtual/ps-lifestyle.de/new/htdocs/public/../config/../vendor/rails/actionpack/lib/action_controller/routing.rb:512:in `recognize!'' /var/www/virtual/ps-lifestyle.de/new/htdocs/public/../config/../vendor/rails/railties/lib/dispatcher.rb:38:in `dispatch'' /var/www/virtual/ps-lifestyle.de/new/htdocs/public/dispatch.cgi:12 Line 12 in dispatch.cgi: Dispatcher.dispatch Roger Pack wrote:> maybe test with a simple dispatch.fcgi one that just prints hello? > Looks like it''s an apache error mostly (?) > check your logs, rails logs, error logs. > GL! > -Roger-- 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 -~----------~----~----~----~------~----~------~--~---
I created a complete new Rails application but get the same error. Anyone has a clue why this is happening? -- 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 -~----------~----~----~----~------~----~------~--~---
Heinz Strunk wrote:> I created a complete new Rails application but get the same error. > Anyone has a clue why this is happening?maybe create a public/index.html ? make sure it works with just normal requests...checkout various instructions on how to set it 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 -~----------~----~----~----~------~----~------~--~---
I created a index.html with normal html-stuff inside and it was all displayed normally. Roger Pack wrote:> Heinz Strunk wrote: >> I created a complete new Rails application but get the same error. >> Anyone has a clue why this is happening? > > maybe create a public/index.html ? > make sure it works with just normal requests...checkout various > instructions on how to set it 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 -~----------~----~----~----~------~----~------~--~---
Heinz Strunk wrote:> I created a index.html with normal html-stuff inside and it was all > displayed normally. > > Roger Pack wrote: >> Heinz Strunk wrote: >>> I created a complete new Rails application but get the same error. >>> Anyone has a clue why this is happening? >> >> maybe create a public/index.html ? >> make sure it works with just normal requests...checkout various >> instructions on how to set it up...lookup on google how to replace public/index.html (you set up a route for it). -- 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 -~----------~----~----~----~------~----~------~--~---
Sorry but I don'' really get what you mean by saying replace public/index.html. I normally delete it and that''s it. Could you please explain what you mean by replacing index.html and setting up a route? Thanks a lot. Roger Pack wrote:> > lookup on google how to replace public/index.html (you set up a route > for it).-- 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 -~----------~----~----~----~------~----~------~--~---
> lookup on google how to replace public/index.html (you set up a route > for it).sorry. what I meant was google search for rails replace public/index.html GL! -- 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 -~----------~----~----~----~------~----~------~--~---
Well, I tried the first 5 page results from Google and I''m not a bit smarter how to solve that problem. I might be too stupid or just don''t get your point but thanks anyway ;) Roger Pack wrote:> > sorry. what I meant was google search for > rails replace public/index.html > GL!-- 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 -~----------~----~----~----~------~----~------~--~---
Thanks for doing that. What you need to do is delete that file and set up a ''route'' for '''' a la map.connect '''', :controller => ''site'', :action => ''index'' (from the second link). GL! -- 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 -~----------~----~----~----~------~----~------~--~---
Aaaah! OK, that''s what you''re talking about! Like I said it''s all works when I use WEBrick so the project itself is 100% working. So the routes and everything are set prooperly. WEBrick: Project works just fine. Apache: 500 Error. Roger Pack wrote:> Thanks for doing that. > What you need to do is delete that file and set up a ''route'' for '''' > a la > map.connect '''', :controller => ''site'', :action => ''index'' > (from the second link). > GL!-- 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 -~----------~----~----~----~------~----~------~--~---
Heinz Strunk wrote:> Hi everyone, > > I used some HowTo''s to get RoR running on my Debian (etch) and Apache 2 > system. None of them work for me. > > I always get a 500 Error. When I start Webrick, all is working just fine > but I just don''t get it working with Apache.Have you checked the apache error log? webrick error log? -- 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 -~----------~----~----~----~------~----~------~--~---
Roger Pack wrote:> Have you checked the apache error log? webrick error log?No error log from WEBrick cause like I said it''s all working there. Apache-Log: 83.37.126.* - - [15/Jan/2008:16:34:43 +0100] "GET / HTTP/1.1" 500 309 "-" "Mozilla/5.0 (Windows; U; Windows NT 6.0; de; rv:1.8.1.11) Gecko/20071127 Firefox/2.0.0.11" -- 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 -~----------~----~----~----~------~----~------~--~---
> Apache-Log: > 83.37.126.* - - [15/Jan/2008:16:34:43 +0100] "GET / HTTP/1.1" 500 309 > "-" "Mozilla/5.0 (Windows; U; Windows NT 6.0; de; rv:1.8.1.11) > Gecko/20071127 Firefox/2.0.0.11"apache error log? -- 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 -~----------~----~----~----~------~----~------~--~---
Roger Pack wrote:> > apache error log?It does not write anything in the error.log -- 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 -~----------~----~----~----~------~----~------~--~---
does it not throw 500 when there is a public.html? what about if you do an action/view? does webrick work when you load ''/''? -- 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 -~----------~----~----~----~------~----~------~--~---
Roger Pack wrote:> does it not throw 500 when there is a public.html? what about if you do > an action/view? does webrick work when you load ''/''?most of my 500''s from this type of thing are when a directory or file aren''t chmod ag-w * (I think). -- 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 -~----------~----~----~----~------~----~------~--~---
Roger Pack wrote:> > most of my 500''s from this type of thing are when a directory or file > aren''t chmod ag-w * (I think).Thank you so much! I did that chmod ag-w thing and changed the owner from the ftp-user (who uploaded it) to www-data and no it works all fine. Thanks man! Cojones -- 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 -~----------~----~----~----~------~----~------~--~---