Rake db:migrate fails: cannot load such file -- MiqBlockDevOps


#1

I’m on my last steps of finishing building manageiq from the source code.
The step just before last is: rake db:migrate
When I run this step I get this error:

/home/eugene/.rvm/gems/ruby-2.0.0-p598/bin/rake
eugene@3b4d8a92ac5d:~/manageiq/vmdb$ rake db:migrate
rake aborted!
LoadError: cannot load such file -- MiqBlockDevOps
/home/eugene/.rvm/gems/ruby-2.0.0-p598/bundler/gems/rails-8f014fba21f9/activesupport/lib/active_support/dependencies.rb:251:in `require'
/home/eugene/.rvm/gems/ruby-2.0.0-p598/bundler/gems/rails-8f014fba21f9/activesupport/lib/active_support/dependencies.rb:251:in `block in require'
/home/eugene/.rvm/gems/ruby-2.0.0-p598/bundler/gems/rails-8f014fba21f9/activesupport/lib/active_support/dependencies.rb:236:in `load_dependency'
/home/eugene/.rvm/gems/ruby-2.0.0-p598/bundler/gems/rails-8f014fba21f9/activesupport/lib/active_support/dependencies.rb:251:in `require'
/home/eugene/manageiq/lib/disk/modules/MiqLargeFile.rb:11:in `<top (required)>'
/home/eugene/.rvm/gems/ruby-2.0.0-p598/bundler/gems/rails-8f014fba21f9/activesupport/lib/active_support/dependencies.rb:251:in `require'
/home/eugene/.rvm/gems/ruby-2.0.0-p598/bundler/gems/rails-8f014fba21f9/activesupport/lib/active_support/dependencies.rb:251:in `block in require'
/home/eugene/.rvm/gems/ruby-2.0.0-p598/bundler/gems/rails-8f014fba21f9/activesupport/lib/active_support/dependencies.rb:236:in `load_dependency'
/home/eugene/.rvm/gems/ruby-2.0.0-p598/bundler/gems/rails-8f014fba21f9/activesupport/lib/active_support/dependencies.rb:251:in `require'
/home/eugene/manageiq/lib/util/extensions/miq-file.rb:7:in `<top (required)>'
/home/eugene/.rvm/gems/ruby-2.0.0-p598/bundler/gems/rails-8f014fba21f9/activesupport/lib/active_support/dependencies.rb:251:in `require'
/home/eugene/.rvm/gems/ruby-2.0.0-p598/bundler/gems/rails-8f014fba21f9/activesupport/lib/active_support/dependencies.rb:251:in `block in require'
/home/eugene/.rvm/gems/ruby-2.0.0-p598/bundler/gems/rails-8f014fba21f9/activesupport/lib/active_support/dependencies.rb:236:in `load_dependency'
/home/eugene/.rvm/gems/ruby-2.0.0-p598/bundler/gems/rails-8f014fba21f9/activesupport/lib/active_support/dependencies.rb:251:in `require'
/home/eugene/manageiq/lib/util/miq-extensions.rb:5:in `block in <top (required)>'
/home/eugene/manageiq/lib/util/miq-extensions.rb:5:in `glob'
/home/eugene/manageiq/lib/util/miq-extensions.rb:5:in `<top (required)>'
/home/eugene/.rvm/gems/ruby-2.0.0-p598/bundler/gems/rails-8f014fba21f9/activesupport/lib/active_support/dependencies.rb:251:in `require'
/home/eugene/.rvm/gems/ruby-2.0.0-p598/bundler/gems/rails-8f014fba21f9/activesupport/lib/active_support/dependencies.rb:251:in `block in require'
/home/eugene/.rvm/gems/ruby-2.0.0-p598/bundler/gems/rails-8f014fba21f9/activesupport/lib/active_support/dependencies.rb:236:in `load_dependency'
/home/eugene/.rvm/gems/ruby-2.0.0-p598/bundler/gems/rails-8f014fba21f9/activesupport/lib/active_support/dependencies.rb:251:in `require'
/home/eugene/manageiq/vmdb/lib/vmdb_helper.rb:1:in `<top (required)>'
/home/eugene/.rvm/gems/ruby-2.0.0-p598/bundler/gems/rails-8f014fba21f9/activesupport/lib/active_support/dependencies.rb:251:in `require'
/home/eugene/.rvm/gems/ruby-2.0.0-p598/bundler/gems/rails-8f014fba21f9/activesupport/lib/active_support/dependencies.rb:251:in `block in require'
/home/eugene/.rvm/gems/ruby-2.0.0-p598/bundler/gems/rails-8f014fba21f9/activesupport/lib/active_support/dependencies.rb:236:in `load_dependency'
/home/eugene/.rvm/gems/ruby-2.0.0-p598/bundler/gems/rails-8f014fba21f9/activesupport/lib/active_support/dependencies.rb:251:in `require'
/home/eugene/manageiq/vmdb/lib/vmdb/logging.rb:2:in `<top (required)>'
/home/eugene/.rvm/gems/ruby-2.0.0-p598/bundler/gems/rails-8f014fba21f9/activesupport/lib/active_support/dependencies.rb:251:in `require'
/home/eugene/.rvm/gems/ruby-2.0.0-p598/bundler/gems/rails-8f014fba21f9/activesupport/lib/active_support/dependencies.rb:251:in `block in require'
/home/eugene/.rvm/gems/ruby-2.0.0-p598/bundler/gems/rails-8f014fba21f9/activesupport/lib/active_support/dependencies.rb:236:in `load_dependency'
/home/eugene/.rvm/gems/ruby-2.0.0-p598/bundler/gems/rails-8f014fba21f9/activesupport/lib/active_support/dependencies.rb:251:in `require'
/home/eugene/manageiq/vmdb/config/application.rb:99:in `<class:Application>'
/home/eugene/manageiq/vmdb/config/application.rb:14:in `<module:Vmdb>'
/home/eugene/manageiq/vmdb/config/application.rb:13:in `<top (required)>'
/home/eugene/manageiq/vmdb/Rakefile:5:in `require'
/home/eugene/manageiq/vmdb/Rakefile:5:in `<top (required)>'
/home/eugene/.rvm/gems/ruby-2.0.0-p598/bin/ruby_executable_hooks:15:in `eval'
/home/eugene/.rvm/gems/ruby-2.0.0-p598/bin/ruby_executable_hooks:15:in `<main>'
(See full trace by running task with --trace)

What can I do to overcome this step?


#2

It looks like the directions are missing some steps. The directions should very closely mirror the recipe found in the %post section of the kickstart used to build the centos appliances. Note, this kickstart changes fairly often so please do update the documentation to reflect these changes and feel free to ask if you have any questions. We can point you to the pull request that made the changes.

Here is the beginning of the %post section.

Specifically, in the kickstart, we run cfme-setup.sh which does many things including the compiling of the c extensions. The error you are seeing is probably because the MiqBlockDevOps shared object wasn’t compiled.

See: rake build:shared_objects --trace found here

To get around this issue, you’ll need to run that from the location you checked out miq, it appears to be ~/manageiq

If you run into further issues, please review the base.ks.erb from the code you are using as it may help you resolve the issue.

Thanks!


#3

Thank you very much for such a detail answer! I since was able to complete all steps using CentOS 6.6 (which is, probably, the most suitable for this)


#4

Good to here @eugene_goldberg. Could you pass along the details you have to the author of that blog post? We should really try to keep those documents up to date as users find bugs.

Thanks!