-
Bug
-
Resolution: Unresolved
-
Major
-
None
-
6.17.0, 6.15.5, 6.16.5
-
Phoenix - Subscriptions
-
False
-
Moderate
-
sat-proton
-
None
-
None
-
None
-
No Coverage
Description of problem:
Client failed to register to the Satellite with following error raised in production.log. It failed to upload profiles.
[I|app|74c983ab] Processing by Katello::Api::Rhsm::CandlepinDynflowProxyController#upload_profiles as JSON [I|app|74c983ab] Parameters: {"id"=>"xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"} [E|app|74c983ab] ActiveRecord::RangeError: PG::NumericValueOutOfRange: ERROR: integer out of range 74c983ab | 74c983ab | /usr/share/gems/gems/activerecord-6.1.7/lib/active_record/connection_adapters/postgresql/database_statements.rb:49:in `exec' 74c983ab | /usr/share/gems/gems/activerecord-6.1.7/lib/active_record/connection_adapters/postgresql/database_statements.rb:49:in `block (2 levels) in execute' 74c983ab | /usr/share/gems/gems/activesupport-6.1.7/lib/active_support/dependencies/interlock.rb:48:in `block in permit_concurrent_loads' 74c983ab | /usr/share/gems/gems/activesupport-6.1.7/lib/active_support/concurrency/share_lock.rb:187:in `yield_shares' 74c983ab | /usr/share/gems/gems/activesupport-6.1.7/lib/active_support/dependencies/interlock.rb:47:in `permit_concurrent_loads' 74c983ab | /usr/share/gems/gems/activerecord-6.1.7/lib/active_record/connection_adapters/postgresql/database_statements.rb:48:in `block in execute' 74c983ab | /usr/share/gems/gems/activerecord-6.1.7/lib/active_record/connection_adapters/abstract_adapter.rb:696:in `block (2 levels) in log' 74c983ab | /usr/share/gems/gems/activesupport-6.1.7/lib/active_support/concurrency/load_interlock_aware_monitor.rb:26:in `block (2 levels) in synchronize' 74c983ab | /usr/share/gems/gems/activesupport-6.1.7/lib/active_support/concurrency/load_interlock_aware_monitor.rb:25:in `handle_interrupt' 74c983ab | /usr/share/gems/gems/activesupport-6.1.7/lib/active_support/concurrency/load_interlock_aware_monitor.rb:25:in `block in synchronize' 74c983ab | /usr/share/gems/gems/activesupport-6.1.7/lib/active_support/concurrency/load_interlock_aware_monitor.rb:21:in `handle_interrupt' 74c983ab | /usr/share/gems/gems/activesupport-6.1.7/lib/active_support/concurrency/load_interlock_aware_monitor.rb:21:in `synchronize' 74c983ab | /usr/share/gems/gems/activerecord-6.1.7/lib/active_record/connection_adapters/abstract_adapter.rb:695:in `block in log' 74c983ab | /usr/share/gems/gems/activesupport-6.1.7/lib/active_support/notifications/instrumenter.rb:24:in `instrument' 74c983ab | /usr/share/gems/gems/activerecord-6.1.7/lib/active_record/connection_adapters/abstract_adapter.rb:687:in `log' 74c983ab | /usr/share/gems/gems/activerecord-6.1.7/lib/active_record/connection_adapters/postgresql/database_statements.rb:47:in `execute' 74c983ab | /usr/share/gems/gems/katello-4.7.0.37/app/models/katello/concerns/host_managed_extensions.rb:329:in `block (2 levels) in sync_package_associations' 74c983ab | /usr/share/gems/gems/katello-4.7.0.37/app/models/katello/concerns/host_managed_extensions.rb:328:in `each' 74c983ab | /usr/share/gems/gems/katello-4.7.0.37/app/models/katello/concerns/host_managed_extensions.rb:328:in `block in sync_package_associations' 74c983ab | /usr/share/gems/gems/katello-4.7.0.37/app/lib/katello/util/support.rb:97:in `active_record_retry' 74c983ab | /usr/share/gems/gems/katello-4.7.0.37/app/models/katello/concerns/host_managed_extensions.rb:310:in `sync_package_associations' 74c983ab | /usr/share/gems/gems/katello-4.7.0.37/app/models/katello/concerns/host_managed_extensions.rb:208:in `import_package_profile' 74c983ab | /usr/share/gems/gems/katello-4.7.0.37/app/services/katello/host/package_profile_uploader.rb:33:in `import_package_profile_for_host' 74c983ab | /usr/share/gems/gems/katello-4.7.0.37/app/services/katello/host/profiles_uploader.rb:27:in `block in upload' 74c983ab | /usr/share/gems/gems/katello-4.7.0.37/app/services/katello/host/profiles_uploader.rb:23:in `each' 74c983ab | /usr/share/gems/gems/katello-4.7.0.37/app/services/katello/host/profiles_uploader.rb:23:in `upload' 74c983ab | /usr/share/gems/gems/katello-4.7.0.37/app/controllers/katello/api/rhsm/candlepin_dynflow_proxy_controller.rb:41:in `block in upload_profiles'
It is because the id of "katello_host_installed_packages" table has reached the maximum integer limit.
# su - postgres -c "psql -d foreman -c 'select max(id) from katello_host_installed_packages;'"
max
------------
2147439559 <================
(1 row)
How reproducible:
Could be time consuming
Is this issue a regression from an earlier version:
No
Steps to Reproduce:
1. To save time. You can change the last value of the 'id' column to something close to the integer limit (2147483647). E.g.
alter sequence katello_host_installed_packages_id_seq restart with 2147482000;
2. Keep register and unregister a client until you get the error.
- is caused by
-
SAT-39139 Review and update the primary keys and their sequences in the Satellite database to support large amount of data in the tables
-
- New
-
- links to