Issue #5978
Updated by ttereshc almost 5 years ago
~~~ $ http POST :24817/pulp/api/v3/migration-plans/ plan='{"plugins": [{"type": "docker"}, {"type": "iso"}]}' HTTP/1.1 201 Created Allow: GET, POST, HEAD, OPTIONS Connection: close Content-Length: 181 Content-Type: application/json Date: Mon, 13 Jan 2020 19:44:05 GMT Location: /pulp/api/v3/migration-plans/d9c27334-69bb-4494-84ab-68e6c9b16c60/ Server: gunicorn/20.0.4 Vary: Accept, Cookie X-Frame-Options: SAMEORIGIN { "plan": { "plugins": [ { "type": "docker" }, { "type": "iso" } ] }, "pulp_created": "2020-01-13T19:44:05.324425Z", "pulp_href": "/pulp/api/v3/migration-plans/d9c27334-69bb-4494-84ab-68e6c9b16c60/" } (pulp) [vagrant@pulp2-nightly-pulp3-source-centos7 pulp-2to3-migration]$ http POST :24817/pulp/api/v3/migration-plans/d9c27334-69bb-4494-84ab-68e6c9b16c60/run/ HTTP/1.1 202 Accepted Allow: POST, OPTIONS Connection: close Content-Length: 67 Content-Type: application/json Date: Mon, 13 Jan 2020 19:44:14 GMT Server: gunicorn/20.0.4 Vary: Accept, Cookie X-Frame-Options: SAMEORIGIN { "task": "/pulp/api/v3/tasks/35bc9b8d-6e8e-4de5-947c-501e8fb1a65d/" } (pulp) [vagrant@pulp2-nightly-pulp3-source-centos7 pulp-2to3-migration]$ http GET :24817/pulp/api/v3/tasks/35bc9b8d-6e8e-4de5-947c-501e8fb1a65d/ HTTP/1.1 200 OK Allow: GET, PATCH, DELETE, HEAD, OPTIONS Connection: close Content-Length: 5065 Content-Type: application/json Date: Mon, 13 Jan 2020 19:44:27 GMT Server: gunicorn/20.0.4 Vary: Accept, Cookie X-Frame-Options: SAMEORIGIN { "created_resources": [], "error": { "description": "duplicate key value violates unique constraint \"core_repository_name_key\"\nDETAIL: Key (name)=(file) already exists.\n", "traceback": " File \"/usr/local/lib/pulp/lib64/python3.6/site-packages/rq/worker.py\", line 875, in perform_job\n rv = job.perform()\n File \"/usr/local/lib/pulp/lib64/python3.6/site-packages/rq/job.py\", line 648, in perform\n self._result = self._execute()\n File \"/usr/local/lib/pulp/lib64/python3.6/site-packages/rq/job.py\", line 654, in _execute\n return self.func(*self.args, **self.kwargs)\n File \"/home/vagrant/devel/pulp-2to3-migration/pulp_2to3_migration/app/tasks/migrate.py\", line 109, in migrate_from_pulp2\n loop.run_until_complete(migrate_repositories(plan))\n File \"/usr/lib64/python3.6/asyncio/base_events.py\", line 484, in run_until_complete\n return future.result()\n File \"/home/vagrant/devel/pulp-2to3-migration/pulp_2to3_migration/app/migration.py\", line 75, in migrate_repositories\n defaults={'description': pulp2repo.pulp2_description})\n File \"/usr/local/lib/pulp/lib64/python3.6/site-packages/django/db/models/manager.py\", line 82, in manager_method\n return getattr(self.get_queryset(), name)(*args, **kwargs)\n File \"/usr/local/lib/pulp/lib64/python3.6/site-packages/django/db/models/query.py\", line 541, in get_or_create\n return self._create_object_from_params(kwargs, params)\n File \"/usr/local/lib/pulp/lib64/python3.6/site-packages/django/db/models/query.py\", line 583, in _create_object_from_params\n raise e\n File \"/usr/local/lib/pulp/lib64/python3.6/site-packages/django/db/models/query.py\", line 575, in _create_object_from_params\n obj = self.create(**params)\n File \"/usr/local/lib/pulp/lib64/python3.6/site-packages/django/db/models/query.py\", line 422, in create\n obj.save(force_insert=True, using=self.db)\n File \"/home/vagrant/devel/pulpcore/pulpcore/app/models/repository.py\", line 63, in save\n super().save(*args, **kwargs)\n File \"/home/vagrant/devel/pulpcore/pulpcore/app/models/base.py\", line 107, in save\n return super().save(*args, **kwargs)\n File \"/usr/local/lib/pulp/lib64/python3.6/site-packages/django/db/models/base.py\", line 741, in save\n force_update=force_update, update_fields=update_fields)\n File \"/usr/local/lib/pulp/lib64/python3.6/site-packages/django/db/models/base.py\", line 776, in save_base\n parent_inserted = self._save_parents(cls, using, update_fields)\n File \"/usr/local/lib/pulp/lib64/python3.6/site-packages/django/db/models/base.py\", line 807, in _save_parents\n force_insert=parent_inserted,\n File \"/usr/local/lib/pulp/lib64/python3.6/site-packages/django/db/models/base.py\", line 870, in _save_table\n result = self._do_insert(cls._base_manager, using, fields, update_pk, raw)\n File \"/usr/local/lib/pulp/lib64/python3.6/site-packages/django/db/models/base.py\", line 908, in _do_insert\n using=using, raw=raw)\n File \"/usr/local/lib/pulp/lib64/python3.6/site-packages/django/db/models/manager.py\", line 82, in manager_method\n return getattr(self.get_queryset(), name)(*args, **kwargs)\n File \"/usr/local/lib/pulp/lib64/python3.6/site-packages/django/db/models/query.py\", line 1186, in _insert\n return query.get_compiler(using=using).execute_sql(return_id)\n File \"/usr/local/lib/pulp/lib64/python3.6/site-packages/django/db/models/sql/compiler.py\", line 1368, in execute_sql\n cursor.execute(sql, params)\n File \"/usr/local/lib/pulp/lib64/python3.6/site-packages/django/db/backends/utils.py\", line 67, in execute\n return self._execute_with_wrappers(sql, params, many=False, executor=self._execute)\n File \"/usr/local/lib/pulp/lib64/python3.6/site-packages/django/db/backends/utils.py\", line 76, in _execute_with_wrappers\n return executor(sql, params, many, context)\n File \"/usr/local/lib/pulp/lib64/python3.6/site-packages/django/db/backends/utils.py\", line 84, in _execute\n return self.cursor.execute(sql, params)\n File \"/usr/local/lib/pulp/lib64/python3.6/site-packages/django/db/utils.py\", line 89, in __exit__\n raise dj_exc_value.with_traceback(traceback) from exc_value\n File \"/usr/local/lib/pulp/lib64/python3.6/site-packages/django/db/backends/utils.py\", line 84, in _execute\n return self.cursor.execute(sql, params)\n" }, "finished_at": "2020-01-13T19:44:18.779460Z", "name": "pulp_2to3_migration.app.tasks.migrate.migrate_from_pulp2", "progress_reports": [ { "code": "premigrating.repositories", "done": 5, "message": "Pre-migrating Pulp 2 repositories, importers, distributors", "state": "completed", "suffix": null, "total": 5 }, { "code": "creating.repositories", "done": 5, "message": "Creating repositories in Pulp 3", "state": "failed", "suffix": null, "total": 10 } ], "pulp_created": "2020-01-13T19:44:14.699867Z", "pulp_href": "/pulp/api/v3/tasks/35bc9b8d-6e8e-4de5-947c-501e8fb1a65d/", "reserved_resources_record": [ "pulp_2to3_migration" ], "started_at": "2020-01-13T19:44:14.808659Z", "state": "failed", "worker": "/pulp/api/v3/workers/aaca1436-69cb-4002-9073-78a33b58ca9a/" } (pulp) [vagrant@pulp2-nightly-pulp3-source-centos7 pulp-2to3-migration]$ ~~~