Hi, I''m trying to deploy my rails app through passenger on an Apache2 on debian etch. When I start to boot the app it doesn''t load one of my requires throwing an exception which looks like ''/usr/local/lib/ site_ruby/1.8/rubygems/custom_require.rb 31 in `gem_original_require'' '' on the stacktrace. The gem is installed and it''s located in the correct dir which I can find through ''gem environment''. I''m running ruby 1.8.5, passenger 2.2.2 and looking for kwalify 0.7.1. . Is this a debian bug, what am I missing? The app runs fine with the same configuration on my mac. Please help, Karl
Marc Byrd
2009-May-18 17:30 UTC
Re: Deploying Rails App on Debian Etch / Apache2 / Passenger
I also had this problem recently. A few things I did that ultimately got me up and running: - Used very latest rubygems (1.3.3 in my case) instead of that from debian distro - make sure the www-data user can read and execute all the rubygems (chown, chmod, chgrp, etc.). Hope this helps, Marc -- marc-p8aVV2LmIntWk0Htik3J/w@public.gmane.org On Mon, May 18, 2009 at 8:43 AM, karl <kpbode-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> > Hi, > I''m trying to deploy my rails app through passenger on an Apache2 on > debian etch. When I start to boot the app it doesn''t load one of my > requires throwing an exception which looks like ''/usr/local/lib/ > site_ruby/1.8/rubygems/custom_require.rb 31 in > `gem_original_require'' '' on the stacktrace. The gem is installed and > it''s located in the correct dir which I can find through ''gem > environment''. I''m running ruby 1.8.5, passenger 2.2.2 and looking for > kwalify 0.7.1. . > Is this a debian bug, what am I missing? The app runs fine with the > same configuration on my mac. > Please help, > Karl > > > >--~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
Karl, are you sure that all the gems installed in your Mac and on Debian are exactly the same version? You must check carefully the list of gems and versions in both parts to go out of doubt. Good luck. Cesar _______________________________________________ Gnu/Linux count user #416024 Pagina personal : http://www.cesardiaz.com.ar Mi blog : http://cesarediaz.blogspot.com Twitter : http://twitter.com/cesarstafe My github account: http://github.com/cesarediaz Skype: cesarstafe
Ok, tried these things. The gems are the same. Changing permissions doesn''t do anything. Running irb as www-data works fine. Should be a rails problem since it doesn''t work with script/console... On 18 Mai, 19:33, César <cesare.d...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Karl, > are you sure that all the gems installed in your Mac and on > Debian are exactly the same version? > You must check carefully the list of gems and versions in both > parts to go out of doubt. > > Good luck. > > Cesar > > _______________________________________________ > > Gnu/Linux count user #416024 > > Pagina personal :http://www.cesardiaz.com.ar > Mi blog :http://cesarediaz.blogspot.com > Twitter :http://twitter.com/cesarstafe > My github account:http://github.com/cesarediaz > Skype: cesarstafe
Never mind, script/console works fine. passenger not... On 18 Mai, 20:08, karl <kpb...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Ok, > > tried these things. The gems are the same. > Changing permissions doesn''t do anything. Running irb as www-data > works fine. Should be a rails problem since it doesn''t work with > script/console... > > On 18 Mai, 19:33, César <cesare.d...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > > Karl, > > are you sure that all the gems installed in your Mac and on > > Debian are exactly the same version? > > You must check carefully the list of gems and versions in both > > parts to go out of doubt. > > > Good luck. > > > Cesar > > > _______________________________________________ > > > Gnu/Linux count user #416024 > > > Pagina personal :http://www.cesardiaz.com.ar > > Mi blog :http://cesarediaz.blogspot.com > > Twitter :http://twitter.com/cesarstafe > > My github account:http://github.com/cesarediaz > > Skype: cesarstafe
See here at http://wiki.github.com/cesarediaz/inventory/installation-steps Those are the steps that I done to install an application(an open source rails application that I built) that I have allocated in github. Maybe you can find there another way to prove for install Passenger + Apache2 + a Rails application. Good luck. Cesar _______________________________________________ Gnu/Linux count user #416024 Pagina personal : http://www.cesardiaz.com.ar Mi blog : http://cesarediaz.blogspot.com Twitter : http://twitter.com/cesarstafe My github account: http://github.com/cesarediaz Skype: cesarstafe
Marc Byrd
2009-May-18 20:14 UTC
Re: Deploying Rails App on Debian Etch / Apache2 / Passenger
While I don''t recommend this as a long-term solution, it should help know whether this is the issue (make a backup first w/ current permissions): chown -R www-data:www-data /usr/lib/...gems I believe I also did chmod 777 /usr/bin/<gem_file> I also modified the /etc/init.d/apache2 script, adding to the ENV line things like: ENV="env -i LANG=C PATH=/usr/local/bin:/usr/bin:/bin:/usr/lib/ruby/gems/1.8/gems/simple_record-1.0.2/bin:/usr/lib/ruby/gems/1.8/gems/cloud_cache-1.0.1/bin" /etc/init.d/apache2 restart - (The more proper way to do this [should be built into ./bin/passenger-install-apache2-module ?] is to give these files group permissions, include www-data in the group). Other observations: 1) I had to include the full path for passenger-install-apache2-module, didn''t work as # passenger-install-apache2-module , not found) 2) script/console, script/runner, script/server - all worked fine, but passenger/apache2 didn''t work until I got permissions right. Good luck, m On Mon, May 18, 2009 at 11:08 AM, karl <kpbode-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> > Ok, > > tried these things. The gems are the same. > Changing permissions doesn''t do anything. Running irb as www-data > works fine. Should be a rails problem since it doesn''t work with > script/console... > > On 18 Mai, 19:33, César <cesare.d...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > Karl, > > are you sure that all the gems installed in your Mac and on > > Debian are exactly the same version? > > You must check carefully the list of gems and versions in both > > parts to go out of doubt. > > > > Good luck. > > > > Cesar > > > > _______________________________________________ > > > > Gnu/Linux count user #416024 > > > > Pagina personal :http://www.cesardiaz.com.ar > > Mi blog :http://cesarediaz.blogspot.com > > Twitter :http://twitter.com/cesarstafe > > My github account:http://github.com/cesarediaz > > Skype: cesarstafe > > >--~--~---------~--~----~------------~-------~--~----~ 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@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
Changed all the permissions, set path etc. but no changes yet... On 18 Mai, 22:14, Marc Byrd <dr.marc.b...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> While I don''t recommend this as a long-term solution, it should help know > whether this is the issue (make a backup first w/ current permissions): > > chown -R www-data:www-data /usr/lib/...gems > > I believe I also did chmod 777 /usr/bin/<gem_file> > > I also modified the /etc/init.d/apache2 script, adding to the ENV line > things like: > ENV="env -i LANG=C > PATH=/usr/local/bin:/usr/bin:/bin:/usr/lib/ruby/gems/1.8/gems/simple_record-1.0.2/bin:/usr/lib/ruby/gems/1.8/gems/cloud_cache-1.0.1/bin" > > /etc/init.d/apache2 restart - > > (The more proper way to do this [should be built into > ./bin/passenger-install-apache2-module ?] is to give these files group > permissions, include www-data in the group). > > Other observations: > 1) I had to include the full path for passenger-install-apache2-module, > didn''t work as # passenger-install-apache2-module , not found) > 2) script/console, script/runner, script/server - all worked fine, but > passenger/apache2 didn''t work until I got permissions right. > > Good luck, > > m > > On Mon, May 18, 2009 at 11:08 AM, karl <kpb...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > > Ok, > > > tried these things. The gems are the same. > > Changing permissions doesn''t do anything. Running irb as www-data > > works fine. Should be a rails problem since it doesn''t work with > > script/console... > > > On 18 Mai, 19:33, César <cesare.d...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > > Karl, > > > are you sure that all the gems installed in your Mac and on > > > Debian are exactly the same version? > > > You must check carefully the list of gems and versions in both > > > parts to go out of doubt. > > > > Good luck. > > > > Cesar > > > > _______________________________________________ > > > > Gnu/Linux count user #416024 > > > > Pagina personal :http://www.cesardiaz.com.ar > > > Mi blog :http://cesarediaz.blogspot.com > > > Twitter :http://twitter.com/cesarstafe > > > My github account:http://github.com/cesarediaz > > > Skype: cesarstafe
pharrington
2009-May-19 14:13 UTC
Re: Deploying Rails App on Debian Etch / Apache2 / Passenger
Are you using Ruby Enterprise Edition? What is PassengerRuby set to in your Apache configuration? Which version of Ruby is being invoked from the shell (run "which ruby")? On May 19, 10:00 am, karl <kpb...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Changed all the permissions, set path etc. but no changes yet... > > On 18 Mai, 22:14, Marc Byrd <dr.marc.b...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > > While I don''t recommend this as a long-term solution, it should help know > > whether this is the issue (make a backup first w/ current permissions): > > > chown -R www-data:www-data /usr/lib/...gems > > > I believe I also did chmod 777 /usr/bin/<gem_file> > > > I also modified the /etc/init.d/apache2 script, adding to the ENV line > > things like: > > ENV="env -i LANG=C > > PATH=/usr/local/bin:/usr/bin:/bin:/usr/lib/ruby/gems/1.8/gems/simple_record-1.0.2/bin:/usr/lib/ruby/gems/1.8/gems/cloud_cache-1.0.1/bin" > > > /etc/init.d/apache2 restart - > > > (The more proper way to do this [should be built into > > ./bin/passenger-install-apache2-module ?] is to give these files group > > permissions, include www-data in the group). > > > Other observations: > > 1) I had to include the full path for passenger-install-apache2-module, > > didn''t work as # passenger-install-apache2-module , not found) > > 2) script/console, script/runner, script/server - all worked fine, but > > passenger/apache2 didn''t work until I got permissions right. > > > Good luck, > > > m > > > On Mon, May 18, 2009 at 11:08 AM, karl <kpb...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > > > Ok, > > > > tried these things. The gems are the same. > > > Changing permissions doesn''t do anything. Running irb as www-data > > > works fine. Should be a rails problem since it doesn''t work with > > > script/console... > > > > On 18 Mai, 19:33, César <cesare.d...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > > > Karl, > > > > are you sure that all the gems installed in your Mac and on > > > > Debian are exactly the same version? > > > > You must check carefully the list of gems and versions in both > > > > parts to go out of doubt. > > > > > Good luck. > > > > > Cesar > > > > > _______________________________________________ > > > > > Gnu/Linux count user #416024 > > > > > Pagina personal :http://www.cesardiaz.com.ar > > > > Mi blog :http://cesarediaz.blogspot.com > > > > Twitter :http://twitter.com/cesarstafe > > > > My github account:http://github.com/cesarediaz > > > > Skype: cesarstafe
hey guys, I''m very thankful for your help. after inspecting rubygems myself and going down the whole way again, i figured that I accidently capitalized the gem name :-( Now everything seems to run.. On 19 Mai, 16:13, pharrington <xenogene...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Are you using Ruby Enterprise Edition? What is PassengerRuby set to in > your Apache configuration? Which version of Ruby is being invoked from > the shell (run "which ruby")? > > On May 19, 10:00 am, karl <kpb...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > > Changed all the permissions, set path etc. but no changes yet... > > > On 18 Mai, 22:14, Marc Byrd <dr.marc.b...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > > > While I don''t recommend this as a long-term solution, it should help know > > > whether this is the issue (make a backup first w/ current permissions): > > > > chown -R www-data:www-data /usr/lib/...gems > > > > I believe I also did chmod 777 /usr/bin/<gem_file> > > > > I also modified the /etc/init.d/apache2 script, adding to the ENV line > > > things like: > > > ENV="env -i LANG=C > > > PATH=/usr/local/bin:/usr/bin:/bin:/usr/lib/ruby/gems/1.8/gems/simple_record-1.0.2/bin:/usr/lib/ruby/gems/1.8/gems/cloud_cache-1.0.1/bin" > > > > /etc/init.d/apache2 restart - > > > > (The more proper way to do this [should be built into > > > ./bin/passenger-install-apache2-module ?] is to give these files group > > > permissions, include www-data in the group). > > > > Other observations: > > > 1) I had to include the full path for passenger-install-apache2-module, > > > didn''t work as # passenger-install-apache2-module , not found) > > > 2) script/console, script/runner, script/server - all worked fine, but > > > passenger/apache2 didn''t work until I got permissions right. > > > > Good luck, > > > > m > > > > On Mon, May 18, 2009 at 11:08 AM, karl <kpb...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > > > > Ok, > > > > > tried these things. The gems are the same. > > > > Changing permissions doesn''t do anything. Running irb as www-data > > > > works fine. Should be a rails problem since it doesn''t work with > > > > script/console... > > > > > On 18 Mai, 19:33, César <cesare.d...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > > > > Karl, > > > > > are you sure that all the gems installed in your Mac and on > > > > > Debian are exactly the same version? > > > > > You must check carefully the list of gems and versions in both > > > > > parts to go out of doubt. > > > > > > Good luck. > > > > > > Cesar > > > > > > _______________________________________________ > > > > > > Gnu/Linux count user #416024 > > > > > > Pagina personal :http://www.cesardiaz.com.ar > > > > > Mi blog :http://cesarediaz.blogspot.com > > > > > Twitter :http://twitter.com/cesarstafe > > > > > My github account:http://github.com/cesarediaz > > > > > Skype: cesarstafe
Is good know that you solved that and wich was the problem, it is a good feedback . It could help maybe another person to not do the same mistake. Cesar _______________________________________________ Gnu/Linux count user #416024 Pagina personal : http://www.cesardiaz.com.ar Mi blog : http://cesarediaz.blogspot.com Twitter : http://twitter.com/cesarstafe Github: http://github.com/cesarediaz Skype: cesarstafe
Marcin Seroczynski
2009-May-20 07:08 UTC
Re: Deploying Rails App on Debian Etch / Apache2 / Passenger
It always comes to the simplest solutions :) On May 19, 4:43 pm, karl <kpb...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> hey guys, > I''m very thankful for your help. after inspecting rubygems myself and > going down the whole way again, i figured that I accidently > capitalized the gem name :-( Now everything seems to run.. > > On 19 Mai, 16:13, pharrington <xenogene...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > > Are you using Ruby Enterprise Edition? What is PassengerRuby set to in > > your Apache configuration? Which version of Ruby is being invoked from > > the shell (run "which ruby")? > > > On May 19, 10:00 am, karl <kpb...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > > > Changed all the permissions, set path etc. but no changes yet... > > > > On 18 Mai, 22:14, Marc Byrd <dr.marc.b...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > > > > While I don''t recommend this as a long-term solution, it should help know > > > > whether this is the issue (make a backup first w/ current permissions): > > > > > chown -R www-data:www-data /usr/lib/...gems > > > > > I believe I also did chmod 777 /usr/bin/<gem_file> > > > > > I also modified the /etc/init.d/apache2 script, adding to the ENV line > > > > things like: > > > > ENV="env -i LANG=C > > > > PATH=/usr/local/bin:/usr/bin:/bin:/usr/lib/ruby/gems/1.8/gems/simple_record-1.0.2/bin:/usr/lib/ruby/gems/1.8/gems/cloud_cache-1.0.1/bin" > > > > > /etc/init.d/apache2 restart - > > > > > (The more proper way to do this [should be built into > > > > ./bin/passenger-install-apache2-module ?] is to give these files group > > > > permissions, include www-data in the group). > > > > > Other observations: > > > > 1) I had to include the full path for passenger-install-apache2-module, > > > > didn''t work as # passenger-install-apache2-module , not found) > > > > 2) script/console, script/runner, script/server - all worked fine, but > > > > passenger/apache2 didn''t work until I got permissions right. > > > > > Good luck, > > > > > m > > > > > On Mon, May 18, 2009 at 11:08 AM, karl <kpb...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > > > > > Ok, > > > > > > tried these things. The gems are the same. > > > > > Changing permissions doesn''t do anything. Running irb as www-data > > > > > works fine. Should be a rails problem since it doesn''t work with > > > > > script/console... > > > > > > On 18 Mai, 19:33, César <cesare.d...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > > > > > Karl, > > > > > > are you sure that all the gems installed in your Mac and on > > > > > > Debian are exactly the same version? > > > > > > You must check carefully the list of gems and versions in both > > > > > > parts to go out of doubt. > > > > > > > Good luck. > > > > > > > Cesar > > > > > > > _______________________________________________ > > > > > > > Gnu/Linux count user #416024 > > > > > > > Pagina personal :http://www.cesardiaz.com.ar > > > > > > Mi blog :http://cesarediaz.blogspot.com > > > > > > Twitter :http://twitter.com/cesarstafe > > > > > > My github account:http://github.com/cesarediaz > > > > > > Skype: cesarstafe