jnraine / munkiserver

Visit https://github.com/munkiserver/munkiserver for active development — this repository is no longer maintained
85 stars 27 forks source link

rake db:migrate : cannot load such file -- bundler #149

Closed laurentades closed 12 years ago

laurentades commented 12 years ago

Hi All,

Totally new to Ruby, so maybe i'm doing something really stupid here....

I'm making my way through the install steps on Mac OS X 10.7.4. When i eventually issue the command "rake db:migrate", the thing throws "cannot load such file -- bundler"

I have made sure bundler is around and it is....

I have been googled around and it looks like it might be a case sensitive file system issue but i can't see where in the files i would need to change that.. unless i'm looking totally in the wrong place...

Anyone, any idea ?

Thanks

Laurent

rickychilcott commented 12 years ago

Case sensitive partitions aren't great. Cause all sorts of issues -- I might change that!

But, other than that, are you using RVM to use ruby 1.9.3? If so, it's possible that bundler is installed for the system ruby (ver 1.8.7), but not for 1.9.3

Ricky

On Jul 18, 2012, at 12:58 AM, laurentades wrote:

Hi All,

Totally new to Ruby, so maybe i'm doing something really stupid here....

I'm making my way through the install steps on Mac OS X 10.7.4. When i eventually issue the command "rake db:migrate", the thing throws "cannot load such file -- bundler"

I have made sure bundler is around and it is....

I have been googled around and it looks like it might be a case sensitive file system issue but i can't see where in the files i would need to change that.. unless i'm looking totally in the wrong place...

Anyone, any idea ?

Thanks

Laurent


Reply to this email directly or view it on GitHub: https://github.com/jnraine/munkiserver/issues/149

jnraine commented 12 years ago

Try running gem install bundler first. If you are using your system Ruby, run sudo gem install bundler.

What install doc are you working through? I'd recommend this one for OS X: https://github.com/jnraine/munkiserver/wiki/Setup-on-OS-X

Best of luck with your install!

laurentades commented 12 years ago

Yes working through that doc. May i ask do we need to use 1.9.3-p0 ? Would 1.9.3-p125 work as well ?

jnraine commented 12 years ago

p125 might work. When I attempted to use p194, I kept getting seg faults when running the app. So long as the app runs, you can use p125.

rickychilcott commented 12 years ago

p125 will work fine. I use that locally for development -- it's bound to be the fastest, most bug free version of 1.9.3.

It's hard to keep docs such as this up-to-date and accurate for people.

Ricky Chilcott

On Jul 18, 2012, at 1:49 PM, laurentadesreply@reply.github.com wrote:

Yes working through that doc. May i ask do we need to use 1.9.3-p0 ? Would 1.9.3-p125 work as well ?


Reply to this email directly or view it on GitHub: https://github.com/jnraine/munkiserver/issues/149#issuecomment-7076396

laurentades commented 12 years ago

Guys, as i see you are online an answering quick (...!), i'll just fire a few more quezies...

Should i be worried of the following message once p125 is installed

Ruby 'ruby-1.9.3-p125' was build using clang - but it's not (fully) supported, expect errors.

Was getting the same with p0 anyway....

rickychilcott commented 12 years ago

I've had to wrestle with that several times -

I wouldn't worry about it unless it causes issues. This bug on GitHub shows the history https://github.com/wayneeseguin/rvm/issues/763

Ricky Chilcott

On Jul 18, 2012, at 1:56 PM, laurentadesreply@reply.github.com wrote:

Guys, as i see you are online an answering quick (...!), i'll just fire a few more quezies...

Should i be worried of the following message once p125 is installed

Ruby 'ruby-1.9.3-p125' was build using clang - but it's not (fully) supported, expect errors.

Was getting the same with p0 anyway....


Reply to this email directly or view it on GitHub: https://github.com/jnraine/munkiserver/issues/149#issuecomment-7076626

laurentades commented 12 years ago

Ricky, back to my original problem, i have the feeling in deed that 1.8.7 is standing in the way.... but not sure how to get rid of it....

Would rvm remove 1.8.7 be enough ?

rickychilcott commented 12 years ago

I'd recommend NOT removing system ruby.

try this:

rvm --default use 1.9.3 #this will set the default to 1.9.3 gem install bundler #my guess is RVM already installed bundler bundle #this will install all gems needed rake db:migrate #or rake db:migrate RAILS_ENV=production

Ricky Chilcott

On Jul 18, 2012, at 2:25 PM, laurentadesreply@reply.github.com wrote:

Ricky, back to my original problem, i have the feeling in deed that 1.8.7 is standing in the way.... but not sure how to get rid of it....

Would rvm remove 1.8.7 be enough ?


Reply to this email directly or view it on GitHub: https://github.com/jnraine/munkiserver/issues/149#issuecomment-7077487

rickychilcott commented 12 years ago

something to check before trying this

ruby -v

does it give you 1.8.7 or 1.9.3?

Ricky Chilcott

On Jul 18, 2012, at 2:25 PM, laurentadesreply@reply.github.com wrote:

Ricky, back to my original problem, i have the feeling in deed that 1.8.7 is standing in the way.... but not sure how to get rid of it....

Would rvm remove 1.8.7 be enough ?


Reply to this email directly or view it on GitHub: https://github.com/jnraine/munkiserver/issues/149#issuecomment-7077487

laurentades commented 12 years ago

ok... i ran the command to remove 1.8.7 before you advised not to...! ... but it appeared to be "already non existent"... so that should not be an issue....

but... ruby -v goes :

ruby 1.9.3p194 (2012-04-20 revision 35410) [x86_64-darwin11.4.0]

aha !!!

don't ask me how 1.9.4 got there ! Default for 10.7.4 ?

laurentades commented 12 years ago

So, now the question is whether i keep p194 and bring everything else up to consistency with that... or.... bring everything down consistent with p125..... if that actually makes sense...

?

rickychilcott commented 12 years ago

Yes default to 194 and then make sure any special configs that reference 125 to the new version.

Sent from my iPhone

On Jul 18, 2012, at 2:38 PM, laurentadesreply@reply.github.com wrote:

ok... i ran the command to remove 1.8.7 before you advised not to...! ... but it appeared to be "already non existent"... so that should not be an issue....

but... ruby -v goes :

ruby 1.9.3p194 (2012-04-20 revision 35410) [x86_64-darwin11.4.0]

aha !!!

don't ask me how 1.9.4 got there ! Default for 1.9.4 ?


Reply to this email directly or view it on GitHub: https://github.com/jnraine/munkiserver/issues/149#issuecomment-7077916

laurentades commented 12 years ago

..no luck..

A few things that might be worth noting :

KiAdiMundi:munkiserver laurentades$ sudo rake db:migrate --trace rake aborted! cannot load such file -- bundler /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in require' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:inrequire' /Library/WebServer/Documents/munkiserver/config/boot.rb:6:in rescue in <top (required)>' /Library/WebServer/Documents/munkiserver/config/boot.rb:2:in<top (required)>' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in require' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:inrequire' /Library/WebServer/Documents/munkiserver/config/application.rb:1:in <top (required)>' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:inrequire' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in require' /Library/WebServer/Documents/munkiserver/Rakefile:4:in<top (required)>' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/rake/rake_module.rb:25:in load' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/rake/rake_module.rb:25:inload_rakefile' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/rake/application.rb:501:in raw_load_rakefile' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/rake/application.rb:82:inblock in load_rakefile' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/rake/application.rb:133:in standard_exception_handling' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/rake/application.rb:81:inload_rakefile' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/rake/application.rb:65:in block in run' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/rake/application.rb:133:instandard_exception_handling' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/rake/application.rb:63:in run' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/gems/1.9.1/gems/rake-0.9.2.2/bin/rake:32:in<top (required)>' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/bin/rake:19:in load' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/bin/rake:19:in

' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/bin/ruby_noexec_wrapper:14:in eval' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/bin/ruby_noexec_wrapper:14:in
'

Cordialement / Best regards


Laurent Adès Managing Director  Certified Associate Mac Integration 10.7

Paoma Ltd |  Authorised Reseller |  Solution Expert |  Authorised Service Provider | www.paoma.mu | BRN: C06067070 T:+230 670 23 68 | M:+230 253 05 40 | F:+230 670 25 82 | Please consider the environment before printing this e-mail.

On 18Jul, 2012, at 11:26 PM, Ricky Chilcott wrote:

Yes default to 194 and then make sure any special configs that reference 125 to the new version.

Sent from my iPhone

On Jul 18, 2012, at 2:38 PM, laurentadesreply@reply.github.com wrote:

ok... i ran the command to remove 1.8.7 before you advised not to...! ... but it appeared to be "already non existent"... so that should not be an issue....

but... ruby -v goes :

ruby 1.9.3p194 (2012-04-20 revision 35410) [x86_64-darwin11.4.0]

aha !!!

don't ask me how 1.9.4 got there ! Default for 1.9.4 ?


Reply to this email directly or view it on GitHub: https://github.com/jnraine/munkiserver/issues/149#issuecomment-7077916


Reply to this email directly or view it on GitHub: https://github.com/jnraine/munkiserver/issues/149#issuecomment-7079211

jnraine commented 12 years ago

Hmm, seems as though you are using system ruby and not one installed by rvm. What do you get when you type which ruby?

On Wednesday, 18 July, 2012 at 7:18 PM, laurentades wrote:

..no luck..

A few things that might be worth noting :

  • I can't run "gem install bundler" without going sudo. Your install guide does mention not ti use sudo for rvm install.. does it matter here ?
  • I can' run "rake db:migrate" eitheir without going sudo….
  • ruby - v : ruby 1.9.3p194 (2012-04-20 revision 35410) [x86_64-darwin11.4.0]
  • Here is the full trace of the eror i'm getting :

KiAdiMundi:munkiserver laurentades$ sudo rake db:migrate --trace rake aborted! cannot load such file -- bundler /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in require' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:inrequire' /Library/WebServer/Documents/munkiserver/config/boot.rb:6:in rescue in <top (required)>' /Library/WebServer/Documents/munkiserver/config/boot.rb:2:in<top (required)>' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in require' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:inrequire' /Library/WebServer/Documents/munkiserver/config/application.rb:1:in <top (required)>' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:inrequire' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in require' /Library/WebServer/Documents/munkiserver/Rakefile:4:in<top (required)>' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/rake/rake_module.rb:25:in load' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/rake/rake_module.rb:25:inload_rakefile' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/rake/application.rb:501:in raw_load_rakefile' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/rake/application.rb:82:inblock in load_rakefile' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/rake/application.rb:133:in standard_exception_handling' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/rake/application.rb:81:inload_rakefile' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/rake/application.rb:65:in block in run' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/rake/application.rb:133:instandard_exception_handling' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/rake/application.rb:63:in run' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/gems/1.9.1/gems/rake-0.9.2.2/bin/rake:32:in<top (required)>' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/bin/rake:19:in load' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/bin/rake:19:in

' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/bin/ruby_noexec_wrapper:14:in eval' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/bin/ruby_noexec_wrapper:14:in
'

Cordialement / Best regards


Laurent Adès Managing Director  Certified Associate Mac Integration 10.7

Paoma Ltd |  Authorised Reseller |  Solution Expert |  Authorised Service Provider | www.paoma.mu | BRN: C06067070 T:+230 670 23 68 | M:+230 253 05 40 | F:+230 670 25 82 | Please consider the environment before printing this e-mail.

On 18Jul, 2012, at 11:26 PM, Ricky Chilcott wrote:

Yes default to 194 and then make sure any special configs that reference 125 to the new version.

Sent from my iPhone

On Jul 18, 2012, at 2:38 PM, laurentadesreply@reply.github.com wrote:

ok... i ran the command to remove 1.8.7 before you advised not to...! ... but it appeared to be "already non existent"... so that should not be an issue....

but... ruby -v goes :

ruby 1.9.3p194 (2012-04-20 revision 35410) [x86_64-darwin11.4.0]

aha !!!

don't ask me how 1.9.4 got there ! Default for 1.9.4 ?


Reply to this email directly or view it on GitHub: https://github.com/jnraine/munkiserver/issues/149#issuecomment-7077916


Reply to this email directly or view it on GitHub: https://github.com/jnraine/munkiserver/issues/149#issuecomment-7079211


Reply to this email directly or view it on GitHub: https://github.com/jnraine/munkiserver/issues/149#issuecomment-7088142

laurentades commented 12 years ago

Yes, that's exactly what it looks like

which ruby : /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/bin/ruby

So, now i am confused….

jnraine commented 12 years ago

If you need to add sudo to your gem install, it's not using the gem command for the rvm ruby. You should never need to add sudo when running rake db:migrate unless you don't have permission to edit your SQLite db.

Try this: cd path/to/your/app rvm use ruby-1.9.3-p194 which gem which ruby which rake which rails gem install bundler bundle install rake --trace db:migrate

If all works, awesome. If not, can you copy/paste the output?

On Wednesday, 18 July, 2012 at 8:59 PM, laurentades wrote:

Yes, that's exactly what it looks like

which ruby : /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/bin/ruby

So, now i am confused….


Reply to this email directly or view it on GitHub: https://github.com/jnraine/munkiserver/issues/149#issuecomment-7089184

laurentades commented 12 years ago

rvm use ruby-1.9.3-p194

Using /Users/laurentades/.rvm/gems/ruby-1.9.3-p194

which gem

/Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/bin/gem

which ruby

/Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/bin/ruby

which rake

/Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/bin/rake

which rails

/Users/laurentades/.rvm/gems/ruby-1.9.3-p194/bin/rails

gem install bundler

ERROR: While executing gem ... (Errno::EPERM) Operation not permitted - /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/bundler-1.1.5/.gitignore

sudo gem install bundler

Successfully installed bundler-1.1.5 1 gem installed Installing ri documentation for bundler-1.1.5... Installing RDoc documentation for bundler-1.1.5...

bundle install

Using rake (0.9.2.2) Using i18n (0.6.0) Using multi_json (1.1.0) Using activesupport (3.2.2) Using builder (3.0.0) Using activemodel (3.2.2) Using erubis (2.7.0) Using journey (1.0.3) Using rack (1.4.1) Using rack-cache (1.2) Using rack-test (0.6.1) Using hike (1.2.1) Using tilt (1.3.3) Using sprockets (2.1.2) Using actionpack (3.2.2) Using mime-types (1.17.2) Using polyglot (0.3.3) Using treetop (1.4.10) Using mail (2.4.4) Using actionmailer (3.2.2) Using arel (3.0.2) Using tzinfo (0.3.32) Using activerecord (3.2.2) Using activeresource (3.2.2) Using addressable (2.2.8) Using cancan (1.6.7) Using nokogiri (1.5.2) Using ffi (1.0.11) Using childprocess (0.3.2) Using libwebsocket (0.1.3) Using rubyzip (0.9.8) Using selenium-webdriver (2.22.2) Using xpath (0.1.4) Using capybara (1.1.2) Using chronic (0.6.7) Using client_side_validations (3.1.4) Using cocaine (0.2.1) Using coderay (1.0.6) Using coffee-script-source (1.2.0) Using execjs (1.3.0) Using coffee-script (2.2.0) Using rack-ssl (1.3.2) Using json (1.6.5) Using rdoc (3.12) Using thor (0.14.6) Using railties (3.2.2) Using coffee-rails (3.2.2) Using crack (0.3.1) Using diff-lcs (1.1.3) Using dynamic_form (1.1.4) Using factory_girl (3.3.0) Using highcharts-rails (2.1.9) Using highline (1.6.11) Using jquery-rails (2.0.1) Using libv8 (3.3.10.4) Using method_source (0.7.1) Using newrelic_rpm (3.3.2) Using paperclip (2.7.0) Using plist (3.1.0) Using slop (2.4.4) Using pry (0.9.9.6) Using pry-rails (0.1.6) Using bundler (1.1.5) Using rails (3.2.2) Using ruby-graphviz (0.9.21) Using rails-erd (0.4.5) Using rest-client (1.6.7) Using rspec-core (2.10.1) Using rspec-expectations (2.10.0) Using rspec-mocks (2.10.1) Using rspec (2.10.0) Using rspec-rails (2.10.1) Using sass (3.1.15) Using sass-rails (3.2.4) Using sequel (3.20.0) Using sinatra (1.0) Using sqlite3 (1.3.5) Using sqlite3-ruby (1.3.3) Using taps (0.3.23) Using textmate_backtracer (1.0.0) Using therubyracer (0.9.10) Using uglifier (1.2.3) Using vcr (2.2.0) Using webmock (1.8.7) Using whenever (0.7.3) Using will_paginate (3.0.3) Your bundle is complete! Use bundle show [gemname] to see where a bundled gem is installed.

rake --trace db:migrate

Permission denied - /Library/WebServer/Documents/munkiserver/packages /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/fileutils.rb:247:in mkdir' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/fileutils.rb:247:infu_mkdir' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/fileutils.rb:221:in block (2 levels) in mkdir_p' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/fileutils.rb:219:inreverse_each' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/fileutils.rb:219:in block in mkdir_p' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/fileutils.rb:205:ineach' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/fileutils.rb:205:in mkdir_p' /Library/WebServer/Documents/munkiserver/config/application.rb:50:inclass:Application' /Library/WebServer/Documents/munkiserver/config/application.rb:13:in <module:Munki>' /Library/WebServer/Documents/munkiserver/config/application.rb:12:in<top (required)>' /Library/WebServer/Documents/munkiserver/Rakefile:4:in require' /Library/WebServer/Documents/munkiserver/Rakefile:4:in<top (required)>' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/rake_module.rb:25:in load' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/rake_module.rb:25:inload_rakefile' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:501:in raw_load_rakefile' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:82:inblock in load_rakefile' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:133:in standard_exception_handling' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:81:inload_rakefile' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:65:in block in run' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:133:instandard_exception_handling' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:63:in run' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/bin/rake:33:in<top (required)>' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/bin/rake:19:in load' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/bin/rake:19:in

' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/bin/ruby_noexec_wrapper:14:in eval' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/bin/ruby_noexec_wrapper:14:in
'

sudo rake --trace db:migrate

rake aborted! cannot load such file -- bundler /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in require' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:inrequire' /Library/WebServer/Documents/munkiserver/config/boot.rb:6:in rescue in <top (required)>' /Library/WebServer/Documents/munkiserver/config/boot.rb:2:in<top (required)>' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in require' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:inrequire' /Library/WebServer/Documents/munkiserver/config/application.rb:1:in <top (required)>' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:inrequire' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in require' /Library/WebServer/Documents/munkiserver/Rakefile:4:in<top (required)>' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/rake/rake_module.rb:25:in load' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/rake/rake_module.rb:25:inload_rakefile' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/rake/application.rb:501:in raw_load_rakefile' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/rake/application.rb:82:inblock in load_rakefile' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/rake/application.rb:133:in standard_exception_handling' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/rake/application.rb:81:inload_rakefile' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/rake/application.rb:65:in block in run' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/rake/application.rb:133:instandard_exception_handling' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/rake/application.rb:63:in run' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/gems/1.9.1/gems/rake-0.9.2.2/bin/rake:32:in<top (required)>' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/bin/rake:19:in load' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/bin/rake:19:in

' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/bin/ruby_noexec_wrapper:14:in eval' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/bin/ruby_noexec_wrapper:14:in
'

laurentades commented 12 years ago

Following your comments on sudo usage, i've done the following change :

sudo chown -R root:admin munkiserver/ sudo chmod 775 munkiserver/

and now the output is changing.....

* Invoke db:migrate (first_time) * Invoke environment (first_time) ** Execute environment Cannot find or read /Library/WebServer/Documents/munkiserver/config/newrelic.yml rake aborted! unable to open database file /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/sqlite3_adapter.rb:26:in initialize' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/sqlite3_adapter.rb:26:innew' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/sqlite3_adapter.rb:26:in sqlite3_connection' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:277:innew_connection' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:287:in checkout_new_connection' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:235:inblock (2 levels) in checkout' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:230:in loop' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:230:inblock in checkout' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/monitor.rb:211:in mon_synchronize' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:229:incheckout' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:95:in connection' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:374:inretrieve_connection' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_specification.rb:168:in retrieve_connection' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_specification.rb:142:inconnection' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/model_schema.rb:308:in clear_cache!' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/railtie.rb:91:inblock (2 levels) in class:Railtie' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activesupport-3.2.2/lib/active_support/callbacks.rb:418:in _run__195615079546567580__prepare__4042091861988625410__callbacks' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activesupport-3.2.2/lib/active_support/callbacks.rb:405:in__run_callback' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activesupport-3.2.2/lib/active_support/callbacks.rb:385:in _run_prepare_callbacks' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activesupport-3.2.2/lib/active_support/callbacks.rb:81:inrun_callbacks' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/actionpack-3.2.2/lib/action_dispatch/middleware/reloader.rb:74:in prepare!' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/actionpack-3.2.2/lib/action_dispatch/middleware/reloader.rb:48:inprepare!' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.2/lib/rails/application/finisher.rb:47:in block in <module:Finisher>' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.2/lib/rails/initializable.rb:30:ininstance_exec' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.2/lib/rails/initializable.rb:30:in run' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.2/lib/rails/initializable.rb:55:inblock in run_initializers' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.2/lib/rails/initializable.rb:54:in each' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.2/lib/rails/initializable.rb:54:inrun_initializers' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.2/lib/rails/application.rb:136:in initialize!' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.2/lib/rails/railtie/configurable.rb:30:inmethod_missing' /Library/WebServer/Documents/munkiserver/config/environment.rb:5:in <top (required)>' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activesupport-3.2.2/lib/active_support/dependencies.rb:251:inrequire' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activesupport-3.2.2/lib/active_support/dependencies.rb:251:in block in require' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activesupport-3.2.2/lib/active_support/dependencies.rb:236:inload_dependency' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activesupport-3.2.2/lib/active_support/dependencies.rb:251:in require' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.2/lib/rails/application.rb:103:inrequire_environment!' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.2/lib/rails/application.rb:292:in block (2 levels) in initialize_tasks' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:205:incall' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:205:in block in execute' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:200:ineach' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:200:in execute' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:158:inblock in invoke_with_call_chain' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/monitor.rb:211:in mon_synchronize' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:151:ininvoke_with_call_chain' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:176:in block in invoke_prerequisites' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:174:ineach' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:174:in invoke_prerequisites' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:157:inblock in invoke_with_call_chain' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/monitor.rb:211:in mon_synchronize' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:151:ininvoke_with_call_chain' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:144:in invoke' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:116:ininvoke_task' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:94:in block (2 levels) in top_level' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:94:ineach' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:94:in block in top_level' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:133:instandard_exception_handling' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:88:in top_level' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:66:inblock in run' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:133:in standard_exception_handling' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:63:inrun' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/bin/rake:33:in <top (required)>' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/bin/rake:19:inload' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/bin/rake:19:in <main>' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/bin/ruby_noexec_wrapper:14:ineval' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/bin/ruby_noexec_wrapper:14:in `

' Tasks: TOP => db:migrate => environment

rickychilcott commented 12 years ago

A few things to try:

what happens when you type

sudo which ruby

is there a file named [munkiserver-directory]/db/development.sqlite3?

If not, first try rake db:create, then rake db:migrate.

Lasly, what is the output of rvm use 1.9.3-p194 and gem list?

Ricky

On Jul 19, 2012, at 4:52 AM, laurentades wrote:

Following your comments on sudo usage, i've done the following change :

sudo chown -R root:admin munkiserver/ sudo chmod 775 munkiserver/

and now the output is changing.....

* Invoke db:migrate (first_time) * Invoke environment (first_time) ** Execute environment Cannot find or read /Library/WebServer/Documents/munkiserver/config/newrelic.yml rake aborted! unable to open database file /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/sqlite3_adapter.rb:26:in initialize' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/sqlite3_adapter.rb:26:innew' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/sqlite3_adapter.rb:26:in sqlite3_connection' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:277:innew_connection' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:287:in checkout_new_connection' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:235:inblock (2 levels) in checkout' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:230:in loop' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:230:inblock in checkout' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/monitor.rb:211:in mon_synchronize' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:229:incheckout' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:95:in connection' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:374:inretrieve_connection' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_specification.rb:168:in retrieve_connection' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_specification.rb:142:inconnection' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/model_schema.rb:308:in clear_cache!' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/railtie.rb:91:inblock (2 levels) in class:Railtie' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activesupport-3.2.2/lib/active_support/callbacks.rb:418:in _run__195615079546567580__prepare__4042091861988625410__callbacks' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activesupport-3.2.2/lib/active_support/callbacks.rb:405:in__run_callback' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activesupport-3.2.2/lib/active_support/callbacks.rb:385:in _run_prepare_callbacks' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activesupport-3.2.2/lib/active_support/callbacks.rb:81:inrun_callbacks' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/actionpack-3.2.2/lib/action_dispatch/middleware/reloader.rb:74:in prepare!' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/actionpack-3.2.2/lib/action_dispatch/middleware/reloader.rb:48:inprepare!' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.2/lib/rails/application/finisher.rb:47:in block in <module:Finisher>' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.2/lib/rails/initializable.rb:30:ininstance_exec' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.2/lib/rails/initializable.rb:30:in run' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.2/lib/rails/initializable.rb:55:inblock in run_initializers' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.2/lib/rails/initializable.rb:54:in each' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.2/lib/rails/initializable.rb:54:inrun_initializers' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.2/lib/rails/application.rb:136:in initialize!' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.2/lib/rails/railtie/configurable.rb:30:inmethod_missing' /Library/WebServer/Documents/munkiserver/config/environment.rb:5:in <top (required)>' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activesupport-3.2.2/lib/active_support/dependencies.rb:251:inrequire' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activesupport-3.2.2/lib/active_support/dependencies.rb:251:in block in require' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activesupport-3.2.2/lib/active_support/dependencies.rb:236:inload_dependency' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activesupport-3.2.2/lib/active_support/dependencies.rb:251:in require' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.2/lib/rails/application.rb:103:inrequire_environment!' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.2/lib/rails/application.rb:292:in block (2 levels) in initialize_tasks' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:205:incall' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:205:in block in execute' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:200:ineach' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:200:in execute' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:158:inblock in invoke_with_call_chain' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/monitor.rb:211:in mon_synchronize' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:151:ininvoke_with_call_chain' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:176:in block in invoke_prerequisites' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:174:ineach' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:174:in invoke_prerequisites' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:157:inblock in invoke_with_call_chain' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/monitor.rb:211:in mon_synchronize' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:151:ininvoke_with_call_chain' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:144:in invoke' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:116:ininvoke_task' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:94:in block (2 levels) in top_level' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:94:ineach' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:94:in block in top_level' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:133:instandard_exception_handling' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:88:in top_level' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:66:inblock in run' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:133:in standard_exception_handling' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:63:inrun' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/bin/rake:33:in <top (required)>' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/bin/rake:19:inload' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/bin/rake:19:in <main>' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/bin/ruby_noexec_wrapper:14:ineval' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/bin/ruby_noexec_wrapper:14:in `

' Tasks: TOP => db:migrate => environment


Reply to this email directly or view it on GitHub: https://github.com/jnraine/munkiserver/issues/149#issuecomment-7092926

jnraine commented 12 years ago

Try changing the ownership to your user for the app directory and the entire ~/.rvm directory. Seems like permissions are still a bit off.

On Thursday, 19 July, 2012 at 1:52 AM, laurentades wrote:

Following your comments on sudo usage, i've done the following change :

sudo chown -R root:admin munkiserver/ sudo chmod 775 munkiserver/

and now the output is changing.....

* Invoke db:migrate (first_time) * Invoke environment (first_time) ** Execute environment Cannot find or read /Library/WebServer/Documents/munkiserver/config/newrelic.yml rake aborted! unable to open database file /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/sqlite3_adapter.rb:26:in initialize' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/sqlite3_adapter.rb:26:innew' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/sqlite3_adapter.rb:26:in sqlite3_connection' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:277:innew_connection' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:287:in checkout_new_connection' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:235:inblock (2 levels) in checkout' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:230:in loop' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:230:inblock in checkout' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/monitor.rb:211:in mon_synchronize' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:229:incheckout' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:95:in connection' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:374:inretrieve_connection' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_specification.rb:168:in retrieve_connection' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/connection_adapters/abstract/connection_specification.rb:142:inconnection' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/model_schema.rb:308:in clear_cache!' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activerecord-3.2.2/lib/active_record/railtie.rb:91:inblock (2 levels) in class:Railtie' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activesupport-3.2.2/lib/active_support/callbacks.rb:418:in _run__195615079546567580__prepare__4042091861988625410__callbacks' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activesupport-3.2.2/lib/active_support/callbacks.rb:405:in__run_callback' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activesupport-3.2.2/lib/active_support/callbacks.rb:385:in _run_prepare_callbacks' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activesupport-3.2.2/lib/active_support/callbacks.rb:81:inrun_callbacks' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/actionpack-3.2.2/lib/action_dispatch/middleware/reloader.rb:74:in prepare!' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/actionpack-3.2.2/lib/action_dispatch/middleware/reloader.rb:48:inprepare!' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.2/lib/rails/application/finisher.rb:47:in block in <module:Finisher>' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.2/lib/rails/initializable.rb:30:ininstance_exec' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.2/lib/rails/initializable.rb:30:in run' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.2/lib/rails/initializable.rb:55:inblock in run_initializers' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.2/lib/rails/initializable.rb:54:in each' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.2/lib/rails/initializable.rb:54:inrun_initializers' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.2/lib/rails/application.rb:136:in initialize!' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.2/lib/rails/railtie/configurable.rb:30:inmethod_missing' /Library/WebServer/Documents/munkiserver/config/environment.rb:5:in <top (required)>' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activesupport-3.2.2/lib/active_support/dependencies.rb:251:inrequire' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activesupport-3.2.2/lib/active_support/dependencies.rb:251:in block in require' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activesupport-3.2.2/lib/active_support/dependencies.rb:236:inload_dependency' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/activesupport-3.2.2/lib/active_support/dependencies.rb:251:in require' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.2/lib/rails/application.rb:103:inrequire_environment!' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/gems/railties-3.2.2/lib/rails/application.rb:292:in block (2 levels) in initialize_tasks' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:205:incall' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:205:in block in execute' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:200:ineach' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:200:in execute' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:158:inblock in invoke_with_call_chain' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/monitor.rb:211:in mon_synchronize' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:151:ininvoke_with_call_chain' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:176:in block in invoke_prerequisites' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:174:ineach' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:174:in invoke_prerequisites' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:157:inblock in invoke_with_call_chain' /Users/laurentades/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/monitor.rb:211:in mon_synchronize' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:151:ininvoke_with_call_chain' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/task.rb:144:in invoke' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:116:ininvoke_task' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:94:in block (2 levels) in top_level' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:94:ineach' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:94:in block in top_level' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:133:instandard_exception_handling' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:88:in top_level' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:66:inblock in run' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:133:in standard_exception_handling' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/lib/rake/application.rb:63:inrun' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/gems/rake-0.9.2.2/bin/rake:33:in <top (required)>' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/bin/rake:19:inload' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194@global/bin/rake:19:in <main>' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/bin/ruby_noexec_wrapper:14:ineval' /Users/laurentades/.rvm/gems/ruby-1.9.3-p194/bin/ruby_noexec_wrapper:14:in `

' Tasks: TOP => db:migrate => environment


Reply to this email directly or view it on GitHub: https://github.com/jnraine/munkiserver/issues/149#issuecomment-7092926

laurentades commented 12 years ago

It is now working (!!!) : just managed to fire up http://localhost:3000 to the login screen and dashboard....

Bottom line, a chown -R to change ownership of munkiserver directory to my user solved the whole issue. What i'm not clear on yet though is whether it wa a version issue at all.

What would be the way forward to help sorting this out ? Can i help ?

jnraine commented 12 years ago

Glad to hear it! I believe the setup instructions are sound (let me know if you find otherwise), but in this case perhaps a misplaced sudo caused some permissions to be set incorrectly.

jelockwood commented 10 years ago

I have had various problems so far installing MunkiServer which I have so far been successfully resolving. I thought however it would be worth mentioning them here.

The command rake bootstrap:all RAILS_ENV=production was failing it was complaining it did not have permission to mkdir /usr/local/munkiserver/../munkiserver_assets this turned out to be because the current login did not have write permission to /usr/local although it does have permission to write to /usr/local/munkiserver and /usr/local/rvm I could have resolved this by altering the permissions on /usr/local but instead manually created that directory.

An earlier issue was that while it created the rvm group it did not automatically add my current login to that group nor did any instructions advise doing so manually.

Another issue was resolved by doing sudo ln -s /usr/local/mysql/lib/libmysqlclient.18.dylib /usr/lib/libmysqlclient.18.dylib see http://stackoverflow.com/questions/10557507/rails-mysql-on-osx-library-not-loaded-libmysqlclient-18-dylib

I also found that for me at least with OS X 10.8.5 that I could not get rvm to successfully install and build ruby 1.9.3-p0 I did find 1.9.3-p488 worked. I therefore went with that and modified /usr/local/munkiserver/.rvmrc to match.