An error occurs during the [Run pulp migrations] step when upgrading RHUI4, causing the upgrade to fail.

Solution In Progress - Updated -

Issue

An error occurs during the [Run pulp migrations] step when upgrading RHUI4, causing the upgrade to fail.

# rhui-installer --rerun
        /root/.ssh/id_rsa_rhua Already exists
        Answers saved to file: /root/.rhui/answers.yaml

 PLAY [RHUA provision playbook] **************************************************************************************************************************************************************************************************************

 TASK [Gathering Facts]
<snip>

 TASK [Run pulp migrations] ******************************************************************************************************************************************************************************************************************
 fatal: [localhost]: FAILED! => {"changed": true, "cmd": ["env", "PULP_SETTINGS=/etc/pulp/settings.py", "pulpcore-manager", "migrate"], "delta": "0:00:04.269492", "end": "2025-02-13 10:24:30.855367", "msg": "non-zero return code", "rc": 1, "start": "2025-02-13 10:24:26.585875", "stderr": "Traceback (most recent call last):\n  File \"/usr/bin/pulpcore-manager\", line 33, in <module>\n    sys.exit(load_entry_point('pulpcore==3.49.22', 'console_scripts', 'pulpcore-manager')())\n             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n  File \"/usr/lib/python3.11/site-packages/pulpcore/app/manage.py\", line 11, in manage\n    execute_from_command_line(sys.argv)\n  File \"/usr/lib/python3.11/site-packages/django/core/management/__init__.py\", line 442, in execute_from_command_line\n    utility.execute()\n  File \"/usr/lib/python3.11/site-packages/django/core/management/__init__.py\", line 436, in execute\n    self.fetch_command(subcommand).run_from_argv(self.argv)\n  File \"/usr/lib/python3.11/site-packages/django/core/management/base.py\", line 412, in run_from_argv\n    self.execute(*args, **cmd_options)\n  File \"/usr/lib/python3.11/site-packages/django/core/management/base.py\", line 458, in execute\n    output = self.handle(*args, **options)\n             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n  File \"/usr/lib/python3.11/site-packages/django/core/management/base.py\", line 106, in wrapper\n    res = handle_func(*args, **kwargs)\n          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n  File \"/usr/lib/python3.11/site-packages/django/core/management/commands/migrate.py\", line 356, in handle\n    post_migrate_state = executor.migrate(\n                         ^^^^^^^^^^^^^^^^^\n  File \"/usr/lib/python3.11/site-packages/django/db/migrations/executor.py\", line 135, in migrate\n    state = self._migrate_all_forwards(\n            ^^^^^^^^^^^^^^^^^^^^^^^^^^^\n  File \"/usr/lib/python3.11/site-packages/django/db/migrations/executor.py\", line 167, in _migrate_all_forwards\n    state = self.apply_migration(\n            ^^^^^^^^^^^^^^^^^^^^^\n  File \"/usr/lib/python3.11/site-packages/django/db/migrations/executor.py\", line 252, in apply_migration\n    state = migration.apply(state, schema_editor)\n            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n  File \"/usr/lib/python3.11/site-packages/django/db/migrations/migration.py\", line 132, in apply\n    operation.database_forwards(\n  File \"/usr/lib/python3.11/site-packages/pulpcore/migrations.py\", line 48, in database_forwards\n    raise RuntimeError(\nRuntimeError: Incompatible versions detected (core >= 3.34.0 needed):\n  - 'core'='3.28.19' with content server '1024280@rhui-rhua'\n  - 'core'='3.28.19' with content server '943593@rhui-rhua'\nPlease shutdown or upgrade the outdated components before you continue the migration.", "stderr_lines": ["Traceback (most recent call last):", "  File \"/usr/bin/pulpcore-manager\", line 33, in <module>", "    sys.exit(load_entry_point('pulpcore==3.49.22', 'console_scripts', 'pulpcore-manager')())", "             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^", "  File \"/usr/lib/python3.11/site-packages/pulpcore/app/manage.py\", line 11, in manage", "    execute_from_command_line(sys.argv)", "  File \"/usr/lib/python3.11/site-packages/django/core/management/__init__.py\", line 442, in execute_from_command_line", "    utility.execute()", "  File \"/usr/lib/python3.11/site-packages/django/core/management/__init__.py\", line 436, in execute", "    self.fetch_command(subcommand).run_from_argv(self.argv)", "  File \"/usr/lib/python3.11/site-packages/django/core/management/base.py\", line 412, in run_from_argv", "    self.execute(*args, **cmd_options)", "  File \"/usr/lib/python3.11/site-packages/django/core/management/base.py\", line 458, in execute", "    output = self.handle(*args, **options)", "             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^", "  File \"/usr/lib/python3.11/site-packages/django/core/management/base.py\", line 106, in wrapper", "    res = handle_func(*args, **kwargs)", "          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^", "  File \"/usr/lib/python3.11/site-packages/django/core/management/commands/migrate.py\", line 356, in handle", "    post_migrate_state = executor.migrate(", "                         ^^^^^^^^^^^^^^^^^", "  File \"/usr/lib/python3.11/site-packages/django/db/migrations/executor.py\", line 135, in migrate", "    state = self._migrate_all_forwards(", "            ^^^^^^^^^^^^^^^^^^^^^^^^^^^", "  File \"/usr/lib/python3.11/site-packages/django/db/migrations/executor.py\", line 167, in _migrate_all_forwards", "    state = self.apply_migration(", "            ^^^^^^^^^^^^^^^^^^^^^", "  File \"/usr/lib/python3.11/site-packages/django/db/migrations/executor.py\", line 252, in apply_migration", "    state = migration.apply(state, schema_editor)", "            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^", "  File \"/usr/lib/python3.11/site-packages/django/db/migrations/migration.py\", line 132, in apply", "    operation.database_forwards(", "  File \"/usr/lib/python3.11/site-packages/pulpcore/migrations.py\", line 48, in database_forwards", "    raise RuntimeError(", "RuntimeError: Incompatible versions detected (core >= 3.34.0 needed):", "  - 'core'='3.28.19' with content server '1024280@rhui-rhua'", "  - 'core'='3.28.19' with content server '943593@rhui-rhua'", "Please shutdown or upgrade the outdated components before you continue the migration."], "stdout": "Operations to perform:\n  Apply all migrations: auth, certguard, container, contenttypes, core, file, rpm, sessions\nRunning migrations:\n  Applying certguard.0001_initial... OK\n  Applying certguard.0002_alter_rhsmcertguard_contentguard_ptr_and_more... OK\n  Applying core.0108_task_versions... OK\n  Applying core.0109_contentartifact_relative_path_index... OK\n  Applying core.0110_apiappstatus... OK\n  Applying core.0111_task_enc_args_task_enc_kwargs... OK\n  Applying core.0112_alter_upstreampulp_options... OK\n  Applying core.0113_headercontentguard... OK\n  Applying core.0114_remove_task_args_remove_task_kwargs...", "stdout_lines": ["Operations to perform:", "  Apply all migrations: auth, certguard, container, contenttypes, core, file, rpm, sessions", "Running migrations:", "  Applying certguard.0001_initial... OK", "  Applying certguard.0002_alter_rhsmcertguard_contentguard_ptr_and_more... OK", "  Applying core.0108_task_versions... OK", "  Applying core.0109_contentartifact_relative_path_index... OK", "  Applying core.0110_apiappstatus... OK", "  Applying core.0111_task_enc_args_task_enc_kwargs... OK", "  Applying core.0112_alter_upstreampulp_options... OK", "  Applying core.0113_headercontentguard... OK", "  Applying core.0114_remove_task_args_remove_task_kwargs..."]}

 PLAY RECAP **********************************************************************************************************************************************************************************************************************************
 localhost                  : ok=50   changed=11   unreachable=0    failed=1    skipped=37   rescued=0    ignored=0   

        ERROR: Ansible execution failed.
#

Environment

Red Hat Update Infrastructure 4.10

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content