Upgrade from repository is not possible if gitlab is stopped
If gitlab-ce
is stopped, apt-get dist-upgrade
fails to upgrade package:
$> apt-get dist-upgrade
The following packages will be upgraded:
gitlab-ce
Get:1 https://packages.gitlab.com/gitlab/gitlab-ce/ubuntu xenial/main amd64 gitlab-ce amd64 8.9.6-ce.0 [280 MB]
Preparing to unpack .../gitlab-ce_8.9.6-ce.0_amd64.deb ...
gitlab preinstall: Automatically backing up only the GitLab SQL database (excluding everything else!)
rake aborted!
Errno::ENOENT: No such file or directory - connect(2) for /var/opt/gitlab/redis/redis.socket
gitlab preinstall:
gitlab preinstall: Backup failed! If you want to skip this backup, run the following command and
gitlab preinstall: try again:
gitlab preinstall:
gitlab preinstall: sudo touch /etc/gitlab/skip-auto-migrations
gitlab preinstall:
dpkg: error processing archive /var/cache/apt/archives/gitlab-ce_8.9.6-ce.0_amd64.deb (--unpack):
subprocess new pre-installation script returned error exit status 1
Implementation Guide
We should add a note in the prerequisites list that GitLab should be running when performing an upgrade.
Edited by Achilleas Pipinellis