In some cases after a failed upgrade, the fastest solution is to roll back to the previous version you were using.

First, roll back the code or package. For source installations this involves checking out the older version (branch or tag). For Omnibus installations this means installing the older .deb or .rpm package. Then, restore from a backup. Follow the instructions in the Backup and Restore documentation.

When a rollback is necessary it can produce problems on subsequent upgrade attempts. This is because some tables may have been added during the failed upgrade. If these tables are still present after you restore from the older backup it can lead to migration failures on future upgrades.

Starting in GitLab 8.6 we drop all tables prior to importing the backup to prevent this problem. If you've restored a backup to a version prior to 8.6 you may need to manually correct the problem next time you upgrade.