Bug #28831
closedContent View publishing fails after katello_repository_rpms "id" column hits max integer size
Description
Cloned from https://bugzilla.redhat.com/show_bug.cgi?id=1793701
Description of problem:
Content View publishing fails after katello_repository_rpms "id" column hits max integer size
Version-Release number of selected component (if applicable):
Red Hat Satellite 6.6 (but I believe all supported versions would be susceptible)
How reproducible:
Steps to Reproduce:
1. Publish, publish, publish new content until the number of INSERTS (which increment "id" on every new row finally hits Integer max size (or close enough that the next publish would increment it above the Max)
Actual results:
Expected results:
Publishes succeed.
Additional info:
Error in dynflow task:
----------------------------------------------------------------
PG::NumericValueOutOfRange: ERROR: integer out of range
: INSERT INTO katello_repository_rpms (rpm_id, repository_id, created_at, updated_at) VALUES
(494939, 751553, '2020-01-21 14:03:14', '2020-01-21 14:03:14'),
(249613, 751553, '2020-01-21 14:03:14', '2020-01-21 14:03:14'),
(249614, 751553, '2020-01-21 14:03:14', '2020-01-21 14:03:14'),
(393610, 751553, '2020-01-21 14:03:14', '2020-01-21 14:03:14'),
(287208, 751553, '2020-01-21 14:03:14', '2020-01-21 14:03:14'),
(249616, 751553, '2020-01-21 14:03:14', '2020-01-21 14:03:14'),
(397182, 751553, '2020-01-21 14:03:14', '2020-01-21 14:03:14'),
(353289, 751553, '2020-01-21 14:03:14', '2020-01-21 14:03:14'),
(228061, 751553, '2020-01-21 14:03:14', '2020-01-21 14:03:14'),
(383234, 751553, '2020-01-21 14:03:14', '2020-01-21 14:03:14'),
(369162, 751553, '2020-01-21 14:03:14', '2020-01-21 14:03:14'),
(488882, 751553, '2020-01-21 14:03:14', '2020-01-21 14:03:14'),
(365164, 751553, '2020-01-21 14:03:14', '2020-01-21 14:03:14'),
(494940, 751553, '2020-01-21 14:03:14', '2020-01-21 14:03:14'),
(393611, 751553, '2020-01-21 14:03:14', '2020-01-21 14:03:14'),
(430253, 751553, '2020-01-21 14:03:14', '2020-01-21 14:03:14'),
(228062, 751553, '2020-01-21 14:03:14', '2020-01-21 14:03:14'),
(489006, 751553, '2020-01-21 14:03:14', '2020-01-21 14:03:14'),
(228871, 751553, '2020-01-21 14:03:14', '2020-01-21 14:03:14'),
(365425, 751553, '2020-01-21 14:03:14', '2020-01-21 14:03:14'),
(256320, 751553, '2020-01-21 14:03:14', '2020-01-21 14:03:14'),
(420443, 751553, '2020-01-21 14:03:14', '2020-01-21 14:03:14'),
(365426, 751553, '2020-01-21 14:03:14', '2020-01-21 14:03:14'),
(398249, 751553, '2020-01-21 14:03:14', '2020-01-21 14:03:14'),
(431032, 751553, '2020-01-21 14:03:14', '2020-01-21 14:03:14'),
(487077, 751553, '2020-01-21 14:03:14', '2020-01-21 14:03:14')
----------------------------------------------
As neither of the two integers being inserted above (rpm_id, or repository_id) appear to be anywhere close to the integer max size, they're unlikely to be the culprits.
--------------------------------------------------
foreman=# \d katello_repository_rpms
Table "public.katello_repository_rpms"
Column | Type | Modifiers
---------------+-----------------------------+----------------------------------------------------------------------
id | integer | not null default nextval('katello_repository_rpms_id_seq'::regclass)
rpm_id | integer | not null
repository_id | integer |
created_at | timestamp without time zone |
updated_at | timestamp without time zone |
Indexes:
"katello_repository_rpms_pkey" PRIMARY KEY, btree (id)
"index_katello_repository_rpms_on_rpm_id_and_repository_id" UNIQUE, btree (rpm_id, repository_id)
"index_katello_repository_rpms_on_repository_id" btree (repository_id)
Foreign-key constraints:
"katello_repository_rpms_repository_id_fk" FOREIGN KEY (repository_id) REFERENCES katello_repositories(id)
"katello_repository_rpms_rpm_id_fk" FOREIGN KEY (rpm_id) REFERENCES katello_rpms(id)
foreman=#
--------------------------------------------------------------
Rather, it is the "id" that is incremented on every new row that is hitting the max, and the following shows that it's currently super close.
foreman=# select MAX from katello_repository_rpms;
max
------------
2147478931
(1 row)
Updated by The Foreman Bot almost 5 years ago
- Status changed from New to Ready For Testing
- Assignee set to Justin Sherrill
- Pull request https://github.com/Katello/katello/pull/8537 added
Updated by The Foreman Bot almost 5 years ago
- Fixed in Releases Katello 3.16.0 added
Updated by Justin Sherrill almost 5 years ago
- Status changed from Ready For Testing to Closed
Applied in changeset katello|109ab4805a4b72e4a6ca58316470c17fa1c39297.
Updated by Samir Jha almost 5 years ago
- Category changed from 111 to Content Views
- Target version set to Katello 3.15.0
- Triaged changed from No to Yes
Updated by Markus Bucher 6 months ago
- Related to Bug #37585: katello_repository_debs "id" column hits max integer size added