Failed upgrade from 12.0.0 to 12.0.5

Nextcloud version : 12.0.0 going to 12.0.5
Operating system and version : QNAP
Apache or nginx version : 2.4.29
PHP version : 7.1.1

The issue you are facing: The upgrade seems to have failed, leaving the install in maintenance mode (for an hour now - nothing is happening). I cannot locate ANY backup created by the installer. I’m not sure if this is a platform limitation or what.

Is this the first time you’ve seen this error? : Y

Steps to replicate it:

Tried to upgrade the nextcloud app (by doing a upgrade install of the app) on the QNAP NAS I own.

The output of your Nextcloud log in Admin > Logging:

Can't access

The output of your config.php file in /path/to/nextcloud (make sure you remove any identifiable information!):

<?php
$CONFIG = array (
  'instanceid' => '',
  'passwordsalt' => '',
  'secret' => '',
  'trusted_domains' => 
  array (
    0 => '192.168.1.11:port',
    1 => '192.168.1.11:port',
    2 => 'publicsite:port',
    3 => 'publicsite:port',
  ),
  'datadirectory' => '/share/CE_CACHEDEV2_DATA/SecureData/nextcloud-data',
  'overwriteprotocol' => 'https',
  'overwrite.cli.url' => 'https://192.168.1.11:port',
  'dbtype' => 'mysql',
  'version' => '12.0.0.29',
  'dbname' => 'nc',
  'dbhost' => '127.0.0.1',
  'dbport' => '',
  'dbtableprefix' => 'oc_',
  'dbuser' => 'username',
  'dbpassword' => '',
  'logtimezone' => 'UTC',
  'installed' => true,
  'theme' => '',
  'loglevel' => 2,
  'maintenance' => false,
  'memcache.local' => '\OC\Memcache\APCu',
);

The output of your Apache/nginx/system log in /var/log/____:

{"reqId":"d8O0HFfdQhfPPOft8B1c","level":1,"time":"2018-02-18T23:34:27+00:00","remoteAddr":"192.168.1.1","user":"--","app":"updater","method":"GET","url":"\/core\/ajax\/update.php?requesttoken=DrDx362Yo3SNODzxQHfOiwa2K6NrCVJJPxRGt9JPotY%3D%3AQOnEpZni8QLCSQqaCCC64W6DT%2FQyMWUqXV0hg%2BUdwZ0%3D","message":"\\OC\\Updater::maintenanceEnabled: Turned on maintenance mode","userAgent":"Mozilla\/5.0 (X11; Ubuntu; Linux x86_64; rv:58.0) Gecko\/20100101 Firefox\/58.0","version":"12.0.0.29"}
{"reqId":"d8O0HFfdQhfPPOft8B1c","level":0,"time":"2018-02-18T23:34:27+00:00","remoteAddr":"192.168.1.1","user":"--","app":"core","method":"GET","url":"\/core\/ajax\/update.php?requesttoken=DrDx362Yo3SNODzxQHfOiwa2K6NrCVJJPxRGt9JPotY%3D%3AQOnEpZni8QLCSQqaCCC64W6DT%2FQyMWUqXV0hg%2BUdwZ0%3D","message":"starting upgrade from 12.0.0.29 to 12.0.5.3","userAgent":"Mozilla\/5.0 (X11; Ubuntu; Linux x86_64; rv:58.0) Gecko\/20100101 Firefox\/58.0","version":"12.0.0.29"}
{"reqId":"d8O0HFfdQhfPPOft8B1c","level":1,"time":"2018-02-18T23:34:27+00:00","remoteAddr":"192.168.1.1","user":"--","app":"updater","method":"GET","url":"\/core\/ajax\/update.php?requesttoken=DrDx362Yo3SNODzxQHfOiwa2K6NrCVJJPxRGt9JPotY%3D%3AQOnEpZni8QLCSQqaCCC64W6DT%2FQyMWUqXV0hg%2BUdwZ0%3D","message":"\\OC\\Repair::step: Repair step: Repair MySQL collation","userAgent":"Mozilla\/5.0 (X11; Ubuntu; Linux x86_64; rv:58.0) Gecko\/20100101 Firefox\/58.0","version":"12.0.0.29"}
{"reqId":"d8O0HFfdQhfPPOft8B1c","level":1,"time":"2018-02-18T23:34:27+00:00","remoteAddr":"192.168.1.1","user":"--","app":"updater","method":"GET","url":"\/core\/ajax\/update.php?requesttoken=DrDx362Yo3SNODzxQHfOiwa2K6NrCVJJPxRGt9JPotY%3D%3AQOnEpZni8QLCSQqaCCC64W6DT%2FQyMWUqXV0hg%2BUdwZ0%3D","message":"\\OC\\Repair::info: Repair info: All tables already have the correct collation -> nothing to do","userAgent":"Mozilla\/5.0 (X11; Ubuntu; Linux x86_64; rv:58.0) Gecko\/20100101 Firefox\/58.0","version":"12.0.0.29"}
{"reqId":"d8O0HFfdQhfPPOft8B1c","level":1,"time":"2018-02-18T23:34:27+00:00","remoteAddr":"192.168.1.1","user":"--","app":"updater","method":"GET","url":"\/core\/ajax\/update.php?requesttoken=DrDx362Yo3SNODzxQHfOiwa2K6NrCVJJPxRGt9JPotY%3D%3AQOnEpZni8QLCSQqaCCC64W6DT%2FQyMWUqXV0hg%2BUdwZ0%3D","message":"\\OC\\Repair::step: Repair step: Repair SQLite autoincrement","userAgent":"Mozilla\/5.0 (X11; Ubuntu; Linux x86_64; rv:58.0) Gecko\/20100101 Firefox\/58.0","version":"12.0.0.29"}
{"reqId":"d8O0HFfdQhfPPOft8B1c","level":1,"time":"2018-02-18T23:34:27+00:00","remoteAddr":"192.168.1.1","user":"--","app":"updater","method":"GET","url":"\/core\/ajax\/update.php?requesttoken=DrDx362Yo3SNODzxQHfOiwa2K6NrCVJJPxRGt9JPotY%3D%3AQOnEpZni8QLCSQqaCCC64W6DT%2FQyMWUqXV0hg%2BUdwZ0%3D","message":"\\OC\\Repair::step: Repair step: Copy data from accounts table when migrating from ownCloud","userAgent":"Mozilla\/5.0 (X11; Ubuntu; Linux x86_64; rv:58.0) Gecko\/20100101 Firefox\/58.0","version":"12.0.0.29"}
{"reqId":"d8O0HFfdQhfPPOft8B1c","level":1,"time":"2018-02-18T23:34:28+00:00","remoteAddr":"192.168.1.1","user":"--","app":"updater","method":"GET","url":"\/core\/ajax\/update.php?requesttoken=DrDx362Yo3SNODzxQHfOiwa2K6NrCVJJPxRGt9JPotY%3D%3AQOnEpZni8QLCSQqaCCC64W6DT%2FQyMWUqXV0hg%2BUdwZ0%3D","message":"\\OC\\Repair::step: Repair step: Drop account terms table when migrating from ownCloud","userAgent":"Mozilla\/5.0 (X11; Ubuntu; Linux x86_64; rv:58.0) Gecko\/20100101 Firefox\/58.0","version":"12.0.0.29"}
{"reqId":"d8O0HFfdQhfPPOft8B1c","level":1,"time":"2018-02-18T23:34:28+00:00","remoteAddr":"192.168.1.1","user":"--","app":"updater","method":"GET","url":"\/core\/ajax\/update.php?requesttoken=DrDx362Yo3SNODzxQHfOiwa2K6NrCVJJPxRGt9JPotY%3D%3AQOnEpZni8QLCSQqaCCC64W6DT%2FQyMWUqXV0hg%2BUdwZ0%3D","message":"\\OC\\Updater::dbUpgradeBefore: Updating database schema","userAgent":"Mozilla\/5.0 (X11; Ubuntu; Linux x86_64; rv:58.0) Gecko\/20100101 Firefox\/58.0","version":"12.0.0.29"}
{"reqId":"d8O0HFfdQhfPPOft8B1c","level":1,"time":"2018-02-18T23:34:28+00:00","remoteAddr":"192.168.1.1","user":"--","app":"updater","method":"GET","url":"\/core\/ajax\/update.php?requesttoken=DrDx362Yo3SNODzxQHfOiwa2K6NrCVJJPxRGt9JPotY%3D%3AQOnEpZni8QLCSQqaCCC64W6DT%2FQyMWUqXV0hg%2BUdwZ0%3D","message":"\\OC\\Updater::dbUpgrade: Updated database","userAgent":"Mozilla\/5.0 (X11; Ubuntu; Linux x86_64; rv:58.0) Gecko\/20100101 Firefox\/58.0","version":"12.0.0.29"}
{"reqId":"d8O0HFfdQhfPPOft8B1c","level":1,"time":"2018-02-18T23:34:28+00:00","remoteAddr":"192.168.1.1","user":"--","app":"updater","method":"GET","url":"\/core\/ajax\/update.php?requesttoken=DrDx362Yo3SNODzxQHfOiwa2K6NrCVJJPxRGt9JPotY%3D%3AQOnEpZni8QLCSQqaCCC64W6DT%2FQyMWUqXV0hg%2BUdwZ0%3D","message":"\\OC\\Updater::appUpgradeStarted: Updating <dav> ...","userAgent":"Mozilla\/5.0 (X11; Ubuntu; Linux x86_64; rv:58.0) Gecko\/20100101 Firefox\/58.0","version":"12.0.0.29"}
{"reqId":"d8O0HFfdQhfPPOft8B1c","level":1,"time":"2018-02-18T23:34:29+00:00","remoteAddr":"192.168.1.1","user":"--","app":"updater","method":"GET","url":"\/core\/ajax\/update.php?requesttoken=DrDx362Yo3SNODzxQHfOiwa2K6NrCVJJPxRGt9JPotY%3D%3AQOnEpZni8QLCSQqaCCC64W6DT%2FQyMWUqXV0hg%2BUdwZ0%3D","message":"\\OC\\Repair::step: Repair step: Fix component of birthday calendars","userAgent":"Mozilla\/5.0 (X11; Ubuntu; Linux x86_64; rv:58.0) Gecko\/20100101 Firefox\/58.0","version":"12.0.0.29"}
{"reqId":"d8O0HFfdQhfPPOft8B1c","level":1,"time":"2018-02-18T23:34:29+00:00","remoteAddr":"192.168.1.1","user":"--","app":"updater","method":"GET","url":"\/core\/ajax\/update.php?requesttoken=DrDx362Yo3SNODzxQHfOiwa2K6NrCVJJPxRGt9JPotY%3D%3AQOnEpZni8QLCSQqaCCC64W6DT%2FQyMWUqXV0hg%2BUdwZ0%3D","message":"\\OC\\Repair::info: Repair info: 1 birthday calendars updated.","userAgent":"Mozilla\/5.0 (X11; Ubuntu; Linux x86_64; rv:58.0) Gecko\/20100101 Firefox\/58.0","version":"12.0.0.29"}
{"reqId":"d8O0HFfdQhfPPOft8B1c","level":1,"time":"2018-02-18T23:34:29+00:00","remoteAddr":"192.168.1.1","user":"--","app":"updater","method":"GET","url":"\/core\/ajax\/update.php?requesttoken=DrDx362Yo3SNODzxQHfOiwa2K6NrCVJJPxRGt9JPotY%3D%3AQOnEpZni8QLCSQqaCCC64W6DT%2FQyMWUqXV0hg%2BUdwZ0%3D","message":"\\OC\\Repair::step: Repair step: Fix broken values of calendar objects","userAgent":"Mozilla\/5.0 (X11; Ubuntu; Linux x86_64; rv:58.0) Gecko\/20100101 Firefox\/58.0","version":"12.0.0.29"}
{"reqId":"d8O0HFfdQhfPPOft8B1c","level":1,"time":"2018-02-18T23:34:29+00:00","remoteAddr":"192.168.1.1","user":"--","app":"updater","method":"GET","url":"\/core\/ajax\/update.php?requesttoken=DrDx362Yo3SNODzxQHfOiwa2K6NrCVJJPxRGt9JPotY%3D%3AQOnEpZni8QLCSQqaCCC64W6DT%2FQyMWUqXV0hg%2BUdwZ0%3D","message":"\\OC\\Repair::startProgress: Starting ... Fix broken values of calendar objects (0)","userAgent":"Mozilla\/5.0 (X11; Ubuntu; Linux x86_64; rv:58.0) Gecko\/20100101 Firefox\/58.0","version":"12.0.0.29"}
{"reqId":"d8O0HFfdQhfPPOft8B1c","level":1,"time":"2018-02-18T23:34:29+00:00","remoteAddr":"192.168.1.1","user":"--","app":"updater","method":"GET","url":"\/core\/ajax\/update.php?requesttoken=DrDx362Yo3SNODzxQHfOiwa2K6NrCVJJPxRGt9JPotY%3D%3AQOnEpZni8QLCSQqaCCC64W6DT%2FQyMWUqXV0hg%2BUdwZ0%3D","message":"\\OC\\Repair::finishProgress","userAgent":"Mozilla\/5.0 (X11; Ubuntu; Linux x86_64; rv:58.0) Gecko\/20100101 Firefox\/58.0","version":"12.0.0.29"}
{"reqId":"d8O0HFfdQhfPPOft8B1c","level":1,"time":"2018-02-18T23:34:29+00:00","remoteAddr":"192.168.1.1","user":"--","app":"updater","method":"GET","url":"\/core\/ajax\/update.php?requesttoken=DrDx362Yo3SNODzxQHfOiwa2K6NrCVJJPxRGt9JPotY%3D%3AQOnEpZni8QLCSQqaCCC64W6DT%2FQyMWUqXV0hg%2BUdwZ0%3D","message":"\\OC\\Repair::step: Repair step: Registering building of calendar search index as background job","userAgent":"Mozilla\/5.0 (X11; Ubuntu; Linux x86_64; rv:58.0) Gecko\/20100101 Firefox\/58.0","version":"12.0.0.29"}
{"reqId":"d8O0HFfdQhfPPOft8B1c","level":1,"time":"2018-02-18T23:34:29+00:00","remoteAddr":"192.168.1.1","user":"--","app":"updater","method":"GET","url":"\/core\/ajax\/update.php?requesttoken=DrDx362Yo3SNODzxQHfOiwa2K6NrCVJJPxRGt9JPotY%3D%3AQOnEpZni8QLCSQqaCCC64W6DT%2FQyMWUqXV0hg%2BUdwZ0%3D","message":"\\OC\\Repair::info: Repair info: Repair step already executed","userAgent":"Mozilla\/5.0 (X11; Ubuntu; Linux x86_64; rv:58.0) Gecko\/20100101 Firefox\/58.0","version":"12.0.0.29"}
{"reqId":"d8O0HFfdQhfPPOft8B1c","level":1,"time":"2018-02-18T23:34:29+00:00","remoteAddr":"192.168.1.1","user":"--","app":"updater","method":"GET","url":"\/core\/ajax\/update.php?requesttoken=DrDx362Yo3SNODzxQHfOiwa2K6NrCVJJPxRGt9JPotY%3D%3AQOnEpZni8QLCSQqaCCC64W6DT%2FQyMWUqXV0hg%2BUdwZ0%3D","message":"\\OC\\Updater::appUpgrade: Updated <dav> to 1.3.1","userAgent":"Mozilla\/5.0 (X11; Ubuntu; Linux x86_64; rv:58.0) Gecko\/20100101 Firefox\/58.0","version":"12.0.0.29"}
{"reqId":"d8O0HFfdQhfPPOft8B1c","level":1,"time":"2018-02-18T23:34:29+00:00","remoteAddr":"192.168.1.1","user":"--","app":"updater","method":"GET","url":"\/core\/ajax\/update.php?requesttoken=DrDx362Yo3SNODzxQHfOiwa2K6NrCVJJPxRGt9JPotY%3D%3AQOnEpZni8QLCSQqaCCC64W6DT%2FQyMWUqXV0hg%2BUdwZ0%3D","message":"\\OC\\Updater::checkAppStoreAppBefore: Checking for update of app \"activity\" in appstore","userAgent":"Mozilla\/5.0 (X11; Ubuntu; Linux x86_64; rv:58.0) Gecko\/20100101 Firefox\/58.0","version":"12.0.0.29"}

I solved my own issue. Boy this forum isn’t very useful.

I just re-ran the upgrade at the command line.

On a QNAP NAS this is the process:

[~] # export PATH=/share/CACHEDEV1_DATA/.qpkg/Qapache/bin:$PATH
[~] # cd /share/CACHEDEV1_DATA/.qpkg/NextCloud/nextcloud/
[~] # occ upgrade

and then undo the PATH addition.  Show the current value via:
[~] # echo $PATH
and then do the export command with the new PATH removing the added folder.

FYI, NextCloud 12.0.0 isn’t compatible with PHP 7.2

You need to upgrade from NC 12.0.0 to 12.0.5, and then to 13.0.0. (to be safe on the upgrades)

Only then can you upgrade PHP to 7.2. On QNAP this is part of the Qapache package.

What is written in the official admin manual:

https://docs.nextcloud.com/server/12/admin_manual/installation/system_requirements.html

Recommended Setup for Running Nextcloud
For best performance, stability, support, and full functionality we recommend:

Red Hat Enterprise Linux 7 / Ubuntu 16.04 LTS
MySQL/MariaDB
PHP 7.0, 7.1 (PHP 7.2 not supported)