Roll back to earlier GitLab versions
- Tier: Free, Premium, Ultimate
- Offering: GitLab Self-Managed
You can roll back to earlier versions of GitLab instances that were installed by using the Linux package.
Prerequisites
Because you must revert the database schema changes (migrations) that were made when the instance was upgraded, you must have:
- At least a database backup created under the exact same version and edition you are rolling back to.
- Ideally, a full backup archive of that exact same version and edition you are rolling back to.
When rolling back to an earlier major versions, you must take into account version-specific changes that occurred when you previously upgraded. For more information, see:
Roll back a Linux package instance to an earlier GitLab version
To roll back to an earlier GitLab version:
Stop GitLab and remove the current package:
# If running Puma sudo gitlab-ctl stop puma # Stop sidekiq sudo gitlab-ctl stop sidekiq # If on Ubuntu: remove the current package sudo dpkg -r gitlab-ee # If on Centos: remove the current package sudo yum remove gitlab-ee
Identify the GitLab version you want to roll back to:
# (Replace with gitlab-ce if you have GitLab FOSS installed) # Ubuntu sudo apt-cache madison gitlab-ee # CentOS: sudo yum --showduplicates list gitlab-ee
Roll back GitLab to the desired version (for example, to GitLab 15.0.5):
# (Replace with gitlab-ce if you have GitLab FOSS installed) # Ubuntu sudo apt install gitlab-ee=15.0.5-ee.0 # CentOS: sudo yum install gitlab-ee-15.0.5-ee.0.el8
Reconfigure GitLab:
sudo gitlab-ctl reconfigure
Restore GitLab to complete the roll back.
Docs
Edit this page to fix an error or add an improvement in a merge request.
Create an issue to suggest an improvement to this page.
Product
Create an issue if there's something you don't like about this feature.
Propose functionality by submitting a feature request.
Feature availability and product trials
View pricing to see all GitLab tiers and features, or to upgrade.
Try GitLab for free with access to all features for 30 days.
Get help
If you didn't find what you were looking for, search the docs.
If you want help with something specific and could use community support, post on the GitLab forum.
For problems setting up or using this feature (depending on your GitLab subscription).
Request support