# Updates between multiple major versions are unsupported

**URL:** <https://help.nextcloud.com/t/updates-between-multiple-major-versions-are-unsupported/7094>\
**Category:** 📑 How to\
**Tags:** update\_problems, nc11, nc9, multiple\_versions\
**Created:** [January 4, 2017, 11:43am UTC](https://help.nextcloud.com/t/updates-between-multiple-major-versions-are-unsupported/7094 "2017-01-04T11:43:30Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![nickvergessen](https://help.nextcloud.com/user_avatar/help.nextcloud.com/nickvergessen/32/66965_2.png) [@nickvergessen](https://help.nextcloud.com/u/nickvergessen)\
**Post date:** [January 4, 2017, 11:43am UTC](https://help.nextcloud.com/t/updates-between-multiple-major-versions-are-unsupported/7094/1 "2017-01-04T11:43:31Z")

</div>

### Problem

A “Updates between multiple major versions are unsupported” message is shown during an update/upgrade

### Description

As the message is telling you, you have done an unsupported upgrade path. For example:

Original version: 9.0.52  
Upgraded version: 11.0.0

In this case you have skipped the 10.0.x upgrade which is unsupported as stated within the **[documentation](https://docs.nextcloud.com/server/11/admin_manual/maintenance/upgrade.html)**.

### Solution:

You need to upgrade first to the latest available version of 10.0.x which is currently 10.0.2. For that specific scenario the following is recommended:

1. Remove all files and folders of your Nextcloud installation folder except /data/ and /config/
2. Download 9.0.56 from [Nextcloud changelog](https://nextcloud.com/changelog/)
3. Extract the content of the archive it into your Nextcloud installation folder
4. Run the update via the webui or the command line tool

Afterwards repeat those steps with 10.0.2 and 11.0.0

---

<div class="post-metadata">

**Author:** ![JochenHWezel](https://help.nextcloud.com/letter_avatar/jochenhwezel/32/6_22734026db12803ebb3e059622ac3534.png) [@JochenHWezel](https://help.nextcloud.com/u/JochenHWezel)\
**Post date:** [August 31, 2018, 1:23pm UTC](https://help.nextcloud.com/t/updates-between-multiple-major-versions-are-unsupported/7094/3 "2018-08-31T13:23:27Z")

</div>

On migration from owncloud 10.0.9.5, the updater downloaded automatically Nextcloud version 12.0.10

Unfortunately, occ upgrade failed:

sudo -u www-data ./occ upgrade  
Nextcloud or one of the apps require upgrade - only a limited number of commands are available  
You may use your browser or the occ upgrade command to do the upgrade  
Set log level to debug  
Exception: Updates between multiple major versions and downgrades are unsupported.  
Update failed  
Maintenance mode is kept active  
Reset log level

---

<div class="post-metadata">

**Author:** ![Crell](https://help.nextcloud.com/user_avatar/help.nextcloud.com/crell/32/10864_2.png) [@Crell](https://help.nextcloud.com/u/Crell)\
**Post date:** [September 17, 2018, 12:09am UTC](https://help.nextcloud.com/t/updates-between-multiple-major-versions-are-unsupported/7094/4 "2018-09-17T00:09:15Z")

</div>

I am running into the same problem. I upgraded my OC instance to the latest version (10.0.9), then ran the NC automated updater. It proceeded fine, but then when I run `occ upgrade` I get told that multiple version upgrades are not supported.

This is the version it downloaded. It should be a version that it can upgrade to. If not, why did it download it?

---

<div class="post-metadata">

**Author:** ![hatsix](https://help.nextcloud.com/user_avatar/help.nextcloud.com/hatsix/32/14506_2.png) [@hatsix](https://help.nextcloud.com/u/hatsix)\
**Post date:** [April 8, 2019, 2:39am UTC](https://help.nextcloud.com/t/updates-between-multiple-major-versions-are-unsupported/7094/5 "2019-04-08T02:39:48Z")

</div>

For updating snaps, use `snap refresh nextcloud --channel=13/stable` (or whatever version you’re on)… Then just keep incrementing the version… when you’re up to latest, use `snap refresh nextcloud --channel=stable`

---

<div class="post-metadata">

**Author:** ![danial-k](https://help.nextcloud.com/letter_avatar/danial-k/32/6_22734026db12803ebb3e059622ac3534.png) [@danial-k](https://help.nextcloud.com/u/danial-k)\
**Post date:** [May 11, 2019, 12:35pm UTC](https://help.nextcloud.com/t/updates-between-multiple-major-versions-are-unsupported/7094/6 "2019-05-11T12:35:36Z")

</div>

Thanks @hatsix, I was stuck on 13 being forced to 15, your solution helped me log in again, many thanks.

---

<div class="post-metadata">

**Author:** ![rubo77](https://help.nextcloud.com/user_avatar/help.nextcloud.com/rubo77/32/10341_2.png) [@rubo77](https://help.nextcloud.com/u/rubo77)\
**Post date:** [September 15, 2019, 6:32pm UTC](https://help.nextcloud.com/t/updates-between-multiple-major-versions-are-unsupported/7094/7 "2019-09-15T18:32:30Z")

</div>

I am stuck on upgrading to 16 now. I accidentally upgraded my docker instance from 14 to 16.

# This is, how to remove all files, but keep the database in my docker instance:

my `docker-compose.yml`

```
version: '3'

services:
  db:
    image: mariadb
    restart: always
    volumes:
      - /var/docker-services/nextcloud/volumes/mysql:/var/lib/mysql
    environment:
      - MYSQL_ROOT_PASSWORD= *****
      - MYSQL_PASSWORD= *****
      - MYSQL_DATABASE=nextcloud
      - MYSQL_USER=nextcloud

  app:
    image: nextcloud:15.0
    build:
      context: .
      dockerfile: Dockerfile
    ports:
      - 8084:80
    links:
      - db
    volumes:
      - /var/docker-services/nextcloud/volumes/html:/var/www/html
    restart: always

```

First I delete all but the config folder and data inside the volume and then I recreate the docker container:

```
docker-compose stop
cd volumes/html/
mv data config/ ../
rm ./* -Rf
mv ../data/ ../config/ .
cd ../../
docker-compose up -d
docker exec --user www-data nextcvkevde_app_1 php occ maintenance:mode --off
```

---

<div class="post-metadata">

**Author:** ![hiran](https://help.nextcloud.com/letter_avatar/hiran/32/6_22734026db12803ebb3e059622ac3534.png) [@hiran](https://help.nextcloud.com/u/hiran)\
**Post date:** [October 9, 2019, 10:40pm UTC](https://help.nextcloud.com/t/updates-between-multiple-major-versions-are-unsupported/7094/8 "2019-10-09T22:40:17Z")

</div>

I can understand jumping versions is not supported and probably not a good idea.  
What happened to me is that after some time I ran my Ansible script which just installs the latest nextcloud docker image. Now I am stuck with an error message that directed me to this thread.

So far so good, I would now like to follow the correct upgrade path. But as my ansible script also cleaned out the old container, I am just left with files and database. Is there any way to find out the nextcloud database version? I need to know which version to start upgrading with…

---

<div class="post-metadata">

**Author:** ![hiran](https://help.nextcloud.com/letter_avatar/hiran/32/6_22734026db12803ebb3e059622ac3534.png) [@hiran](https://help.nextcloud.com/u/hiran)\
**Post date:** [October 9, 2019, 10:53pm UTC](https://help.nextcloud.com/t/updates-between-multiple-major-versions-are-unsupported/7094/9 "2019-10-09T22:53:34Z")

</div>

Fiddling around some more, I checked config.php. Is it possible that this file stores the nextcloud version in use? Or what does the version field actually mean? (I still believe it would be my input for nextcloud to run, nothing that nextcloud would overwrite?)

---

<div class="post-metadata">

**Author:** ![nickvergessen](https://help.nextcloud.com/user_avatar/help.nextcloud.com/nickvergessen/32/66965_2.png) [@nickvergessen](https://help.nextcloud.com/u/nickvergessen)\
**Post date:** [October 10, 2019, 6:23am UTC](https://help.nextcloud.com/t/updates-between-multiple-major-versions-are-unsupported/7094/10 "2019-10-10T06:23:33Z")

</div>

Well yes it’s your configuration and by default only the version field is “overwritten” by Nextcloud itself. But e.g. you can also modify the email settings in the admin page and they will update the values to the config.php

---

<div class="post-metadata">

**Author:** ![hiran](https://help.nextcloud.com/letter_avatar/hiran/32/6_22734026db12803ebb3e059622ac3534.png) [@hiran](https://help.nextcloud.com/u/hiran)\
**Post date:** [October 10, 2019, 7:39am UTC](https://help.nextcloud.com/t/updates-between-multiple-major-versions-are-unsupported/7094/11 "2019-10-10T07:39:44Z")

</div>

What a T"%T%$&/$&§!!!  
Obviously my Ansible script pulls config.php from a repository before deploying the Nextcloud container. And now I learn Nextcloud is editing the file.

So whenever I ran my script config.php contained version 15.0.10, and it seems this bugged Nextcloud from 17 onwards to no longer start. I had to modify the script to run not the latest but distinct versions and in parallel edit config.php as well. Meanwhile I am migrated to 17.

Any idea how to handle this in a smarter way?

---

<div class="post-metadata">

**Author:** ![nickvergessen](https://help.nextcloud.com/user_avatar/help.nextcloud.com/nickvergessen/32/66965_2.png) [@nickvergessen](https://help.nextcloud.com/u/nickvergessen)\
**Post date:** [October 10, 2019, 7:56am UTC](https://help.nextcloud.com/t/updates-between-multiple-major-versions-are-unsupported/7094/12 "2019-10-10T07:56:13Z")

</div>

Set the read only flag in your config:

> <https://github.com/nextcloud/server/blob/master/config/config.sample.php#L718-L728>

---

<div class="post-metadata">

**Author:** ![hiran](https://help.nextcloud.com/letter_avatar/hiran/32/6_22734026db12803ebb3e059622ac3534.png) [@hiran](https://help.nextcloud.com/u/hiran)\
**Post date:** [October 10, 2019, 8:00am UTC](https://help.nextcloud.com/t/updates-between-multiple-major-versions-are-unsupported/7094/13 "2019-10-10T08:00:04Z")

</div>

Thank you for that hint. From reading the comment this would prevent Nextcloud writing the file, and all functions requiring that (e.g. changes on the admin ui) will fail. Sounds good.

But what is this thing about making the file writable for upgrades? After all I want to use my script in case of reinstalls as well as upgrades so it usually installs the latest version - whatever that this and therefore I could not predict when Nextcloud needs to write the file…

---

<div class="post-metadata">

**Author:** ![nickvergessen](https://help.nextcloud.com/user_avatar/help.nextcloud.com/nickvergessen/32/66965_2.png) [@nickvergessen](https://help.nextcloud.com/u/nickvergessen)\
**Post date:** [October 10, 2019, 8:32am UTC](https://help.nextcloud.com/t/updates-between-multiple-major-versions-are-unsupported/7094/14 "2019-10-10T08:32:39Z")

</div>

So what you could do is:

- Remove the version from the config.php you copy all the time
- Copy the config.php to others.config.php instead of config.php

The two configs will then be merged on use. So it would still copy all your configs all the time, while not overwriting the version from the config.php:  
[https://docs.nextcloud.com/server/latest/admin\_manual/configuration\_server/config\_sample\_php\_parameters.html#multiple-config-php-file](https://docs.nextcloud.com/server/latest/admin_manual/configuration_server/config_sample_php_parameters.html#multiple-config-php-file)

---

<div class="post-metadata">

**Author:** ![hiran](https://help.nextcloud.com/letter_avatar/hiran/32/6_22734026db12803ebb3e059622ac3534.png) [@hiran](https://help.nextcloud.com/u/hiran)\
**Post date:** [October 10, 2019, 8:40am UTC](https://help.nextcloud.com/t/updates-between-multiple-major-versions-are-unsupported/7094/15 "2019-10-10T08:40:55Z")

</div>

This sounds very suitable for my purpose. Thank you. 🙂

---

<div class="post-metadata">

**Author:** ![exup](https://help.nextcloud.com/letter_avatar/exup/32/6_22734026db12803ebb3e059622ac3534.png) [@exup](https://help.nextcloud.com/u/exup)\
**Post date:** [October 22, 2019, 8:15am UTC](https://help.nextcloud.com/t/updates-between-multiple-major-versions-are-unsupported/7094/16 "2019-10-22T08:15:45Z")

</div>

Hi,  
I am running Ubuntu 18.04.3 LTS on the VM provided by T&M Handson. But the version of nextcloud is old, version T&M Hanson. I ran there update script but it announced failed to upgrade. Server is now in manitenance mode. If I turn it off it shows on the web gui I need to upgrade but then get the error you have stated.

To follow your workaround I have a Question though what/where is my installation folder?  
Is it /var/www/nextcloud? If yes I dont have permission to that folder as sudo, so what account is configured to edit its contents.

---

<div class="post-metadata">

**Author:** ![robinmem](https://help.nextcloud.com/letter_avatar/robinmem/32/6_22734026db12803ebb3e059622ac3534.png) [@robinmem](https://help.nextcloud.com/u/robinmem)\
**Post date:** [November 2, 2019, 6:53pm UTC](https://help.nextcloud.com/t/updates-between-multiple-major-versions-are-unsupported/7094/17 "2019-11-02T18:53:01Z")

</div>

Hi,

Please excuse me for not knowing anything about all of this. I’m a total novice.

I rent shared server space that uses Softaculous through CPanel to install things like NextCloud, wordpress, etc. NextCloud was all installed and working fine when I got a notification saying to upgrade. I clicked to have it upgrade and evidently, it attempted to jump from maybe 15 to 17 (I honestly don’t know which was initially on there).

Now, since I use softaculous, I don’t know how or what I should do because I don’t actually run the server and I don’t have SSH access or anything.

I don’t want to mess anything up. I can get to my stuff using the cPanel file manager. If I have to, I was just going to do a fresh install but I don’t know how to migrate the files in or point the new instal to where the old files were or what to do.

Now can’t access NextCloud by going to the site or anytnhing. I’m just afraid of losing my stuff stored in nextcloud.

Any ideas on how I can do the upgrade without losing my data or anything? Or just do a fresh install and then move the files or substitute the old NextCloudData file for the new one?

Again, sorry so vague and ignorant. Any help is much appreciated.

Thank you.

---

<div class="post-metadata">

**Author:** ![i-need-to-tell-you-s](https://help.nextcloud.com/user_avatar/help.nextcloud.com/i-need-to-tell-you-s/32/28520_2.png) [@i-need-to-tell-you-s](https://help.nextcloud.com/u/i-need-to-tell-you-s)\
**Post date:** [March 12, 2020, 8:53am UTC](https://help.nextcloud.com/t/updates-between-multiple-major-versions-are-unsupported/7094/18 "2020-03-12T08:53:55Z")

</div>

I was upgrading my docker-compose (using `nextcloud:fpm` image) setup from 16 to 18. I don’t know/remember why I am using `fpm` tag or what it even means. I probably followed some guide. This might therefore not be directly applicable to others. But I made this write-up hoping that it provides clues to making someone else’s life easier.

> **My docker-compose.yml**
>
> ```auto
> # NextCLoud with MariaDB/MySQL all behind Nginx acting as a Reverse Proxy with SSL Encryption from LetsEcrypt.
> #
> # During initial NextCLoud setup, select "Storage & database" --> "Configure the database" --> "MySQL/MariaDB"
> # Database user: nextcloud
> # Database password: nextcloud
> # Database name: nextcloud
> # Database host: replace "localhost" with "db" the same name as the data base container name.
> #
> 
> version: '2'
> 
> services:
> proxy:
> image: jwilder/nginx-proxy
> container_name: proxy
> ports:
> - 80:80
> - 443:443
> volumes:
> - ./proxy/conf.d:/etc/nginx/conf.d
> - ./proxy/vhost.d:/etc/nginx/vhost.d
> - ./proxy/html:/usr/share/nginx/html
> - ./proxy/certs:/etc/nginx/certs:ro
> - /var/run/docker.sock:/tmp/docker.sock:ro
> networks:
> - proxy-tier
> restart: always
> 
> letsencrypt-companion:
> image: jrcs/letsencrypt-nginx-proxy-companion
> container_name: letsencrypt-companion
> volumes_from:
> - proxy
> volumes:
> - /var/run/docker.sock:/var/run/docker.sock:ro
> - ./proxy/certs:/etc/nginx/certs:rw
> restart: always
> 
> web:
> image: nginx
> container_name: nextcloud_webserver
> volumes:
> - ./nginx.conf:/etc/nginx/nginx.conf:ro
> links:
> - app
> volumes_from:
> - app
> environment:
> - VIRTUAL_HOST= ****
> - VIRTUAL_NETWORK=nginx-proxy
> - VIRTUAL_PORT=80
> - LETSENCRYPT_HOST= ****
> - LETSENCRYPT_EMAIL= ****
> networks:
> - proxy-tier
> restart: always
> 
> app:
> image: nextcloud:fpm
> container_name: nextcloud_fpm
> links:
> - db
> volumes:
> - ./nextcloud/apps:/var/www/html/apps
> - ./nextcloud/config:/var/www/html/config
> - ./nextcloud/data:/var/www/html/data
> networks:
> - proxy-tier
> restart: always
> 
> db:
> image: mariadb
> container_name: db
> volumes:
> - ./nextcloud/db:/var/lib/mysql
> environment:
> - MYSQL_ROOT_PASSWORD= ****
> - MYSQL_DATABASE=nextcloud
> - MYSQL_USER= ****
> - MYSQL_PASSWORD= ****
> networks:
> - proxy-tier
> restart: always
> 
> networks:
> proxy-tier:
> external:
> name: nginx-proxy
> 
> ```

1. `ssh` to the server

2. Make backup of NC (NextCloud) data:

```auto
sudo rsync -a ~/nextcloud ~/nextcloud.BAK

```

1. Turn on maintenance mode:

```auto
docker exec -u www-data nextcloud_fpm php occ maintenance:mode --on

```

1. Change in `docker-compose.yml`:  
from

```auto
  app:
    image: nextcloud:fpm

```

to

```auto
  app:
    image: nextcloud:17-fpm

```

I got the tag `17-fpm` searching from [here](https://hub.docker.com/_/nextcloud?tab=tags&page=4).

1. Update the docker images:

```auto
docker-compose down

```

```auto
docker-compose pull

```

```auto
docker-compose up -d

```

1. Check that the version is correct (17 in my case):

```auto
docker exec -u www-data nextcloud_fpm php occ status

```

1. Upgrade NC:

```auto
docker exec -u www-data nextcloud_fpm php occ upgrade

```

1. Repeat steps 4-7 for each intermediary major version of NC. And then one more time for the latest version (18 in my case) but in step 4 I change it back to `nextcloud:fpm` (the latest version).

2. Turn off maintenance mode:

```bash
docker exec -u www-data nextcloud_fpm php occ maintenance:mode --off

```

---

<div class="post-metadata">

**Author:** ![iceman1199](https://help.nextcloud.com/letter_avatar/iceman1199/32/6_22734026db12803ebb3e059622ac3534.png) [@iceman1199](https://help.nextcloud.com/u/iceman1199)\
**Post date:** [March 14, 2020, 9:21pm UTC](https://help.nextcloud.com/t/updates-between-multiple-major-versions-are-unsupported/7094/19 "2020-03-14T21:21:09Z")

</div>

Hey @nickvergessen

I am using NextCloud on Unraid for sometime now and trying to update my version of NextCloud but having issues. I’m currently on 16.0.8 trying to update to 17.0.4. Once I select the “Open updater” option I get a white page with the writing “Step 3 is currently in process. Please reload this page later.” It was been stuck like that for almost a month now.

I’ve tried to update manually via the command line using the docker terminal. I get stuck at the command:

sudo -u abc php7 /config/www/nextcloud/occ upgrade

It returns:

NextCloud or one of the apps require upgrade - only a limited number of commands are available  
You may use your browser or the occ upgrade command to do the upgrade  
Set log level to debug  
Turned on maintenance mode  
_Exception: Updates between multiple major versions and downgrades are unsupported._  
_Update failed_  
Maintenance mode is kept active  
Reset log level

Also, when trying to launch the NextCloud docker I get an Internal Server Error. I can provide logs or whatever is needed.

Any assistance is greatly appreciated.

---

<div class="post-metadata">

**Author:** ![Justin\_Roysdon](https://help.nextcloud.com/user_avatar/help.nextcloud.com/justin_roysdon/32/23527_2.png) [@Justin\_Roysdon](https://help.nextcloud.com/u/Justin_Roysdon)\
**Post date:** [June 18, 2020, 9:43pm UTC](https://help.nextcloud.com/t/updates-between-multiple-major-versions-are-unsupported/7094/20 "2020-06-18T21:43:55Z")

</div>

I have found that separating the following folders to a local volume helps the upgrade process a lot:  
config/config.php  
data/  
db (for MySQL or MariaDB, /var/lib/mysql)  
custom\_apps/

With these folders on separate volumes from the container upgrades have been greatly simplified.

---

<div class="post-metadata">

**Author:** ![Toronto](https://help.nextcloud.com/letter_avatar/toronto/32/6_22734026db12803ebb3e059622ac3534.png) [@Toronto](https://help.nextcloud.com/u/Toronto)\
**Post date:** [November 23, 2020, 5:00pm UTC](https://help.nextcloud.com/t/updates-between-multiple-major-versions-are-unsupported/7094/21 "2020-11-23T17:00:30Z")

</div>

> [@nickvergessen](#):
>
> Updates between multiple major versions are unsupported

I allowed nethserver to proceed with a core upgrade - now nextcloud is at 20.0.1 as part of that process  
However nextcloud 1. still brings up the update page  
2. nextcloud is already at 20.0.1 yet brings up an update page for 20.0.1 then  
fails with “Updates between multiple major versions are unsupported”  
wt%??

[Next page](https://help.nextcloud.com/t/updates-between-multiple-major-versions-are-unsupported/7094.md?page=2)
