Bug 1607776
| Summary: | Customer db upgrade from 6.3 -> 6.4 failed at Upgrade Step: set_upstream_pool_id | ||||||
|---|---|---|---|---|---|---|---|
| Product: | Red Hat Satellite | Reporter: | Nikhil Kathole <nkathole> | ||||
| Component: | Subscription Management | Assignee: | Justin Sherrill <jsherril> | ||||
| Status: | CLOSED ERRATA | QA Contact: | Nikhil Kathole <nkathole> | ||||
| Severity: | high | Docs Contact: | |||||
| Priority: | unspecified | ||||||
| Version: | 6.4 | CC: | cwelton, ehelms, inecas | ||||
| Target Milestone: | 6.4.0 | Keywords: | Triaged, Upgrades | ||||
| Target Release: | Unused | ||||||
| Hardware: | Unspecified | ||||||
| OS: | Unspecified | ||||||
| Whiteboard: | |||||||
| Fixed In Version: | tfm-rubygem-katello-3.7.0.7-1 | Doc Type: | If docs needed, set a value | ||||
| Doc Text: | Story Points: | --- | |||||
| Clone Of: | Environment: | ||||||
| Last Closed: | 2018-10-16 19:30:29 UTC | Type: | Bug | ||||
| Regression: | --- | Mount Type: | --- | ||||
| Documentation: | --- | CRM: | |||||
| Verified Versions: | Category: | --- | |||||
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
| Cloudforms Team: | --- | Target Upstream Version: | |||||
| Embargoed: | |||||||
| Attachments: |
|
||||||
Created attachment 1470236 [details]
import_subscription --trace
Created redmine issue https://projects.theforeman.org/issues/24374 from this bug Moving this bug to POST for triage into Satellite 6 since the upstream issue http://projects.theforeman.org/issues/24374 has been resolved. Verified Version tested: Satellite 6.4 snap 14 Upgrade successful with respective db. Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHSA-2018:2927 |
Description of problem: Customer db upgrade from 6.3 -> 6.4 failed at Upgrade Step: set_upstream_pool_id ActiveRecord::StatementInvalid: PG::UndefinedColumn: ERROR: column katello_subscriptions.product_id does not exist LINE 1: ...katello_subscriptions"."organization_id" = $1 AND "katello_s... ^ : SELECT "katello_subscriptions".* FROM "katello_subscriptions" WHERE "katello_subscriptions"."organization_id" = $1 AND "katello_subscriptions"."product_id" = $2 LIMIT $3 Version-Release number of selected component (if applicable): Satellite 6.4 snap 13 How reproducible: Steps to Reproduce: 1. Restored 6.3 db 2. Enable 6.4 repos 3. satellite-installer --scenario satellite --upgrade Actual results: Upgrade failed at Upgrade Step: set_upstream_pool_id showing Upgrade Step: set_upstream_pool_id (this may take a while) ... /usr/share/foreman/lib/foreman.rb:8: warning: already initialized constant Foreman::UUID_REGEXP /usr/share/foreman/lib/foreman.rb:8: warning: previous definition of UUID_REGEXP was here /usr/share/foreman/lib/core_extensions.rb:182: warning: already initialized constant ActiveSupport::MessageEncryptor::DEFAULT_CIPHER /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activesupport-5.1.6/lib/active_support/message_encryptor.rb:22: warning: previous definition of DEFAULT_CIPHER was here rake aborted! ActiveRecord::StatementInvalid: PG::UndefinedColumn: ERROR: column katello_subscriptions.product_id does not exist LINE 1: ...katello_subscriptions"."organization_id" = $1 AND "katello_s... ^ : SELECT "katello_subscriptions".* FROM "katello_subscriptions" WHERE "katello_subscriptions"."organization_id" = $1 AND "katello_subscriptions"."product_id" = $2 LIMIT $3 /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/connection_adapters/postgresql_adapter.rb:682:in `prepare' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/connection_adapters/postgresql_adapter.rb:682:in `block in prepare_statement' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/connection_adapters/postgresql_adapter.rb:677:in `prepare_statement' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/connection_adapters/postgresql_adapter.rb:622:in `exec_cache' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/connection_adapters/postgresql_adapter.rb:605:in `execute_and_clear' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/connection_adapters/postgresql/database_statements.rb:79:in `exec_query' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/connection_adapters/abstract/database_statements.rb:375:in `select_prepared' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/connection_adapters/abstract/database_statements.rb:40:in `select_all' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/connection_adapters/abstract/query_cache.rb:97:in `select_all' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/querying.rb:39:in `find_by_sql' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/relation.rb:678:in `exec_queries' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/relation.rb:546:in `load' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/relation.rb:255:in `records' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/relation/finder_methods.rb:508:in `find_take' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/relation/finder_methods.rb:100:in `take' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/relation/finder_methods.rb:78:in `find_by' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/querying.rb:7:in `find_by' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/core.rb:208:in `find_by' /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.7.0.rc1.6/app/models/katello/glue/candlepin/pool.rb:85:in `stacking_subscription' /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.7.0.rc1.6/app/models/katello/glue/candlepin/pool.rb:104:in `import_data' /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.7.0.rc1.6/app/models/katello/glue/candlepin/candlepin_object.rb:44:in `block (2 levels) in import_all' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/relation/delegation.rb:39:in `each' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/relation/delegation.rb:39:in `each' /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.7.0.rc1.6/app/models/katello/glue/candlepin/candlepin_object.rb:42:in `block in import_all' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/relation/delegation.rb:39:in `each' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/relation/delegation.rb:39:in `each' /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.7.0.rc1.6/app/models/katello/glue/candlepin/candlepin_object.rb:38:in `import_all' /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.7.0.rc1.6/lib/katello/tasks/import_subscriptions.rake:6:in `block (2 levels) in <top (required)>' /opt/rh/rh-ruby24/root/usr/share/gems/gems/rake-12.0.0/exe/rake:27:in `<top (required)>' PG::UndefinedColumn: ERROR: column katello_subscriptions.product_id does not exist LINE 1: ...katello_subscriptions"."organization_id" = $1 AND "katello_s... ^ /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/connection_adapters/postgresql_adapter.rb:682:in `prepare' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/connection_adapters/postgresql_adapter.rb:682:in `block in prepare_statement' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/connection_adapters/postgresql_adapter.rb:677:in `prepare_statement' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/connection_adapters/postgresql_adapter.rb:622:in `exec_cache' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/connection_adapters/postgresql_adapter.rb:605:in `execute_and_clear' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/connection_adapters/postgresql/database_statements.rb:79:in `exec_query' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/connection_adapters/abstract/database_statements.rb:375:in `select_prepared' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/connection_adapters/abstract/database_statements.rb:40:in `select_all' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/connection_adapters/abstract/query_cache.rb:97:in `select_all' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/querying.rb:39:in `find_by_sql' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/relation.rb:678:in `exec_queries' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/relation.rb:546:in `load' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/relation.rb:255:in `records' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/relation/finder_methods.rb:508:in `find_take' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/relation/finder_methods.rb:100:in `take' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/relation/finder_methods.rb:78:in `find_by' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/querying.rb:7:in `find_by' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/core.rb:208:in `find_by' /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.7.0.rc1.6/app/models/katello/glue/candlepin/pool.rb:85:in `stacking_subscription' /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.7.0.rc1.6/app/models/katello/glue/candlepin/pool.rb:104:in `import_data' /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.7.0.rc1.6/app/models/katello/glue/candlepin/candlepin_object.rb:44:in `block (2 levels) in import_all' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/relation/delegation.rb:39:in `each' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/relation/delegation.rb:39:in `each' /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.7.0.rc1.6/app/models/katello/glue/candlepin/candlepin_object.rb:42:in `block in import_all' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/relation/delegation.rb:39:in `each' /opt/theforeman/tfm-ror51/root/usr/share/gems/gems/activerecord-5.1.6/lib/active_record/relation/delegation.rb:39:in `each' /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.7.0.rc1.6/app/models/katello/glue/candlepin/candlepin_object.rb:38:in `import_all' /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.7.0.rc1.6/lib/katello/tasks/import_subscriptions.rake:6:in `block (2 levels) in <top (required)>' /opt/rh/rh-ruby24/root/usr/share/gems/gems/rake-12.0.0/exe/rake:27:in `<top (required)>' Tasks: TOP => katello:import_subscriptions (See full trace by running task with --trace) Importing Subscriptions foreman-rake katello:import_subscriptions failed! Check the output for error! Upgrade step set_upstream_pool_id failed. Check logs for more information. Expected results: Successful upgrade. Additional info: