Will nc-restore install my previous version of Nextcloud?

I was using Nextcloud via NCP for several years. Wonderful setup! Then, I had to make some changes. My Nextcloud was still at 16.0.3. I tried to upgrade to 19, but couldnā€™t figure it out.

So, I have created a fresh install of NCP, which currently is at Nextcloud 19.0.2.2.

Question: if I use nc-restore on a nextcloud-bkp which was created when I was running Nextcloud 16, will nc-restore remove Nextcloud 19 and install Nextcloud 16, or does it just restore my user accounts and other configs?

nc-restore will do both

  • restore the database.
  • restore Nextcloud to the version installed when creating the backup.

You can use nc-update-nextcloud to upgrade Nextcloud, but it does not support skipping major versions. So you have to go from 16 to 17, to 18, to 19.
As documented in https://docs.nextcloudpi.com/en/staying-up-to-date/

I tried nc-update-nextcloud, but it kept telling me the error ā€œMalformed versionā€. Using either the cli program or the web interface, when I get to the screen that asks me to put in the version of Nextcloud to upgrade to, when I put in 17, it gives the error ā€œMalformed versionā€. I have tried ā€œ17.0.xā€ and ā€œ17.xā€ and gotten the same results. Do you know how to get past this error so I can upgrade 16.0.3 to 17, then 17 to 18, and then 18 to 19?

You can check https://nextcloud.com/changelog/ for the highest version available.
For 17 that would be 17.0.10 (17 or 17.0.x will result in"malformed version" error)
For 18 it is 18.0.10
For 19 it is 19.0.4

Wonderful! I have upgraded to 17.0.10 using your advice.

I ran into a problem moving to 18.0.10, but found a solution which I hope will work in my situation.

From this solution (Upgrade fails with - Column name ā€œoc_flow_operations.entityā€ is ā€œNotNullā€, but has empty string or null as default) and a number of other webpages, I figured out how to fix this oc_flow_operations error.

However, when running nc-update-nextcloud to go from 17.0.10 to 18.0.10, I ran into another error.

Repair error: Repair step ā€˜OCA\Talk\Migration\FixNamespaceInDatabaseTablesā€™ is unknown
PHP Fatal error: Cannot declare class OCA\Talk\Migration\Version8000Date20200331144101, because the name is already in use in /var/www/nextcloud/apps/spreed/lib/Migration/Version8000Date20200331144101.php on line 54

Since I donā€™t use the Talk / Spreed app, I removed it from my nextcloud instance. After that, I was able to upgrade to 18.0.10, 19.04, and then 20.0.1.

Case closed. Thanks for the help.