Migration from 18.4 to 18.5
Everyone can contribute. Help move this issue forward while earning points, leveling up and collecting rewards.
I try to upgrade a dockered Gitlab CE from 18.4 to 18.5 and it crashed with "undefined method `id' for nil:NilClass". Then I reverted the docker image back to 18.4.3-ce.0 and it worked again, but two background jobs are stuck in finalize visible under Background migrations:
- FixNonExistingTimelogUsers: timelogs
- BackfillMissingNamespaceIdOnNotes: notes
The first migration reports also failed jobs. The time range is exactly the range, where I run the 18.5 release (undefined method id' for nil:NilClass). The Background jobs log shows me several dead jobs with Database::BatchedBackgroundMigration::MainExecutionWorkerand the resultNameError: uninitialized constant Gitlab::BackgroundMigration::BackfillMissingNamespaceIdOnNotes`.
There are no queued background migrations. Only this two migrations, that hang with 0% progress since 3 days.
I'm not sure how to proceed. I tried the steps from https://docs.gitlab.com/update/background_migrations_troubleshooting/ I don't get rid of this jobs and I cannot upgrade.
I didn't made a manual rollback (backup, restore) because a minor release without breaking changes should not make this kind of issues and I couldnt find issues or discussions about this from 2025. But I wonder - this seems to be a unique issue with my installation. Are this entries and logs from the db:migration of 18.5 itself? Should they be persistent?