Foreman Katello Installation Error!

This is a fresh installation for foreman along with katello.

Error with foreman-installer:

[ERROR 2020-01-13T10:31:57 main] Errors encountered during run:
[ERROR 2020-01-13T10:31:57 main]  '/usr/sbin/foreman-rake db:migrate' returned 1 instead of one of [0]
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/errors.rb:157:in `fail'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/type/exec.rb:183:in `sync'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction/resource_harness.rb:241:in `sync'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction/resource_harness.rb:136:in `sync_if_needed'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction/resource_harness.rb:90:in `block in perform_changes'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction/resource_harness.rb:89:in `each'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction/resource_harness.rb:89:in `perform_changes'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction/resource_harness.rb:21:in `evaluate'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:263:in `apply'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:283:in `eval_resource'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:187:in `call'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:187:in `block (2 levels) in evaluate'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:521:in `block in thinmark'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/2.5.0/benchmark.rb:308:in `realtime'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:520:in `thinmark'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:187:in `block in evaluate'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/graph/relationship_graph.rb:122:in `traverse'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:174:in `evaluate'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/resource/catalog.rb:240:in `block (2 levels) in apply'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:521:in `block in thinmark'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/2.5.0/benchmark.rb:308:in `realtime'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:520:in `thinmark'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/resource/catalog.rb:239:in `block in apply'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/log.rb:161:in `with_destination'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction/report.rb:146:in `as_logging_destination'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/resource/catalog.rb:238:in `apply'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:194:in `block (2 levels) in apply_catalog'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:521:in `block in thinmark'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/2.5.0/benchmark.rb:308:in `realtime'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:520:in `thinmark'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:193:in `block in apply_catalog'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:233:in `block in benchmark'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/2.5.0/benchmark.rb:308:in `realtime'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:232:in `benchmark'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:192:in `apply_catalog'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:381:in `run_internal'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:242:in `block in run'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/context.rb:62:in `override'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet.rb:274:in `override'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:219:in `run'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application/apply.rb:343:in `apply_catalog'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application/apply.rb:260:in `block (2 levels) in main'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/context.rb:62:in `override'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet.rb:274:in `override'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application/apply.rb:243:in `block in main'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/context.rb:62:in `override'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet.rb:274:in `override'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application/apply.rb:207:in `main'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application/apply.rb:177:in `run_command'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application.rb:382:in `block in run'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:687:in `exit_on_fail'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application.rb:382:in `run'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/command_line.rb:143:in `run'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/command_line.rb:77:in `execute'
[ERROR 2020-01-13T10:31:57 main] /opt/puppetlabs/puppet/bin/puppet:5:in `<main>'
[ERROR 2020-01-13T10:31:57 main]  /Stage[main]/Foreman::Database/Foreman::Rake[db:migrate]/Exec[foreman-rake-db:migrate]/returns: change from 'notrun' to ['0'] failed: '/usr/sbin/foreman-rake db:migrate' returned 1 instead of one of [0]
:**

Looks like the DB migrations failed to run. which version of foreman and katello are you installing? can you please paste the actual error from the failing migration? (should be in /var/log/foreman/install.log or /var/log/foreman/production.log)

The version of Foreman is 1.24.1-1.el7 and Katello is 3.15.0-0.3.master.el7

and the logs located in /var/log/foreman/production.log

2020-01-19T23:03:39 [E|kat|3c6a22c9] <Array> ["/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/candlepin_event_listener.rb:70:in `initialize_listening_service'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/candlepin_event_listener.rb:12:in `run'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:31:in `block in check_services'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:20:in `each'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:20:in `check_services'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:13:in `block (2 levels) in start'", "/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/execution_wrapper.rb:87:in `wrap'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:12:in `block in start'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:11:in `loop'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:11:in `start'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:117:in `block in start_monitor_thread'", "/opt/theforeman/tfm/root/usr/share/gems/gems/logging-2.2.2/lib/logging/diagnostic_context.rb:474:in `block in create_with_logging_context'"]
2020-01-19T23:03:39 [E|kat|3c6a22c9] Fatal error in Candlepin Listening Service
2020-01-19T23:03:39 [E|app|3c6a22c9] Error occurred while starting Katello::CandlepinEventListener
2020-01-19T23:03:39 [E|app|3c6a22c9] undefined method `start' for nil:NilClass
2020-01-19T23:03:39 [E|app|3c6a22c9] /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/candlepin_event_listener.rb:14:in `run'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:31:in `block in check_services'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:20:in `each'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:20:in `check_services'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:13:in `block (2 levels) in start'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/execution_wrapper.rb:87:in `wrap'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:12:in `block in start'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:11:in `loop'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:11:in `start'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:117:in `block in start_monitor_thread'
/opt/theforeman/tfm/root/usr/share/gems/gems/logging-2.2.2/lib/logging/diagnostic_context.rb:474:in `block in create_with_logging_context'
2020-01-19T23:03:39 [I|kat|3c6a22c9] Stopping Katello Event Monitor
2020-01-19T23:03:39 [E|app|3c6a22c9] Error occurred while starting Katello::EventMonitor::PollerThread
2020-01-19T23:03:39 [E|app|3c6a22c9] PG::UndefinedTable: ERROR:  relation "katello_events" does not exist
LINE 8:                WHERE a.attrelid = '"katello_events"'::regcla...
                                          ^
:               SELECT a.attname, format_type(a.atttypid, a.atttypmod),
                     pg_get_expr(d.adbin, d.adrelid), a.attnotnull, a.atttypid, a.atttypmod,
                     c.collname, col_description(a.attrelid, a.attnum) AS comment
                FROM pg_attribute a
                LEFT JOIN pg_attrdef d ON a.attrelid = d.adrelid AND a.attnum = d.adnum
                LEFT JOIN pg_type t ON a.atttypid = t.oid
                LEFT JOIN pg_collation c ON a.attcollation = c.oid AND a.attcollation <> t.typcollation
               WHERE a.attrelid = '"katello_events"'::regclass
                 AND a.attnum > 0 AND NOT a.attisdropped
               ORDER BY a.attnum

2020-01-19T23:03:39 [E|app|3c6a22c9] /opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql/database_statements.rb:63:in `async_exec'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql/database_statements.rb:63:in `block (2 levels) in query'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/dependencies/interlock.rb:48:in `block in permit_concurrent_loads'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/concurrency/share_lock.rb:187:in `yield_shares'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/dependencies/interlock.rb:47:in `permit_concurrent_loads'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql/database_statements.rb:62:in `block in query'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract_adapter.rb:579:in `block (2 levels) in log'
/opt/rh/rh-ruby25/root/usr/share/ruby/monitor.rb:226:in `mon_synchronize'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract_adapter.rb:578:in `block in log'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/notifications/instrumenter.rb:23:in `instrument'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract_adapter.rb:569:in `log'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql/database_statements.rb:61:in `query'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql_adapter.rb:749:in `column_definitions'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract/schema_statements.rb:113:in `columns'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/schema_cache.rb:69:in `columns'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/schema_cache.rb:75:in `columns_hash'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:466:in `load_schema!'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/attributes.rb:234:in `load_schema!'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/attribute_decorators.rb:51:in `load_schema!'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:459:in `block in load_schema'
/opt/rh/rh-ruby25/root/usr/share/ruby/monitor.rb:226:in `mon_synchronize'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:456:in `load_schema'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:346:in `attribute_types'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:370:in `type_for_attribute'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/table_metadata.rb:33:in `type'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:51:in `build'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:107:in `block in expand_from_hash'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:71:in `each'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:71:in `flat_map'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:71:in `expand_from_hash'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:21:in `build_from_hash'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/where_clause_factory.rb:19:in `build'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/query_methods.rb:591:in `where!'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/query_methods.rb:584:in `where'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/querying.rb:12:in `where'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_queue.rb:42:in `reset_in_progress'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_monitor/poller_thread.rb:23:in `run'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:31:in `block in check_services'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:20:in `each'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:20:in `check_services'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:13:in `block (2 levels) in start'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/execution_wrapper.rb:87:in `wrap'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:12:in `block in start'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:11:in `loop'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:11:in `start'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:117:in `block in start_monitor_thread'
/opt/theforeman/tfm/root/usr/share/gems/gems/logging-2.2.2/lib/logging/diagnostic_context.rb:474:in `block in create_with_logging_context'
2020-01-19T23:03:54 [E|kat|3c6a22c9] Katello has not been configured for qpid.url and qpid.subscriptions_queue_address
2020-01-19T23:03:54 [E|kat|3c6a22c9] <Array> ["/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/candlepin_event_listener.rb:70:in `initialize_listening_service'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/candlepin_event_listener.rb:12:in `run'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:31:in `block in check_services'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:20:in `each'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:20:in `check_services'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:13:in `block (2 levels) in start'", "/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/execution_wrapper.rb:87:in `wrap'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:12:in `block in start'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:11:in `loop'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:11:in `start'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:117:in `block in start_monitor_thread'", "/opt/theforeman/tfm/root/usr/share/gems/gems/logging-2.2.2/lib/logging/diagnostic_context.rb:474:in `block in create_with_logging_context'"]
2020-01-19T23:03:54 [E|kat|3c6a22c9] Fatal error in Candlepin Listening Service
2020-01-19T23:03:54 [E|app|3c6a22c9] Error occurred while starting Katello::CandlepinEventListener
2020-01-19T23:03:54 [E|app|3c6a22c9] undefined method `start' for nil:NilClass
2020-01-19T23:03:54 [E|app|3c6a22c9] /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/candlepin_event_listener.rb:14:in `run'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:31:in `block in check_services'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:20:in `each'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:20:in `check_services'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:13:in `block (2 levels) in start'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/execution_wrapper.rb:87:in `wrap'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:12:in `block in start'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:11:in `loop'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:11:in `start'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:117:in `block in start_monitor_thread'
/opt/theforeman/tfm/root/usr/share/gems/gems/logging-2.2.2/lib/logging/diagnostic_context.rb:474:in `block in create_with_logging_context'
2020-01-19T23:03:54 [I|kat|3c6a22c9] Stopping Katello Event Monitor
2020-01-19T23:03:54 [E|app|3c6a22c9] Error occurred while starting Katello::EventMonitor::PollerThread
2020-01-19T23:03:54 [E|app|3c6a22c9] PG::UndefinedTable: ERROR:  relation "katello_events" does not exist
LINE 8:                WHERE a.attrelid = '"katello_events"'::regcla...
                                          ^
:               SELECT a.attname, format_type(a.atttypid, a.atttypmod),
                     pg_get_expr(d.adbin, d.adrelid), a.attnotnull, a.atttypid, a.atttypmod,
                     c.collname, col_description(a.attrelid, a.attnum) AS comment
                FROM pg_attribute a
                LEFT JOIN pg_attrdef d ON a.attrelid = d.adrelid AND a.attnum = d.adnum
                LEFT JOIN pg_type t ON a.atttypid = t.oid
                LEFT JOIN pg_collation c ON a.attcollation = c.oid AND a.attcollation <> t.typcollation
               WHERE a.attrelid = '"katello_events"'::regclass
                 AND a.attnum > 0 AND NOT a.attisdropped
               ORDER BY a.attnum

2020-01-19T23:03:54 [E|app|3c6a22c9] /opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql/database_statements.rb:63:in `async_exec'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql/database_statements.rb:63:in `block (2 levels) in query'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/dependencies/interlock.rb:48:in `block in permit_concurrent_loads'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/concurrency/share_lock.rb:187:in `yield_shares'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/dependencies/interlock.rb:47:in `permit_concurrent_loads'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql/database_statements.rb:62:in `block in query'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract_adapter.rb:579:in `block (2 levels) in log'
/opt/rh/rh-ruby25/root/usr/share/ruby/monitor.rb:226:in `mon_synchronize'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract_adapter.rb:578:in `block in log'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/notifications/instrumenter.rb:23:in `instrument'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract_adapter.rb:569:in `log'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql/database_statements.rb:61:in `query'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql_adapter.rb:749:in `column_definitions'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract/schema_statements.rb:113:in `columns'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/schema_cache.rb:69:in `columns'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/schema_cache.rb:75:in `columns_hash'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:466:in `load_schema!'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/attributes.rb:234:in `load_schema!'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/attribute_decorators.rb:51:in `load_schema!'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:459:in `block in load_schema'
/opt/rh/rh-ruby25/root/usr/share/ruby/monitor.rb:226:in `mon_synchronize'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:456:in `load_schema'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:346:in `attribute_types'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:370:in `type_for_attribute'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/table_metadata.rb:33:in `type'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:51:in `build'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:107:in `block in expand_from_hash'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:71:in `each'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:71:in `flat_map'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:71:in `expand_from_hash'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:21:in `build_from_hash'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/where_clause_factory.rb:19:in `build'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/query_methods.rb:591:in `where!'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/query_methods.rb:584:in `where'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/querying.rb:12:in `where'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_queue.rb:42:in `reset_in_progress'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_monitor/poller_thread.rb:23:in `run'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:31:in `block in check_services'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:20:in `each'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:20:in `check_services'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:13:in `block (2 levels) in start'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/execution_wrapper.rb:87:in `wrap'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:12:in `block in start'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:11:in `loop'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:11:in `start'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:117:in `block in start_monitor_thread'
/opt/theforeman/tfm/root/usr/share/gems/gems/logging-2.2.2/lib/logging/diagnostic_context.rb:474:in `block in create_with_logging_context'
2020-01-19T23:04:09 [E|kat|3c6a22c9] Katello has not been configured for qpid.url and qpid.subscriptions_queue_address
2020-01-19T23:04:09 [E|kat|3c6a22c9] <Array> ["/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/candlepin_event_listener.rb:70:in `initialize_listening_service'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/candlepin_event_listener.rb:12:in `run'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:31:in `block in check_services'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:20:in `each'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:20:in `check_services'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:13:in `block (2 levels) in start'", "/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/execution_wrapper.rb:87:in `wrap'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:12:in `block in start'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:11:in `loop'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:11:in `start'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:117:in `block in start_monitor_thread'", "/opt/theforeman/tfm/root/usr/share/gems/gems/logging-2.2.2/lib/logging/diagnostic_context.rb:474:in `block in create_with_logging_context'"]
2020-01-19T23:04:09 [E|kat|3c6a22c9] Fatal error in Candlepin Listening Service
2020-01-19T23:04:09 [E|app|3c6a22c9] Error occurred while starting Katello::CandlepinEventListener
2020-01-19T23:04:09 [E|app|3c6a22c9] undefined method `start' for nil:NilClass
2020-01-19T23:04:09 [E|app|3c6a22c9] /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/candlepin_event_listener.rb:14:in `run'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:31:in `block in check_services'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:20:in `each'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:20:in `check_services'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:13:in `block (2 levels) in start'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/execution_wrapper.rb:87:in `wrap'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:12:in `block in start'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:11:in `loop'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:11:in `start'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:117:in `block in start_monitor_thread'
/opt/theforeman/tfm/root/usr/share/gems/gems/logging-2.2.2/lib/logging/diagnostic_context.rb:474:in `block in create_with_logging_context'
2020-01-19T23:04:09 [I|kat|3c6a22c9] Stopping Katello Event Monitor
2020-01-19T23:04:09 [E|app|3c6a22c9] Error occurred while starting Katello::EventMonitor::PollerThread
2020-01-19T23:04:09 [E|app|3c6a22c9] PG::UndefinedTable: ERROR:  relation "katello_events" does not exist
LINE 8:                WHERE a.attrelid = '"katello_events"'::regcla...
                                          ^
:               SELECT a.attname, format_type(a.atttypid, a.atttypmod),
                     pg_get_expr(d.adbin, d.adrelid), a.attnotnull, a.atttypid, a.atttypmod,
                     c.collname, col_description(a.attrelid, a.attnum) AS comment
                FROM pg_attribute a
                LEFT JOIN pg_attrdef d ON a.attrelid = d.adrelid AND a.attnum = d.adnum
                LEFT JOIN pg_type t ON a.atttypid = t.oid
                LEFT JOIN pg_collation c ON a.attcollation = c.oid AND a.attcollation <> t.typcollation
               WHERE a.attrelid = '"katello_events"'::regclass
                 AND a.attnum > 0 AND NOT a.attisdropped
               ORDER BY a.attnum

2020-01-19T23:04:09 [E|app|3c6a22c9] /opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql/database_statements.rb:63:in `async_exec'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql/database_statements.rb:63:in `block (2 levels) in query'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/dependencies/interlock.rb:48:in `block in permit_concurrent_loads'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/concurrency/share_lock.rb:187:in `yield_shares'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/dependencies/interlock.rb:47:in `permit_concurrent_loads'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql/database_statements.rb:62:in `block in query'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract_adapter.rb:579:in `block (2 levels) in log'
/opt/rh/rh-ruby25/root/usr/share/ruby/monitor.rb:226:in `mon_synchronize'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract_adapter.rb:578:in `block in log'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/notifications/instrumenter.rb:23:in `instrument'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract_adapter.rb:569:in `log'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql/database_statements.rb:61:in `query'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql_adapter.rb:749:in `column_definitions'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract/schema_statements.rb:113:in `columns'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/schema_cache.rb:69:in `columns'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/schema_cache.rb:75:in `columns_hash'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:466:in `load_schema!'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/attributes.rb:234:in `load_schema!'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/attribute_decorators.rb:51:in `load_schema!'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:459:in `block in load_schema'
/opt/rh/rh-ruby25/root/usr/share/ruby/monitor.rb:226:in `mon_synchronize'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:456:in `load_schema'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:346:in `attribute_types'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:370:in `type_for_attribute'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/table_metadata.rb:33:in `type'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:51:in `build'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:107:in `block in expand_from_hash'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:71:in `each'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:71:in `flat_map'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:71:in `expand_from_hash'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:21:in `build_from_hash'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/where_clause_factory.rb:19:in `build'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/query_methods.rb:591:in `where!'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/query_methods.rb:584:in `where'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/querying.rb:12:in `where'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_queue.rb:42:in `reset_in_progress'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_monitor/poller_thread.rb:23:in `run'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:31:in `block in check_services'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:20:in `each'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:20:in `check_services'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:13:in `block (2 levels) in start'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/execution_wrapper.rb:87:in `wrap'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:12:in `block in start'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:11:in `loop'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:11:in `start'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:117:in `block in start_monitor_thread'
/opt/theforeman/tfm/root/usr/share/gems/gems/logging-2.2.2/lib/logging/diagnostic_context.rb:474:in `block in create_with_logging_context'
2020-01-19T23:04:24 [E|kat|3c6a22c9] Katello has not been configured for qpid.url and qpid.subscriptions_queue_address
2020-01-19T23:04:24 [E|kat|3c6a22c9] <Array> ["/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/candlepin_event_listener.rb:70:in `initialize_listening_service'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/candlepin_event_listener.rb:12:in `run'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:31:in `block in check_services'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:20:in `each'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:20:in `check_services'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:13:in `block (2 levels) in start'", "/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/execution_wrapper.rb:87:in `wrap'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:12:in `block in start'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:11:in `loop'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:11:in `start'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:117:in `block in start_monitor_thread'", "/opt/theforeman/tfm/root/usr/share/gems/gems/logging-2.2.2/lib/logging/diagnostic_context.rb:474:in `block in create_with_logging_context'"]
2020-01-19T23:04:24 [E|kat|3c6a22c9] Fatal error in Candlepin Listening Service
2020-01-19T23:04:24 [E|app|3c6a22c9] Error occurred while starting Katello::CandlepinEventListener
2020-01-19T23:04:24 [E|app|3c6a22c9] undefined method `start' for nil:NilClass
2020-01-19T23:04:24 [E|app|3c6a22c9] /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/candlepin_event_listener.rb:14:in `run'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:31:in `block in check_services'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:20:in `each'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:20:in `check_services'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:13:in `block (2 levels) in start'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/execution_wrapper.rb:87:in `wrap'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:12:in `block in start'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:11:in `loop'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:11:in `start'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:117:in `block in start_monitor_thread'
/opt/theforeman/tfm/root/usr/share/gems/gems/logging-2.2.2/lib/logging/diagnostic_context.rb:474:in `block in create_with_logging_context'
2020-01-19T23:04:24 [I|kat|3c6a22c9] Stopping Katello Event Monitor
2020-01-19T23:04:24 [E|app|3c6a22c9] Error occurred while starting Katello::EventMonitor::PollerThread
2020-01-19T23:04:24 [E|app|3c6a22c9] PG::UndefinedTable: ERROR:  relation "katello_events" does not exist
LINE 8:                WHERE a.attrelid = '"katello_events"'::regcla...
                                          ^
:               SELECT a.attname, format_type(a.atttypid, a.atttypmod),
                     pg_get_expr(d.adbin, d.adrelid), a.attnotnull, a.atttypid, a.atttypmod,
                     c.collname, col_description(a.attrelid, a.attnum) AS comment
                FROM pg_attribute a
                LEFT JOIN pg_attrdef d ON a.attrelid = d.adrelid AND a.attnum = d.adnum
                LEFT JOIN pg_type t ON a.atttypid = t.oid
                LEFT JOIN pg_collation c ON a.attcollation = c.oid AND a.attcollation <> t.typcollation
               WHERE a.attrelid = '"katello_events"'::regclass
                 AND a.attnum > 0 AND NOT a.attisdropped
               ORDER BY a.attnum

2020-01-19T23:04:24 [E|app|3c6a22c9] /opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql/database_statements.rb:63:in `async_exec'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql/database_statements.rb:63:in `block (2 levels) in query'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/dependencies/interlock.rb:48:in `block in permit_concurrent_loads'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/concurrency/share_lock.rb:187:in `yield_shares'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/dependencies/interlock.rb:47:in `permit_concurrent_loads'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql/database_statements.rb:62:in `block in query'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract_adapter.rb:579:in `block (2 levels) in log'
/opt/rh/rh-ruby25/root/usr/share/ruby/monitor.rb:226:in `mon_synchronize'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract_adapter.rb:578:in `block in log'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/notifications/instrumenter.rb:23:in `instrument'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract_adapter.rb:569:in `log'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql/database_statements.rb:61:in `query'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql_adapter.rb:749:in `column_definitions'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract/schema_statements.rb:113:in `columns'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/schema_cache.rb:69:in `columns'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/schema_cache.rb:75:in `columns_hash'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:466:in `load_schema!'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/attributes.rb:234:in `load_schema!'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/attribute_decorators.rb:51:in `load_schema!'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:459:in `block in load_schema'
/opt/rh/rh-ruby25/root/usr/share/ruby/monitor.rb:226:in `mon_synchronize'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:456:in `load_schema'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:346:in `attribute_types'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:370:in `type_for_attribute'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/table_metadata.rb:33:in `type'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:51:in `build'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:107:in `block in expand_from_hash'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:71:in `each'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:71:in `flat_map'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:71:in `expand_from_hash'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:21:in `build_from_hash'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/where_clause_factory.rb:19:in `build'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/query_methods.rb:591:in `where!'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/query_methods.rb:584:in `where'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/querying.rb:12:in `where'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_queue.rb:42:in `reset_in_progress'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_monitor/poller_thread.rb:23:in `run'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:31:in `block in check_services'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:20:in `each'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:20:in `check_services'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:13:in `block (2 levels) in start'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/execution_wrapper.rb:87:in `wrap'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:12:in `block in start'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:11:in `loop'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:11:in `start'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:117:in `block in start_monitor_thread'
/opt/theforeman/tfm/root/usr/share/gems/gems/logging-2.2.2/lib/logging/diagnostic_context.rb:474:in `block in create_with_logging_context'
2020-01-19T23:04:39 [E|kat|3c6a22c9] Katello has not been configured for qpid.url and qpid.subscriptions_queue_address
2020-01-19T23:04:39 [E|kat|3c6a22c9] <Array> ["/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/candlepin_event_listener.rb:70:in `initialize_listening_service'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/candlepin_event_listener.rb:12:in `run'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:31:in `block in check_services'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:20:in `each'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:20:in `check_services'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:13:in `block (2 levels) in start'", "/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/execution_wrapper.rb:87:in `wrap'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:12:in `block in start'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:11:in `loop'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:11:in `start'", "/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:117:in `block in start_monitor_thread'", "/opt/theforeman/tfm/root/usr/share/gems/gems/logging-2.2.2/lib/logging/diagnostic_context.rb:474:in `block in create_with_logging_context'"]
2020-01-19T23:04:39 [E|kat|3c6a22c9] Fatal error in Candlepin Listening Service
2020-01-19T23:04:39 [E|app|3c6a22c9] Error occurred while starting Katello::CandlepinEventListener
2020-01-19T23:04:39 [E|app|3c6a22c9] undefined method `start' for nil:NilClass
2020-01-19T23:04:39 [E|app|3c6a22c9] /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/candlepin_event_listener.rb:14:in `run'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:31:in `block in check_services'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:20:in `each'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:20:in `check_services'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:13:in `block (2 levels) in start'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/execution_wrapper.rb:87:in `wrap'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:12:in `block in start'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:11:in `loop'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:11:in `start'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:117:in `block in start_monitor_thread'
/opt/theforeman/tfm/root/usr/share/gems/gems/logging-2.2.2/lib/logging/diagnostic_context.rb:474:in `block in create_with_logging_context'
2020-01-19T23:04:39 [I|kat|3c6a22c9] Stopping Katello Event Monitor
2020-01-19T23:04:39 [E|app|3c6a22c9] Error occurred while starting Katello::EventMonitor::PollerThread
2020-01-19T23:04:39 [E|app|3c6a22c9] PG::UndefinedTable: ERROR:  relation "katello_events" does not exist
LINE 8:                WHERE a.attrelid = '"katello_events"'::regcla...
                                          ^
:               SELECT a.attname, format_type(a.atttypid, a.atttypmod),
                     pg_get_expr(d.adbin, d.adrelid), a.attnotnull, a.atttypid, a.atttypmod,
                     c.collname, col_description(a.attrelid, a.attnum) AS comment
                FROM pg_attribute a
                LEFT JOIN pg_attrdef d ON a.attrelid = d.adrelid AND a.attnum = d.adnum
                LEFT JOIN pg_type t ON a.atttypid = t.oid
                LEFT JOIN pg_collation c ON a.attcollation = c.oid AND a.attcollation <> t.typcollation
               WHERE a.attrelid = '"katello_events"'::regclass
                 AND a.attnum > 0 AND NOT a.attisdropped
               ORDER BY a.attnum

2020-01-19T23:04:39 [E|app|3c6a22c9] /opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql/database_statements.rb:63:in `async_exec'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql/database_statements.rb:63:in `block (2 levels) in query'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/dependencies/interlock.rb:48:in `block in permit_concurrent_loads'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/concurrency/share_lock.rb:187:in `yield_shares'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/dependencies/interlock.rb:47:in `permit_concurrent_loads'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql/database_statements.rb:62:in `block in query'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract_adapter.rb:579:in `block (2 levels) in log'
/opt/rh/rh-ruby25/root/usr/share/ruby/monitor.rb:226:in `mon_synchronize'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract_adapter.rb:578:in `block in log'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/notifications/instrumenter.rb:23:in `instrument'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract_adapter.rb:569:in `log'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql/database_statements.rb:61:in `query'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/postgresql_adapter.rb:749:in `column_definitions'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract/schema_statements.rb:113:in `columns'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/schema_cache.rb:69:in `columns'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/connection_adapters/schema_cache.rb:75:in `columns_hash'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:466:in `load_schema!'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/attributes.rb:234:in `load_schema!'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/attribute_decorators.rb:51:in `load_schema!'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:459:in `block in load_schema'
/opt/rh/rh-ruby25/root/usr/share/ruby/monitor.rb:226:in `mon_synchronize'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:456:in `load_schema'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:346:in `attribute_types'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:370:in `type_for_attribute'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/table_metadata.rb:33:in `type'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:51:in `build'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:107:in `block in expand_from_hash'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:71:in `each'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:71:in `flat_map'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:71:in `expand_from_hash'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:21:in `build_from_hash'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/where_clause_factory.rb:19:in `build'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/query_methods.rb:591:in `where!'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/relation/query_methods.rb:584:in `where'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activerecord-5.2.1/lib/active_record/querying.rb:12:in `where'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_queue.rb:42:in `reset_in_progress'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_monitor/poller_thread.rb:23:in `run'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:31:in `block in check_services'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:20:in `each'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:20:in `check_services'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:13:in `block (2 levels) in start'
/opt/theforeman/tfm-ror52/root/usr/share/gems/gems/activesupport-5.2.1/lib/active_support/execution_wrapper.rb:87:in `wrap'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:12:in `block in start'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:11:in `loop'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:11:in `start'
/opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.15.0.pre.master/app/services/katello/event_daemon.rb:117:in `block in start_monitor_thread'
/opt/theforeman/tfm/root/usr/share/gems/gems/logging-2.2.2/lib/logging/diagnostic_context.rb:474:in `block in create_with_logging_context'
2020-01-19T23:04:53 [I|kat|] Stopping Katello Event Monitor
2020-01-19T23:04:53 [I|dyn|] start terminating throttle_limiter...
2020-01-19T23:04:53 [I|dyn|] start terminating client dispatcher...
2020-01-19T23:04:53 [I|dyn|] stop listening for new events...
2020-01-19T23:04:53 [I|dyn|] start terminating clock...
2020-01-19T23:15:09 [I|app|] Rails cache backend: File
2020-01-19T23:15:15 [W|app|] Creating scope :path_of. Overwriting existing method Hostgroup.path_of.
2020-01-19T23:15:15 [W|app|] Creating scope :path_of. Overwriting existing method Taxonomy.path_of.
2020-01-19T23:15:15 [W|app|] Creating scope :completer_scope. Overwriting existing method Organization.completer_scope.
2020-01-19T23:15:16 [W|app|] Scoped order is ignored, it's forced to be batch order.
2020-01-19T23:15:17 [W|app|] Creating scope :completer_scope. Overwriting existing method Location.completer_scope.
2020-01-19T23:15:17 [W|app|] Creating scope :path_of. Overwriting existing method FactName.path_of.
2020-01-19T23:15:28 [I|dyn|] start terminating throttle_limiter...
2020-01-19T23:15:28 [I|dyn|] start terminating client dispatcher...
2020-01-19T23:15:28 [I|dyn|] stop listening for new events...
2020-01-19T23:15:28 [I|dyn|] start terminating clock...

Katello 3.15 hasn’t been released yet; It is a release that will be compatible with Foreman 2.0 and is not compatible with 1.24.
You should install Katello 3.14 with Foreman 1.24.

So i have upgraded the foreman to the Version 2.0 and katello to the version 3.15 and still as the same error

I would highly recommend using Foreman 1.24 and Katello 3.14, as Foreman 2.0 and Katello 3.15 are nightly releases that are often unstable.

I have downgraded the packages to the recommended version but still the same issue

 ~]# foreman-installer
Notice: /Package[rh-redis5-redis]/ensure: created
package { 'rh-redis5-redis':
  ensure   => '5.0.5-1.el7',
  provider => 'yum',
}
/opt/puppetlabs/bin/puppet resource package rh-redis5-redis ensure=installed finished successfully!
 '/usr/sbin/foreman-rake db:migrate' returned 1 instead of one of [0]
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/errors.rb:157:in `fail'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/type/exec.rb:183:in `sync'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction/resource_harness.rb:241:in `sync'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction/resource_harness.rb:136:in `sync_if_needed'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction/resource_harness.rb:90:in `block in perform_changes'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction/resource_harness.rb:89:in `each'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction/resource_harness.rb:89:in `perform_changes'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction/resource_harness.rb:21:in `evaluate'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:263:in `apply'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:283:in `eval_resource'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:187:in `call'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:187:in `block (2 levels) in evaluate'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:521:in `block in thinmark'
/opt/puppetlabs/puppet/lib/ruby/2.5.0/benchmark.rb:308:in `realtime'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:520:in `thinmark'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:187:in `block in evaluate'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/graph/relationship_graph.rb:122:in `traverse'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:174:in `evaluate'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/resource/catalog.rb:240:in `block (2 levels) in apply'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:521:in `block in thinmark'
/opt/puppetlabs/puppet/lib/ruby/2.5.0/benchmark.rb:308:in `realtime'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:520:in `thinmark'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/resource/catalog.rb:239:in `block in apply'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/log.rb:161:in `with_destination'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction/report.rb:146:in `as_logging_destination'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/resource/catalog.rb:238:in `apply'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:194:in `block (2 levels) in apply_catalog'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:521:in `block in thinmark'
/opt/puppetlabs/puppet/lib/ruby/2.5.0/benchmark.rb:308:in `realtime'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:520:in `thinmark'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:193:in `block in apply_catalog'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:233:in `block in benchmark'
/opt/puppetlabs/puppet/lib/ruby/2.5.0/benchmark.rb:308:in `realtime'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:232:in `benchmark'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:192:in `apply_catalog'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:381:in `run_internal'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:242:in `block in run'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/context.rb:62:in `override'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet.rb:274:in `override'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:219:in `run'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application/apply.rb:343:in `apply_catalog'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application/apply.rb:260:in `block (2 levels) in main'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/context.rb:62:in `override'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet.rb:274:in `override'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application/apply.rb:243:in `block in main'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/context.rb:62:in `override'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet.rb:274:in `override'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application/apply.rb:207:in `main'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application/apply.rb:177:in `run_command'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application.rb:382:in `block in run'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:687:in `exit_on_fail'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application.rb:382:in `run'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/command_line.rb:143:in `run'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/command_line.rb:77:in `execute'
/opt/puppetlabs/puppet/bin/puppet:5:in `<main>'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/errors.rb:157:in `fail'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/type/exec.rb:183:in `sync'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/type/exec.rb:649:in `refresh'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction/event_manager.rb:149:in `process_callback'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction/event_manager.rb:34:in `block in process_events'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction/event_manager.rb:121:in `block in queued_events'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction/event_manager.rb:120:in `each'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction/event_manager.rb:120:in `queued_events'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction/event_manager.rb:33:in `process_events'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:284:in `eval_resource'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:187:in `call'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:187:in `block (2 levels) in evaluate'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:521:in `block in thinmark'
/opt/puppetlabs/puppet/lib/ruby/2.5.0/benchmark.rb:308:in `realtime'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:520:in `thinmark'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:187:in `block in evaluate'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/graph/relationship_graph.rb:122:in `traverse'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:174:in `evaluate'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/resource/catalog.rb:240:in `block (2 levels) in apply'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:521:in `block in thinmark'
/opt/puppetlabs/puppet/lib/ruby/2.5.0/benchmark.rb:308:in `realtime'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:520:in `thinmark'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/resource/catalog.rb:239:in `block in apply'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/log.rb:161:in `with_destination'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction/report.rb:146:in `as_logging_destination'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/resource/catalog.rb:238:in `apply'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:194:in `block (2 levels) in apply_catalog'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:521:in `block in thinmark'
/opt/puppetlabs/puppet/lib/ruby/2.5.0/benchmark.rb:308:in `realtime'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:520:in `thinmark'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:193:in `block in apply_catalog'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:233:in `block in benchmark'
/opt/puppetlabs/puppet/lib/ruby/2.5.0/benchmark.rb:308:in `realtime'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:232:in `benchmark'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:192:in `apply_catalog'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:381:in `run_internal'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:242:in `block in run'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/context.rb:62:in `override'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet.rb:274:in `override'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:219:in `run'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application/apply.rb:343:in `apply_catalog'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application/apply.rb:260:in `block (2 levels) in main'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/context.rb:62:in `override'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet.rb:274:in `override'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application/apply.rb:243:in `block in main'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/context.rb:62:in `override'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet.rb:274:in `override'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application/apply.rb:207:in `main'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application/apply.rb:177:in `run_command'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application.rb:382:in `block in run'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:687:in `exit_on_fail'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application.rb:382:in `run'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/command_line.rb:143:in `run'
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/command_line.rb:77:in `execute'
/opt/puppetlabs/puppet/bin/puppet:5:in `<main>'
Preparing installation Done
  Something went wrong! Check the log for ERROR-level output
  The full log is at /var/log/foreman-installer/foreman.log

Downgrading of Foreman is probably no good idea. The DB shema is probably not “downgraded” after that since there should be no backwards migrations.
You could try foreman-installer --reset, that should reset the DB, but the best and cleanest option would probably be to scrap the system and start over again.