Red Hat Satellite engineering is moving the tracking of its product development work on Satellite to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "Satellite project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs will be migrated starting at the end of May. If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "Satellite project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/SAT-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1325339 - Repository synchronization fails with "not a valid ObjectId, it must be a 12-byte input or a 24-character hex string"
Summary: Repository synchronization fails with "not a valid ObjectId, it must be a 12-...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Pulp
Version: 6.2.0
Hardware: Unspecified
OS: Unspecified
unspecified
urgent
Target Milestone: Unspecified
Assignee: satellite6-bugs
QA Contact: jcallaha
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-04-08 13:19 UTC by Og Maciel
Modified: 2019-09-25 21:18 UTC (History)
4 users (show)

Fixed In Version: pulp-2.8.1.3-1
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-07-27 09:31:11 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
foreman-debug logs (501.98 KB, application/octet-stream)
2016-04-08 13:23 UTC, Og Maciel
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2016:1501 0 normal SHIPPED_LIVE Red Hat Satellite 6.2 Capsule and Server 2016-07-27 12:28:58 UTC

Description Og Maciel 2016-04-08 13:19:40 UTC
Description of problem:

Our automation and existing systems that were updated to SNAP 7.0 show that synchronization of repositories (YUM) are failing with the following error message showing on /var/log/messages:

    pulp: pulp.server.webservices.middleware.exception:ERROR: (6458-96512) InvalidId: '00011577-1c82-4e91-a589-586652d5987e' is not a valid ObjectId, it must be a 12-byte input or a 24-character hex string

This is a regression from previous snap.

Version-Release number of selected component (if applicable):

* Satellite 6.2.0 SNAP 7.0

How reproducible:


Steps to Reproduce:
1. Synchronize a YUM repository
2.
3.

Actual results:

Web ui will show a warning: 500 Internal Server Error

Expected results:


Additional info:

Apr  7 21:24:28 ibm-x3250m4-01 pulp: py.warnings:WARNING: (6421-70400) /usr/lib/python2.7/site-packages/pulp/server/controllers/repository.py:1065: DeprecationWarning: save is deprecated. Use insert_one or replace_one instead
Apr  7 21:24:28 ibm-x3250m4-01 pulp: py.warnings:WARNING: (6421-70400)   publish_result_coll.save(result)
Apr  7 21:24:28 ibm-x3250m4-01 pulp: py.warnings:WARNING: (6421-70400)
Apr  7 21:24:28 ibm-x3250m4-01 pulp: celery.worker.job:INFO: Task pulp.server.managers.repo.publish.publish[125df6e0-2f91-4b9e-95e8-e85a0b08524a] succeeded in 3.570729938s: {'exception': None, 'repo_id':...
Apr  7 21:24:28 ibm-x3250m4-01 pulp: celery.worker.job:INFO: Task pulp.server.async.tasks._release_resource[04daccd1-7dac-4630-8b57-98c8e49afdbb] succeeded in 0.00385127200025s: None
Apr  7 21:24:32 ibm-x3250m4-01 pulp: pulp.server.webservices.middleware.exception:ERROR: Unhandled Exception
Apr  7 21:24:32 ibm-x3250m4-01 pulp: pulp.server.webservices.middleware.exception:ERROR: (6458-96512) '00011577-1c82-4e91-a589-586652d5987e' is not a valid ObjectId, it must be a 12-byte input or a 24-character hex string
Apr  7 21:24:32 ibm-x3250m4-01 pulp: pulp.server.webservices.middleware.exception:ERROR: (6458-96512) Traceback (most recent call last):
Apr  7 21:24:32 ibm-x3250m4-01 pulp: pulp.server.webservices.middleware.exception:ERROR: (6458-96512)   File "/usr/lib/python2.7/site-packages/django/core/handlers/base.py", line 112, in get_response
Apr  7 21:24:32 ibm-x3250m4-01 pulp: pulp.server.webservices.middleware.exception:ERROR: (6458-96512)     response = wrapped_callback(request, *callback_args, **callback_kwargs)
Apr  7 21:24:32 ibm-x3250m4-01 pulp: pulp.server.webservices.middleware.exception:ERROR: (6458-96512)   File "/usr/lib/python2.7/site-packages/django/views/generic/base.py", line 69, in view
Apr  7 21:24:32 ibm-x3250m4-01 pulp: pulp.server.webservices.middleware.exception:ERROR: (6458-96512)     return self.dispatch(request, *args, **kwargs)
Apr  7 21:24:32 ibm-x3250m4-01 pulp: pulp.server.webservices.middleware.exception:ERROR: (6458-96512)   File "/usr/lib/python2.7/site-packages/django/views/generic/base.py", line 87, in dispatch
Apr  7 21:24:32 ibm-x3250m4-01 pulp: pulp.server.webservices.middleware.exception:ERROR: (6458-96512)     return handler(request, *args, **kwargs)
Apr  7 21:24:32 ibm-x3250m4-01 pulp: pulp.server.webservices.middleware.exception:ERROR: (6458-96512)   File "/usr/lib/python2.7/site-packages/pulp/server/webservices/views/decorators.py", line 241, in _auth_decorator
Apr  7 21:24:32 ibm-x3250m4-01 pulp: pulp.server.webservices.middleware.exception:ERROR: (6458-96512)     return _verify_auth(self, operation, super_user_only, method, *args, **kwargs)
Apr  7 21:24:32 ibm-x3250m4-01 pulp: pulp.server.webservices.middleware.exception:ERROR: (6458-96512)   File "/usr/lib/python2.7/site-packages/pulp/server/webservices/views/decorators.py", line 195, in _verify_auth
Apr  7 21:24:32 ibm-x3250m4-01 pulp: pulp.server.webservices.middleware.exception:ERROR: (6458-96512)     value = method(self, *args, **kwargs)
Apr  7 21:24:32 ibm-x3250m4-01 pulp: pulp.server.webservices.middleware.exception:ERROR: (6458-96512)   File "/usr/lib/python2.7/site-packages/pulp/server/webservices/views/util.py", line 130, in wrapper
Apr  7 21:24:32 ibm-x3250m4-01 pulp: pulp.server.webservices.middleware.exception:ERROR: (6458-96512)     return func(*args, **kwargs)
Apr  7 21:24:32 ibm-x3250m4-01 pulp: pulp.server.webservices.middleware.exception:ERROR: (6458-96512)   File "/usr/lib/python2.7/site-packages/pulp/server/webservices/views/search.py", line 127, in post
Apr  7 21:24:32 ibm-x3250m4-01 pulp: pulp.server.webservices.middleware.exception:ERROR: (6458-96512)     return self._generate_response(query, options, *args, **kwargs)
Apr  7 21:24:32 ibm-x3250m4-01 pulp: pulp.server.webservices.middleware.exception:ERROR: (6458-96512)   File "/usr/lib/python2.7/site-packages/pulp/server/webservices/views/search.py", line 195, in _generate_response
Apr  7 21:24:32 ibm-x3250m4-01 pulp: pulp.server.webservices.middleware.exception:ERROR: (6458-96512)     *args, **kwargs))
Apr  7 21:24:32 ibm-x3250m4-01 pulp: pulp.server.webservices.middleware.exception:ERROR: (6458-96512)   File "/usr/lib/python2.7/site-packages/pulp/server/webservices/views/content.py", line 293, in get_results
Apr  7 21:24:32 ibm-x3250m4-01 pulp: pulp.server.webservices.middleware.exception:ERROR: (6458-96512)     query['filters'] = serializer.translate_filters(serializer.model, query['filters'])
Apr  7 21:24:32 ibm-x3250m4-01 pulp: pulp.server.webservices.middleware.exception:ERROR: (6458-96512)   File "/usr/lib/python2.7/site-packages/pulp/server/webservices/views/serializers/__init__.py", line 210, in translate_filters
Apr  7 21:24:32 ibm-x3250m4-01 pulp: pulp.server.webservices.middleware.exception:ERROR: (6458-96512)     new_value = self._translate__id(value)
Apr  7 21:24:32 ibm-x3250m4-01 pulp: pulp.server.webservices.middleware.exception:ERROR: (6458-96512)   File "/usr/lib/python2.7/site-packages/pulp/server/webservices/views/serializers/__init__.py", line 276, in _translate__id
Apr  7 21:24:32 ibm-x3250m4-01 pulp: pulp.server.webservices.middleware.exception:ERROR: (6458-96512)     translated[key] = [ObjectId(str_id) for str_id in value]
Apr  7 21:24:32 ibm-x3250m4-01 pulp: pulp.server.webservices.middleware.exception:ERROR: (6458-96512)   File "/usr/lib64/python2.7/site-packages/bson/objectid.py", line 110, in __init__
Apr  7 21:24:32 ibm-x3250m4-01 pulp: pulp.server.webservices.middleware.exception:ERROR: (6458-96512)     self.__validate(oid)
Apr  7 21:24:32 ibm-x3250m4-01 pulp: pulp.server.webservices.middleware.exception:ERROR: (6458-96512)   File "/usr/lib64/python2.7/site-packages/bson/objectid.py", line 206, in __validate
Apr  7 21:24:32 ibm-x3250m4-01 pulp: pulp.server.webservices.middleware.exception:ERROR: (6458-96512)     _raise_invalid_id(oid)
Apr  7 21:24:32 ibm-x3250m4-01 pulp: pulp.server.webservices.middleware.exception:ERROR: (6458-96512)   File "/usr/lib64/python2.7/site-packages/bson/objectid.py", line 52, in _raise_invalid_id
Apr  7 21:24:32 ibm-x3250m4-01 pulp: pulp.server.webservices.middleware.exception:ERROR: (6458-96512)     " or a 24-character hex string" %% oid)
Apr  7 21:24:32 ibm-x3250m4-01 pulp: pulp.server.webservices.middleware.exception:ERROR: (6458-96512) InvalidId: '00011577-1c82-4e91-a589-586652d5987e' is not a valid ObjectId, it must be a 12-byte input or a 24-character hex string

Comment 1 Og Maciel 2016-04-08 13:23:33 UTC
Created attachment 1145138 [details]
foreman-debug logs

Comment 3 Mike McCune 2016-04-08 17:04:12 UTC
This is solved via 1320225, which is MODIFIED

We can leave this (vs a dupe) if QE wants to test this scenario specifically.

Comment 4 jcallaha 2016-04-11 17:54:32 UTC
Verified in Satellite 6.2 Beta Snap 7 Compose 1.

Comment 6 errata-xmlrpc 2016-07-27 09:31:11 UTC
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/RHBA-2016:1501


Note You need to log in before you can comment on or make changes to this bug.