Rails on Apache: FAIL

Hey guys,
I am getting the following while trying to run a rails project someone
else wrote under apache:

[Tue Jul 22 19:50:33 2008] [notice] Apache/2.2.9 (Unix) mod_ruby/1.2.6
Ruby/1.8.6(2008-03-03) configured – resuming normal operations
[Tue Jul 22 19:50:45 2008] [error] mod_ruby: failed to require
apache/rails-dispatcher
[Tue Jul 22 19:50:45 2008] [error] mod_ruby: error in ruby
[Tue Jul 22 19:50:45 2008] [error] mod_ruby:
/usr/lib/ruby/site_ruby/1.8/rubygems.rb:139:in activate': can't activate actionpack (= 1.13.6), already activated actionpack-2.1.0] (Gem::Exception) [Tue Jul 22 19:50:45 2008] [error] mod_ruby: from /usr/lib/ruby/site_ruby/1.8/rubygems.rb:155:inactivate’
[Tue Jul 22 19:50:45 2008] [error] mod_ruby: from
/usr/lib/ruby/site_ruby/1.8/rubygems.rb:154:in each' [Tue Jul 22 19:50:45 2008] [error] mod_ruby: from /usr/lib/ruby/site_ruby/1.8/rubygems.rb:154:inactivate’
[Tue Jul 22 19:50:45 2008] [error] mod_ruby: from
/usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in require' [Tue Jul 22 19:50:45 2008] [error] mod_ruby: from /usr/lib/ruby/gems/1.8/gems/activesupport-2.1.0/lib/active_support/dependencies.rb:509:inrequire’
[Tue Jul 22 19:50:45 2008] [error] mod_ruby: from
/usr/lib/ruby/gems/1.8/gems/activesupport-2.1.0/lib/active_support/dependencies.rb:354:in
new_constants_in' [Tue Jul 22 19:50:45 2008] [error] mod_ruby: from /usr/lib/ruby/gems/1.8/gems/activesupport-2.1.0/lib/active_support/dependencies.rb:509:inrequire’
[Tue Jul 22 19:50:45 2008] [error] mod_ruby: from
/usr/lib/ruby/1.8/apache/rails-dispatcher.rb:55
[Tue Jul 22 19:50:45 2008] [error] mod_ruby: from
/usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in
gem_original_require' [Tue Jul 22 19:50:45 2008] [error] mod_ruby: from /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:inrequire’

I have googled quite some, but none of the answers I found actually
worked. Any pointers as to what could be going wrong there? I am running
rails 2.1.0, mod_ruby 1.2.6 and ruby 1.8.6.

Thanks a bunch!

On Jul 23, 12:56 am, Kryptic M. [email protected]
wrote:

Hey guys,
I am getting the following while trying to run a rails project someone
else wrote under apache:

I didn’t think anyone actually used mod_ruby. What happens if you just
try and bring up the app’s console (require script/console) ?
Off the top of my head it looks like one bit of the app is requiring
actionpack (which causes the latest version available to be loaded)
but then some other bit is requiring a specific version (1.13.6 which,
if memory serves me correctly, was parts of rails 1.2.6).

This might happen for example if environment.rb specified 1.2.6 as the
version of rails to load, but somewhere else some was just trying to
load the actionpack gem

Fred

Frederick C. wrote:

On Jul 23, 12:56�am, Kryptic M. [email protected]
wrote:

Hey guys,
I am getting the following while trying to run a rails project someone
else wrote under apache:

I didn’t think anyone actually used mod_ruby. What happens if you just
try and bring up the app’s console (require script/console) ?
Hey Fredrick!
Thanks for the response! Should I use FCGI with Apache instead of
mod_ruby? What is the community “standard” as for running RoR apps?

Regards,
KM

You could also try Passenger ie ModRails http://www.modrails.com/

On Wed, Jul 23, 2008 at 4:31 PM, Jean N.

Hey Fredrick!
Thanks for the response! Should I use FCGI with Apache instead of
mod_ruby? What is the community “standard” as for running RoR apps?

Regards,
KM

Forget apache and the mod_ruby unless you HAVE to use it… it’s sorta
“old school” now with the newer technologies just as performant and
reliable.

Mongrel w/ Nginx.

Try those you wont regret it.

Or check out “Heroku” (google it) and see if you can get an account
there… they do it all for you.

Hope this helps.

Lee I. wrote:

You could also try Passenger ie ModRails http://www.modrails.com/

On Wed, Jul 23, 2008 at 4:31 PM, Jean N.

Hi Lee!
That did it. Thanks for the help guys!