Actions
Issue #1707
closedRepository's repo_id duplicate key error on upgrade
Start date:
Due date:
Estimated time:
Severity:
3. High
Version:
Platform Release:
2.8.0
OS:
Triaged:
Yes
Groomed:
No
Sprint Candidate:
No
Tags:
Pulp 2
Sprint:
Quarter:
Description
http://projects.theforeman.org/issues/13807
Feb 18 13:35:01 centos7-2-4 pulp: py.warnings:WARNING: (11302-47008)
Feb 18 13:35:01 centos7-2-4 pulp: pulp.server.db.manage:INFO: Migration to pulp_rpm.plugins.migrations version 23 complete.
Feb 18 13:35:01 centos7-2-4 pulp: pulp.server.db.manage:INFO: Applying pulp_rpm.plugins.migrations version 24
Feb 18 13:35:01 centos7-2-4 pulp: pulp.server.db.manage:INFO: Migration to pulp_rpm.plugins.migrations version 24 complete.
Feb 18 13:35:01 centos7-2-4 pulp: pulp.server.db.manage:CRITICAL: E11000 duplicate key error index: pulp_database.repos.$repo_id_-1 dup key: { : null }
Feb 18 13:35:01 centos7-2-4 pulp: pulp.server.db.manage:CRITICAL: (11302-47008) Traceback (most recent call last):
Feb 18 13:35:01 centos7-2-4 pulp: pulp.server.db.manage:CRITICAL: (11302-47008) File "/usr/lib/python2.7/site-packages/pulp/server/db/manage.py", line 183, in main
Feb 18 13:35:01 centos7-2-4 pulp: pulp.server.db.manage:CRITICAL: (11302-47008) return _auto_manage_db(options)
Feb 18 13:35:01 centos7-2-4 pulp: pulp.server.db.manage:CRITICAL: (11302-47008) File "/usr/lib/python2.7/site-packages/pulp/server/db/manage.py", line 246, in _auto_manage_db
Feb 18 13:35:01 centos7-2-4 pulp: pulp.server.db.manage:CRITICAL: (11302-47008) migrate_database(options)
Feb 18 13:35:01 centos7-2-4 pulp: pulp.server.db.manage:CRITICAL: (11302-47008) File "/usr/lib/python2.7/site-packages/pulp/server/db/manage.py", line 142, in migrate_database
Feb 18 13:35:01 centos7-2-4 pulp: pulp.server.db.manage:CRITICAL: (11302-47008) ensure_database_indexes()
Feb 18 13:35:01 centos7-2-4 pulp: pulp.server.db.manage:CRITICAL: (11302-47008) File "/usr/lib/python2.7/site-packages/pulp/server/db/manage.py", line 157, in ensure_database_indexes
Feb 18 13:35:01 centos7-2-4 pulp: pulp.server.db.manage:CRITICAL: (11302-47008) model.Repository.ensure_indexes()
Feb 18 13:35:01 centos7-2-4 pulp: pulp.server.db.manage:CRITICAL: (11302-47008) File "/usr/lib/python2.7/site-packages/mongoengine/document.py", line 738, in ensure_indexes
Feb 18 13:35:01 centos7-2-4 pulp: pulp.server.db.manage:CRITICAL: (11302-47008) collection = cls._get_collection()
Feb 18 13:35:01 centos7-2-4 pulp: pulp.server.db.manage:CRITICAL: (11302-47008) File "/usr/lib/python2.7/site-packages/mongoengine/document.py", line 210, in _get_collection
Feb 18 13:35:01 centos7-2-4 pulp: pulp.server.db.manage:CRITICAL: (11302-47008) cls.ensure_indexes()
Feb 18 13:35:01 centos7-2-4 pulp: pulp.server.db.manage:CRITICAL: (11302-47008) File "/usr/lib/python2.7/site-packages/mongoengine/document.py", line 766, in ensure_indexes
Feb 18 13:35:01 centos7-2-4 pulp: pulp.server.db.manage:CRITICAL: (11302-47008) collection.create_index(fields, background=background, **opts)
Feb 18 13:35:01 centos7-2-4 pulp: pulp.server.db.manage:CRITICAL: (11302-47008) File "/usr/lib64/python2.7/site-packages/pymongo/collection.py", line 1380, in create_index
Feb 18 13:35:01 centos7-2-4 pulp: pulp.server.db.manage:CRITICAL: (11302-47008) self.__create_index(keys, kwargs)
Feb 18 13:35:01 centos7-2-4 pulp: pulp.server.db.manage:CRITICAL: (11302-47008) File "/usr/lib64/python2.7/site-packages/pymongo/collection.py", line 1290, in __create_index
Feb 18 13:35:01 centos7-2-4 pulp: pulp.server.db.manage:CRITICAL: (11302-47008) sock_info, cmd, read_preference=ReadPreference.PRIMARY)
Feb 18 13:35:01 centos7-2-4 pulp: pulp.server.db.manage:CRITICAL: (11302-47008) File "/usr/lib64/python2.7/site-packages/pymongo/collection.py", line 205, in _command
Feb 18 13:35:01 centos7-2-4 pulp: pulp.server.db.manage:CRITICAL: (11302-47008) read_concern=read_concern)
Feb 18 13:35:01 centos7-2-4 pulp: pulp.server.db.manage:CRITICAL: (11302-47008) File "/usr/lib64/python2.7/site-packages/pymongo/pool.py", line 211, in command
Feb 18 13:35:01 centos7-2-4 pulp: pulp.server.db.manage:CRITICAL: (11302-47008) read_concern)
Feb 18 13:35:01 centos7-2-4 pulp: pulp.server.db.manage:CRITICAL: (11302-47008) File "/usr/lib64/python2.7/site-packages/pymongo/network.py", line 100, in command
Feb 18 13:35:01 centos7-2-4 pulp: pulp.server.db.manage:CRITICAL: (11302-47008) helpers._check_command_response(response_doc, msg, allowable_errors)
Feb 18 13:35:01 centos7-2-4 pulp: pulp.server.db.manage:CRITICAL: (11302-47008) File "/usr/lib64/python2.7/site-packages/pymongo/helpers.py", line 189, in _check_command_response
Feb 18 13:35:01 centos7-2-4 pulp: pulp.server.db.manage:CRITICAL: (11302-47008) raise DuplicateKeyError(errmsg, code, response)
Feb 18 13:35:01 centos7-2-4 pulp: pulp.server.db.manage:CRITICAL: (11302-47008) DuplicateKeyError: E11000 duplicate key error index: pulp_database.repos.$repo_id_-1 dup key: { : null }
I believe that this is due to renaming a field before dropping the index.
Updated by amacdona@redhat.com almost 9 years ago
- Priority changed from Normal to High
- Severity changed from 2. Medium to 3. High
- Platform Release set to 2.8.0
Updated by amacdona@redhat.com almost 9 years ago
- Status changed from ASSIGNED to POST
Added by Austin Macdonald almost 9 years ago
Added by Austin Macdonald almost 9 years ago
Revision 109e2655 | View on GitHub
fix repository migration
closes #1707
Updated by Anonymous almost 9 years ago
- Status changed from POST to MODIFIED
- % Done changed from 0 to 100
Applied in changeset pulp|109e26551ef1f1077dd53117df659d307f6806f3.
Updated by amacdona@redhat.com almost 9 years ago
- Triaged changed from No to Yes
Updated by dkliban@redhat.com almost 9 years ago
- Status changed from MODIFIED to 5
Updated by pthomas@redhat.com almost 9 years ago
- Status changed from 5 to 6
verified
Migration passes for
2.6->2.8 & 2.7 -> 2.8
Updated by dkliban@redhat.com almost 9 years ago
- Status changed from 6 to CLOSED - CURRENTRELEASE
Actions
fix repository migration
closes #1707