Project

General

Profile

redmine 4.1.0 - new install - bundle exec rake db:migrate fails

Added by Anne Hammond over 4 years ago

I am installing according to"

https://www.redmine.org/projects/redmine/wiki/RedmineInstall

[root@remine4vm redmine]# bundle exec rake db:migrate RAILS_ENV=production --trace
  • Invoke db:migrate (first_time)
  • Invoke db:load_config (first_time)
  • Invoke environment (first_time)
  • Execute environment
    rake aborted!
    ActiveRecord::StatementInvalid: Mysql2::Error: Table 'redmine.users' doesn't exist: SHOW FULL FIELDS FROM `users`

Here is the full trace:

[root@remine4vm redmine]# bundle exec rake db:migrate RAILS_ENV=production --trace
  • Invoke db:migrate (first_time)
  • Invoke db:load_config (first_time)
  • Invoke environment (first_time)
  • Execute environment
    rake aborted!
    ActiveRecord::StatementInvalid: Mysql2::Error: Table 'redmine.users' doesn't exist: SHOW FULL FIELDS FROM `users`
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/mysql2-0.5.3/lib/mysql2/client.rb:131:in `_query'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/mysql2-0.5.3/lib/mysql2/client.rb:131:in `block in query'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/mysql2-0.5.3/lib/mysql2/client.rb:130:in `handle_interrupt'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/mysql2-0.5.3/lib/mysql2/client.rb:130:in `query'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/connection_adapters/abstract_mysql_adapter.rb:187:in `block (2 levels) in execute'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies/interlock.rb:48:in `block in permit_concurrent_loads'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/concurrency/share_lock.rb:187:in `yield_shares'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies/interlock.rb:47:in `permit_concurrent_loads'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/connection_adapters/abstract_mysql_adapter.rb:186:in `block in execute'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/connection_adapters/abstract_adapter.rb:581:in `block (2 levels) in log'
    /usr/share/ruby/monitor.rb:226:in `mon_synchronize'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/connection_adapters/abstract_adapter.rb:580:in `block in log'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/notifications/instrumenter.rb:23:in `instrument'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/connection_adapters/abstract_adapter.rb:571:in `log'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/connection_adapters/abstract_mysql_adapter.rb:185:in `execute'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/connection_adapters/mysql/database_statements.rb:28:in `execute'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/connection_adapters/abstract_mysql_adapter.rb:196:in `execute_and_free'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/connection_adapters/abstract_mysql_adapter.rb:793:in `column_definitions'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/connection_adapters/abstract/schema_statements.rb:113:in `columns'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/connection_adapters/schema_cache.rb:69:in `columns'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/connection_adapters/schema_cache.rb:75:in `columns_hash'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/model_schema.rb:466:in `load_schema!'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/attributes.rb:234:in `load_schema!'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/attribute_decorators.rb:51:in `load_schema!'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/model_schema.rb:459:in `block in load_schema'
    /usr/share/ruby/monitor.rb:226:in `mon_synchronize'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/model_schema.rb:456:in `load_schema'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/model_schema.rb:336:in `columns_hash'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/inheritance.rb:78:in `descends_from_active_record?'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/inheritance.rb:84:in `finder_needs_type_condition?'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/core.rb:287:in `relation'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/scoping/default.rb:34:in `unscoped'
    /data/redmine-4.1.0/app/models/user.rb:822:in `anonymous'
    /data/redmine-4.1.0/app/models/user.rb:816:in `current'
    /data/redmine-4.1.0/app/models/query.rb:91:in `groupable'
    /data/redmine-4.1.0/app/models/query.rb:31:in `initialize'
    /data/redmine-4.1.0/app/models/issue_query.rb:36:in `new'
    /data/redmine-4.1.0/app/models/issue_query.rb:36:in `<class:IssueQuery>'
    /data/redmine-4.1.0/app/models/issue_query.rb:20:in `<top (required)>'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:291:in `require'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:291:in `block in require'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:257:in `load_dependency'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:291:in `require'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:378:in `block in require_or_load'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:37:in `block in load_interlock'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies/interlock.rb:14:in `block in loading'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/concurrency/share_lock.rb:151:in `exclusive'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies/interlock.rb:13:in `loading'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:37:in `load_interlock'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:356:in `require_or_load'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:510:in `load_missing_constant'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:195:in `const_missing'
    /data/redmine-4.1.0/plugins/redmine_checklists/lib/redmine_checklists/patches/issue_query_patch.rb:93:in `<top (required)>'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:291:in `require'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:291:in `block in require'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:257:in `load_dependency'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:291:in `require'
    /data/redmine-4.1.0/plugins/redmine_checklists/lib/redmine_checklists/redmine_checklists.rb:34:in `block in <top (required)>'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/callbacks.rb:426:in `instance_exec'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/callbacks.rb:426:in `block in make_lambda'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/callbacks.rb:198:in `block (2 levels) in halting'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/callbacks.rb:606:in `block (2 levels) in default_terminator'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/callbacks.rb:605:in `catch'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/callbacks.rb:605:in `block in default_terminator'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/callbacks.rb:199:in `block in halting'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/callbacks.rb:513:in `block in invoke_before'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/callbacks.rb:513:in `each'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/callbacks.rb:513:in `invoke_before'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/callbacks.rb:131:in `run_callbacks'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/reloader.rb:89:in `prepare!'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/railties-5.2.4.1/lib/rails/application/finisher.rb:63:in `block in <module:Finisher>'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/railties-5.2.4.1/lib/rails/initializable.rb:32:in `instance_exec'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/railties-5.2.4.1/lib/rails/initializable.rb:32:in `run'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/railties-5.2.4.1/lib/rails/initializable.rb:61:in `block in run_initializers'
    /usr/share/ruby/tsort.rb:228:in `block in tsort_each'
    /usr/share/ruby/tsort.rb:350:in `block (2 levels) in each_strongly_connected_component'
    /usr/share/ruby/tsort.rb:431:in `each_strongly_connected_component_from'
    /usr/share/ruby/tsort.rb:349:in `block in each_strongly_connected_component'
    /usr/share/ruby/tsort.rb:347:in `each'
    /usr/share/ruby/tsort.rb:347:in `call'
    /usr/share/ruby/tsort.rb:347:in `each_strongly_connected_component'
    /usr/share/ruby/tsort.rb:226:in `tsort_each'
    /usr/share/ruby/tsort.rb:205:in `tsort_each'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/railties-5.2.4.1/lib/rails/initializable.rb:60:in `run_initializers'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/railties-5.2.4.1/lib/rails/application.rb:361:in `initialize!'
    /data/redmine-4.1.0/config/environment.rb:16:in `<top (required)>'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:291:in `require'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:291:in `block in require'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:257:in `load_dependency'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:291:in `require'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/railties-5.2.4.1/lib/rails/application.rb:337:in `require_environment!'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/railties-5.2.4.1/lib/rails/application.rb:520:in `block in run_tasks_blocks'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/task.rb:281:in `block in execute'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/task.rb:281:in `each'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/task.rb:281:in `execute'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/task.rb:219:in `block in invoke_with_call_chain'
    /usr/share/ruby/monitor.rb:226:in `mon_synchronize'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/task.rb:199:in `invoke_with_call_chain'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/task.rb:243:in `block in invoke_prerequisites'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/task.rb:241:in `each'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/task.rb:241:in `invoke_prerequisites'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/task.rb:218:in `block in invoke_with_call_chain'
    /usr/share/ruby/monitor.rb:226:in `mon_synchronize'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/task.rb:199:in `invoke_with_call_chain'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/task.rb:243:in `block in invoke_prerequisites'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/task.rb:241:in `each'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/task.rb:241:in `invoke_prerequisites'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/task.rb:218:in `block in invoke_with_call_chain'
    /usr/share/ruby/monitor.rb:226:in `mon_synchronize'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/task.rb:199:in `invoke_with_call_chain'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/task.rb:188:in `invoke'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/application.rb:160:in `invoke_task'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/application.rb:116:in `block (2 levels) in top_level'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/application.rb:116:in `each'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/application.rb:116:in `block in top_level'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/application.rb:125:in `run_with_threads'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/application.rb:110:in `top_level'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/application.rb:83:in `block in run'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/application.rb:186:in `standard_exception_handling'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/application.rb:80:in `run'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/exe/rake:27:in `<top (required)>'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/bin/rake:23:in `load'
    /data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/bin/rake:23:in `<top (required)>'
    /usr/local/share/gems/gems/bundler-2.1.4/lib/bundler/cli/exec.rb:63:in `load'
    /usr/local/share/gems/gems/bundler-2.1.4/lib/bundler/cli/exec.rb:63:in `kernel_load'
    /usr/local/share/gems/gems/bundler-2.1.4/lib/bundler/cli/exec.rb:28:in `run'
    /usr/local/share/gems/gems/bundler-2.1.4/lib/bundler/cli.rb:476:in `exec'
    /usr/local/share/gems/gems/bundler-2.1.4/lib/bundler/vendor/thor/lib/thor/command.rb:27:in `run'
    /usr/local/share/gems/gems/bundler-2.1.4/lib/bundler/vendor/thor/lib/thor/invocation.rb:127:in `invoke_command'
    /usr/local/share/gems/gems/bundler-2.1.4/lib/bundler/vendor/thor/lib/thor.rb:399:in `dispatch'
    /usr/local/share/gems/gems/bundler-2.1.4/lib/bundler/cli.rb:30:in `dispatch'
    /usr/local/share/gems/gems/bundler-2.1.4/lib/bundler/vendor/thor/lib/thor/base.rb:476:in `start'
    /usr/local/share/gems/gems/bundler-2.1.4/lib/bundler/cli.rb:24:in `start'
    /usr/local/share/gems/gems/bundler-2.1.4/exe/bundle:46:in `block in <top (required)>'
    /usr/local/share/gems/gems/bundler-2.1.4/lib/bundler/friendly_errors.rb:123:in `with_friendly_errors'
    /usr/local/share/gems/gems/bundler-2.1.4/exe/bundle:34:in `<top (required)>'
    /usr/local/bin/bundle:23:in `load'
    /usr/local/bin/bundle:23:in `<main>'

Caused by:
Mysql2::Error: Table 'redmine.users' doesn't exist
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/mysql2-0.5.3/lib/mysql2/client.rb:131:in `_query'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/mysql2-0.5.3/lib/mysql2/client.rb:131:in `block in query'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/mysql2-0.5.3/lib/mysql2/client.rb:130:in `handle_interrupt'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/mysql2-0.5.3/lib/mysql2/client.rb:130:in `query'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/connection_adapters/abstract_mysql_adapter.rb:187:in `block (2 levels) in execute'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies/interlock.rb:48:in `block in permit_concurrent_loads'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/concurrency/share_lock.rb:187:in `yield_shares'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies/interlock.rb:47:in `permit_concurrent_loads'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/connection_adapters/abstract_mysql_adapter.rb:186:in `block in execute'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/connection_adapters/abstract_adapter.rb:581:in `block (2 levels) in log'
/usr/share/ruby/monitor.rb:226:in `mon_synchronize'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/connection_adapters/abstract_adapter.rb:580:in `block in log'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/notifications/instrumenter.rb:23:in `instrument'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/connection_adapters/abstract_adapter.rb:571:in `log'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/connection_adapters/abstract_mysql_adapter.rb:185:in `execute'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/connection_adapters/mysql/database_statements.rb:28:in `execute'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/connection_adapters/abstract_mysql_adapter.rb:196:in `execute_and_free'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/connection_adapters/abstract_mysql_adapter.rb:793:in `column_definitions'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/connection_adapters/abstract/schema_statements.rb:113:in `columns'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/connection_adapters/schema_cache.rb:69:in `columns'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/connection_adapters/schema_cache.rb:75:in `columns_hash'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/model_schema.rb:466:in `load_schema!'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/attributes.rb:234:in `load_schema!'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/attribute_decorators.rb:51:in `load_schema!'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/model_schema.rb:459:in `block in load_schema'
/usr/share/ruby/monitor.rb:226:in `mon_synchronize'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/model_schema.rb:456:in `load_schema'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/model_schema.rb:336:in `columns_hash'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/inheritance.rb:78:in `descends_from_active_record?'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/inheritance.rb:84:in `finder_needs_type_condition?'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/core.rb:287:in `relation'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activerecord-5.2.4.1/lib/active_record/scoping/default.rb:34:in `unscoped'
/data/redmine-4.1.0/app/models/user.rb:822:in `anonymous'
/data/redmine-4.1.0/app/models/user.rb:816:in `current'
/data/redmine-4.1.0/app/models/query.rb:91:in `groupable'
/data/redmine-4.1.0/app/models/query.rb:31:in `initialize'
/data/redmine-4.1.0/app/models/issue_query.rb:36:in `new'
/data/redmine-4.1.0/app/models/issue_query.rb:36:in `<class:IssueQuery>'
/data/redmine-4.1.0/app/models/issue_query.rb:20:in `<top (required)>'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:291:in `require'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:291:in `block in require'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:257:in `load_dependency'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:291:in `require'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:378:in `block in require_or_load'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:37:in `block in load_interlock'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies/interlock.rb:14:in `block in loading'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/concurrency/share_lock.rb:151:in `exclusive'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies/interlock.rb:13:in `loading'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:37:in `load_interlock'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:356:in `require_or_load'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:510:in `load_missing_constant'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:195:in `const_missing'
/data/redmine-4.1.0/plugins/redmine_checklists/lib/redmine_checklists/patches/issue_query_patch.rb:93:in `<top (required)>'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:291:in `require'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:291:in `block in require'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:257:in `load_dependency'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:291:in `require'
/data/redmine-4.1.0/plugins/redmine_checklists/lib/redmine_checklists/redmine_checklists.rb:34:in `block in <top (required)>'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/callbacks.rb:426:in `instance_exec'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/callbacks.rb:426:in `block in make_lambda'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/callbacks.rb:198:in `block (2 levels) in halting'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/callbacks.rb:606:in `block (2 levels) in default_terminator'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/callbacks.rb:605:in `catch'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/callbacks.rb:605:in `block in default_terminator'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/callbacks.rb:199:in `block in halting'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/callbacks.rb:513:in `block in invoke_before'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/callbacks.rb:513:in `each'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/callbacks.rb:513:in `invoke_before'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/callbacks.rb:131:in `run_callbacks'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/reloader.rb:89:in `prepare!'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/railties-5.2.4.1/lib/rails/application/finisher.rb:63:in `block in <module:Finisher>'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/railties-5.2.4.1/lib/rails/initializable.rb:32:in `instance_exec'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/railties-5.2.4.1/lib/rails/initializable.rb:32:in `run'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/railties-5.2.4.1/lib/rails/initializable.rb:61:in `block in run_initializers'
/usr/share/ruby/tsort.rb:228:in `block in tsort_each'
/usr/share/ruby/tsort.rb:350:in `block (2 levels) in each_strongly_connected_component'
/usr/share/ruby/tsort.rb:431:in `each_strongly_connected_component_from'
/usr/share/ruby/tsort.rb:349:in `block in each_strongly_connected_component'
/usr/share/ruby/tsort.rb:347:in `each'
/usr/share/ruby/tsort.rb:347:in `call'
/usr/share/ruby/tsort.rb:347:in `each_strongly_connected_component'
/usr/share/ruby/tsort.rb:226:in `tsort_each'
/usr/share/ruby/tsort.rb:205:in `tsort_each'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/railties-5.2.4.1/lib/rails/initializable.rb:60:in `run_initializers'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/railties-5.2.4.1/lib/rails/application.rb:361:in `initialize!'
/data/redmine-4.1.0/config/environment.rb:16:in `<top (required)>'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:291:in `require'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:291:in `block in require'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:257:in `load_dependency'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:291:in `require'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/railties-5.2.4.1/lib/rails/application.rb:337:in `require_environment!'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/railties-5.2.4.1/lib/rails/application.rb:520:in `block in run_tasks_blocks'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/task.rb:281:in `block in execute'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/task.rb:281:in `each'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/task.rb:281:in `execute'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/task.rb:219:in `block in invoke_with_call_chain'
/usr/share/ruby/monitor.rb:226:in `mon_synchronize'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/task.rb:199:in `invoke_with_call_chain'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/task.rb:243:in `block in invoke_prerequisites'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/task.rb:241:in `each'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/task.rb:241:in `invoke_prerequisites'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/task.rb:218:in `block in invoke_with_call_chain'
/usr/share/ruby/monitor.rb:226:in `mon_synchronize'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/task.rb:199:in `invoke_with_call_chain'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/task.rb:243:in `block in invoke_prerequisites'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/task.rb:241:in `each'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/task.rb:241:in `invoke_prerequisites'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/task.rb:218:in `block in invoke_with_call_chain'
/usr/share/ruby/monitor.rb:226:in `mon_synchronize'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/task.rb:199:in `invoke_with_call_chain'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/task.rb:188:in `invoke'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/application.rb:160:in `invoke_task'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/application.rb:116:in `block (2 levels) in top_level'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/application.rb:116:in `each'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/application.rb:116:in `block in top_level'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/application.rb:125:in `run_with_threads'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/application.rb:110:in `top_level'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/application.rb:83:in `block in run'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/application.rb:186:in `standard_exception_handling'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/lib/rake/application.rb:80:in `run'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/gems/rake-13.0.1/exe/rake:27:in `<top (required)>'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/bin/rake:23:in `load'
/data/redmine-4.1.0/vendor/bundle/ruby/2.5.0/bin/rake:23:in `<top (required)>'
/usr/local/share/gems/gems/bundler-2.1.4/lib/bundler/cli/exec.rb:63:in `load'
/usr/local/share/gems/gems/bundler-2.1.4/lib/bundler/cli/exec.rb:63:in `kernel_load'
/usr/local/share/gems/gems/bundler-2.1.4/lib/bundler/cli/exec.rb:28:in `run'
/usr/local/share/gems/gems/bundler-2.1.4/lib/bundler/cli.rb:476:in `exec'
/usr/local/share/gems/gems/bundler-2.1.4/lib/bundler/vendor/thor/lib/thor/command.rb:27:in `run'
/usr/local/share/gems/gems/bundler-2.1.4/lib/bundler/vendor/thor/lib/thor/invocation.rb:127:in `invoke_command'
/usr/local/share/gems/gems/bundler-2.1.4/lib/bundler/vendor/thor/lib/thor.rb:399:in `dispatch'
/usr/local/share/gems/gems/bundler-2.1.4/lib/bundler/cli.rb:30:in `dispatch'
/usr/local/share/gems/gems/bundler-2.1.4/lib/bundler/vendor/thor/lib/thor/base.rb:476:in `start'
/usr/local/share/gems/gems/bundler-2.1.4/lib/bundler/cli.rb:24:in `start'
/usr/local/share/gems/gems/bundler-2.1.4/exe/bundle:46:in `block in <top (required)>'
/usr/local/share/gems/gems/bundler-2.1.4/lib/bundler/friendly_errors.rb:123:in `with_friendly_errors'
/usr/local/share/gems/gems/bundler-2.1.4/exe/bundle:34:in `<top (required)>'
/usr/local/bin/bundle:23:in `load'
/usr/local/bin/bundle:23:in `<main>'
Tasks: TOP => db:migrate => db:load_config => environment

Any suggestions appreciated.


Replies (3)

RE: redmine 4.1.0 - new install - bundle exec rake db:migrate fails - Added by Liane Hampe over 4 years ago

I assume you have already included a plugin in the redmine plugins directory or it is a kind of legacy. The reason for this assumption is this part in your trace:
/dependencies.rb:195:in `const_missing'
/data/redmine-4.1.0/plugins/redmine_checklists/lib/redmine_checklists/patches/issue_query_patch.rb:93:in `<top (required)>'

When integrating plugins before Redmine is initially installed and migrated, the plugins will be migrated too. The problem with this is that the migration files of the plugin may run to early. That is, before all default Redmine tables are created.

Check whether there is the mentionend plugin and move it out of the redmine directory. Clear the database and start from scratch. After hopefully finishing sucessful, add the plugin again and follow the usual plugin instructions.

If you cannot solve the problem this way, let me know.

RE: redmine 4.1.0 - new install - bundle exec rake db:migrate fails - Added by Anne Hammond over 4 years ago

Thank you Liane.

This was it. There was one plugin in plugins/

I moved this up one directory and then repeated the command.

The result was successful.

Now the table exists:


mysql> show tables;
+-------------------------------------+
| Tables_in_redmine                   |
+-------------------------------------+
| ar_internal_metadata                |
| attachments                         |
| auth_sources                        |
| boards                              |
| changes                             |
| changeset_parents                   |
| changesets                          |
| changesets_issues                   |
| comments                            |
| custom_field_enumerations           |
| custom_fields                       |
| custom_fields_projects              |
| custom_fields_roles                 |
| custom_fields_trackers              |
| custom_values                       |
| documents                           |
| email_addresses                     |
| enabled_modules                     |
| enumerations                        |
| groups_users                        |
| import_items                        |
| imports                             |
| issue_categories                    |
| issue_relations                     |
| issue_statuses                      |
| issues                              |
| journal_details                     |
| journals                            |
| member_roles                        |
| members                             |
| messages                            |
| news                                |
| open_id_authentication_associations |
| open_id_authentication_nonces       |
| projects                            |
| projects_trackers                   |
| queries                             |
| queries_roles                       |
| repositories                        |
| roles                               |
| roles_managed_roles                 |
| schema_migrations                   |
| settings                            |
| time_entries                        |
| tokens                              |
| trackers                            |
| user_preferences                    |
| users                               |
| versions                            |
| watchers                            |
| wiki_content_versions               |
| wiki_contents                       |
| wiki_pages                          |
| wiki_redirects                      |
| wikis                               |
| workflows                           |
+-------------------------------------+
56 rows in set (0.00 sec)

I like to migrate the db one plugin at a time, so will do this again.

Thank you again, Liane.

    (1-3/3)