[RESOLVED] Downgrading is not supported and is likely to cause unpredictable issues (from 29.0.1.1 to 29.0.0.19)

Nextcloud version (eg, 20.0.5): 29.0.1.1
Operating system and version (eg, Ubuntu 20.04): Debian 11
Apache or nginx version (eg, Apache 2.4.25): Apache2.4
PHP version (eg, 7.4): php 8.3

Hi,
When I access xxxx.com, the following message appears
Downgrading is not supported and is likely to cause unpredictable issues (from 29.0.1.1 to 29.0.0.19)

In the config file, , I have the following parameter
‘version’ => ‘29.0.1.1’,

And now I have errors with DAV events (that make sense) :

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

                                                         
  There are no commands defined in the "dav" namespace.  

Do you have any idea how to fix it, please ?
Thanxx

Iupdated Nextcloud with the following commands :

  1. php8.3 -f /var/www/xxxx.com/web/updater/updater.phar -e
  2. php8.3 -f /var/www/xxxx.com/web/occ upgrade

I resolved the issue by setting the value ‘version’ => ‘29.0.0.19’ in config file.

Is this the first time you’ve seen this error? (Y/N): Y

Steps to replicate it:

  1. php8.3 -f /var/www/xxxx.com/web/updater/updater.phar -e
  2. php8.3 -f /var/www/xxxx.com/web/occ upgrade
  3. access to xxxx.com

The output of your Nextcloud log in Admin > Logging:

{
  "reqId": "tghSAQbbb8lMzgF6N8e9",
  "level": 3,
  "time": "2024-05-24T08:47:12+02:00",
  "remoteAddr": "2001:41d0:2:dd7c::",
  "user": "--",
  "app": "core",
  "method": "GET",
  "url": "/",
  "message": "Rendering themed error page failed. Falling back to unthemed error page.",
  "userAgent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/115.0.0.0 Safari/537.36",
  "version": "29.0.1.1",
  "exception": {
    "Exception": "OCP\\HintException",
    "Message": "Downgrading is not supported and is likely to cause unpredictable issues (from 29.0.1.1 to 29.0.0.19)",
    "Code": 0,
    "Trace": [
      {
        "file": "/var/www/clients/client1/web8/web/lib/public/Util.php",
        "line": 599,
        "function": "needUpgrade",
        "class": "OC_Util",
        "type": "::"
      },
      {
        "file": "/var/www/clients/client1/web8/web/lib/private/TemplateLayout.php",
        "line": 286,
        "function": "needUpgrade",
        "class": "OCP\\Util",
        "type": "::"
      },
      {
        "file": "/var/www/clients/client1/web8/web/lib/private/legacy/OC_Template.php",
        "line": 145,
        "function": "__construct",
        "class": "OC\\TemplateLayout",
        "type": "->"
      },
      {
        "file": "/var/www/clients/client1/web8/web/lib/public/AppFramework/Http/TemplateResponse.php",
        "line": 211,
        "function": "fetchPage",
        "class": "OC_Template",
        "type": "->"
      },
      {
        "file": "/var/www/clients/client1/web8/web/lib/private/legacy/OC_Template.php",
        "line": 269,
        "function": "render",
        "class": "OCP\\AppFramework\\Http\\TemplateResponse",
        "type": "->"
      },
      {
        "file": "/var/www/clients/client1/web8/web/index.php",
        "line": 60,
        "function": "printErrorPage",
        "class": "OC_Template",
        "type": "::"
      }
    ],
    "File": "/var/www/clients/client1/web8/web/lib/private/legacy/OC_Util.php",
    "Line": 1155,
    "Hint": "Downgrading is not supported and is likely to cause unpredictable issues (from 29.0.1.1 to 29.0.0.19)",
    "message": "Rendering themed error page failed. Falling back to unthemed error page.",
    "CustomMessage": "Rendering themed error page failed. Falling back to unthemed error page."
  },
  "id": "665039a0eba36"
}

Hey @cedrix and welcome to the communityforum of NC.

Sorry to hear you’re facing problems. And sadly enough it’s correct: downgrading isn’t supported by NC.

It’s not completely clear to me where exactly you got stuck (I never tried any downgrading). You forced downgrading… and after that your server showed up with that message? Which would mean the process went through, completely?

If yes I’d ask you to restore the automated backup the process usually takes (or the backup you took before deciding to downgrade) - that would help the easiest way.

1 Like

Hello @JimmyKater and thank you for taking the time to reply.

I must have expressed myself poorly. Actually, it was following an update to 29.0.1 that I encountered the downgrade message.
The update process seemed to have gone through successfully:

Nextcloud Updater - version: v28.0.2rc3-15-gde0582d

Current version is 29.0.0.

Update to Nextcloud 29.0.1 available. (channel: "stable")
Following file will be downloaded automatically: https://download.nextcloud.com/server/releases/nextcloud-29.0.1.zip
Open changelog ↗

Updater run in non-interactive mode.

Start update

Info: Pressing Ctrl-C will finish the currently running step and then stops the updater.

[ ] Check for expected files ... e[2K[✔] Check for expected files
[ ] Check for write permissions ... e[2K[✔] Check for write permissions
[ ] Create backup ... e[2K[✔] Create backup
[ ] Downloading ... e[2K[✔] Downloading
[ ] Verify integrity ... e[2K[✔] Verify integrity
[ ] Extracting ... e[2K[✔] Extracting
[ ] Enable maintenance mode ... e[2K[✔] Enable maintenance mode
[ ] Replace entry points ... e[2K[✔] Replace entry points
[ ] Delete old files ... e[2K[✔] Delete old files
[ ] Move new files in place ... e[2K[✔] Move new files in place
[ ] Done ... e[2K[✔] Done

Update of code successful.
Updater run in non-interactive mode - will start "occ upgrade" now.

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
Setting log level to debug
Repair step: Repair MySQL collation
Repair info: All tables already have the correct collation -> nothing to do
Repair step: Copy data from accounts table when migrating from ownCloud
Repair step: Drop account terms table when migrating from ownCloud
Updating database schema
Updated database
Repair step: Repair MySQL collation
Repair info: All tables already have the correct collation -> nothing to do
Repair step: Copy data from accounts table when migrating from ownCloud
Repair step: Drop account terms table when migrating from ownCloud
Repair step: Remove the unused News update job
Repair info: Job does not exist, all good
Repair step: Repair MySQL collation
Repair info: All tables already have the correct collation -> nothing to do
Repair step: Repair mime types
Repair step: Clean tags and favorites
Repair info: 0 tags of deleted users have been removed.
Repair info: 0 tags for delete files have been removed.
Repair info: 0 tag entries for deleted tags have been removed.
Repair info: 0 tags with no entries have been removed.
Repair step: Repair invalid shares
Repair step: Move .step file of updater to backup location
Repair info: .step file exists
Repair info: .step-previous-update removed
Repair info: .step file moved to .step-previous-update
Repair step: Add move avatar background job
Repair info: Repair step already executed
Repair step: Add preview cleanup background jobs
Repair step: Migrate oauth2_clients table to nextcloud schema
Repair info: Update the oauth2_access_tokens table schema.
Repair info: Update the oauth2_clients table schema.
Repair info: Delete clients (and their related access tokens) with the redirect_uri starting with oc:// or ending with *
Repair step: Fix potential broken mount points
Repair info: No mounts updated
Repair step: Repair language codes
Repair step: Add log rotate job
Repair step: Clear frontend caches
Repair info: Image cache cleared
Repair info: JS cache cleared
Repair step: Clear every generated avatar
Repair step: Add preview background cleanup job
Repair step: Queue a one-time job to cleanup old backups of the updater
Repair step: Cleanup invalid photocache files for carddav
Repair step: Add background job to cleanup login flow v2 tokens
Repair step: Remove potentially over exposing share links
Repair info: No need to remove link shares.
Repair step: Clear access cache of projects
Repair step: Reset generated avatar flag
Repair step: Keep legacy encryption enabled
Repair step: Check encryption key format
Repair step: Remove old dashboard app config data
Repair step: Add job to cleanup the bruteforce entries
Repair step: Queue a one-time job to check for user uploaded certificates
Repair step: Repair DAV shares
Repair step: Add background job to set the lookup server share state for users
Repair step: Add token cleanup job
Repair step: Clean up abandoned apps
Repair step: Add possibly missing system config
Repair step: Add AI tasks cleanup job
Repair step: Queue a job to generate metadata
Repair step: migrate lazy config values
Starting code integrity check...
Finished code integrity check
Update successful
Maintenance mode is kept active
Resetting log level

Updater run in non-interactive mode - will disable maintenance mode now.
Maintenance mode disabled

Maintenance mode is disabled

I don’t know why I find myself in a downgrade situation when I applied an update.

Thank you again for your help.
Cédrix

Exact problem here. I had to restore the backup and run occ upgrade to fix it.

Same problem here

My NC is stunk after the last upgrade

Downgrading is not supported and is likely to cause unpredictable issues (from 29.0.1.1 to 29.0.0.19)

Nextcloud Updater - version: v28.0.2rc3-15-gde0582d

Current version is 29.0.0.

Update to Nextcloud 29.0.1 available. (channel: "stable")
Following file will be downloaded automatically: https://download.nextcloud.com/server/releases/nextcloud-29.0.1.zip
Open changelog ↗

Updater run in non-interactive mode.

Start update

Info: Pressing Ctrl-C will finish the currently running step and then stops the updater.

[✔] Check for expected files
[✔] Check for write permissions
[✔] Create backup
[✔] Downloading
[✔] Verify integrity
[✔] Extracting
[✔] Enable maintenance mode
[✔] Replace entry points
[✔] Delete old files
[✔] Move new files in place
[✔] Done

Update of code successful.
Updater run in non-interactive mode - will start "occ upgrade" now.

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
Setting log level to debug
Repair step: Repair MySQL collation
Repair info: All tables already have the correct collation -> nothing to do
Repair step: Copy data from accounts table when migrating from ownCloud
Repair step: Drop account terms table when migrating from ownCloud
Updating database schema
Updated database
Update app spreed from App Store
Repair step: Repair MySQL collation
Repair info: All tables already have the correct collation -> nothing to do
Repair step: Copy data from accounts table when migrating from ownCloud
Repair step: Drop account terms table when migrating from ownCloud
Repair step: Fix the namespace in database tables
Repair step: Repair MySQL collation
Repair info: All tables already have the correct collation -> nothing to do
Repair step: Copy data from accounts table when migrating from ownCloud
Repair step: Drop account terms table when migrating from ownCloud
Repair step: Fix the namespace in database tables
Repair step: Create help command
Repair step: Invalidate access cache for projects conversation provider
Repair info: Invalidation not required
Repair step: Cache the user display names
Repair step: Repair MySQL collation
Repair info: All tables already have the correct collation -> nothing to do
Repair step: Repair mime types
Repair step: Clean tags and favorites
Repair info: 0 tags of deleted users have been removed.
Repair info: 0 tags for delete files have been removed.
Repair info: 0 tag entries for deleted tags have been removed.
Repair info: 0 tags with no entries have been removed.
Repair step: Repair invalid shares
Repair step: Move .step file of updater to backup location
Repair info: .step file exists
Repair info: .step-previous-update removed
Repair info: .step file moved to .step-previous-update
Repair step: Add move avatar background job
Repair info: Repair step already executed
Repair step: Add preview cleanup background jobs
Repair step: Migrate oauth2_clients table to nextcloud schema
Repair info: Update the oauth2_access_tokens table schema.
Repair info: Update the oauth2_clients table schema.
Repair info: Delete clients (and their related access tokens) with the redirect_uri starting with oc:// or ending with *
Repair step: Fix potential broken mount points
Repair info: No mounts updated
Repair step: Repair language codes
Repair step: Add log rotate job
Repair step: Clear frontend caches
Repair info: Image cache cleared
Repair info: JS cache cleared
Repair step: Clear every generated avatar
Repair step: Add preview background cleanup job
Repair step: Queue a one-time job to cleanup old backups of the updater
Repair step: Cleanup invalid photocache files for carddav
Repair step: Add background job to cleanup login flow v2 tokens
Repair step: Remove potentially over exposing share links
Repair info: No need to remove link shares.
Repair step: Clear access cache of projects
Repair step: Reset generated avatar flag
Repair step: Keep legacy encryption enabled
Repair step: Check encryption key format
Repair step: Remove old dashboard app config data
Repair step: Add job to cleanup the bruteforce entries
Repair step: Queue a one-time job to check for user uploaded certificates
Repair step: Repair DAV shares
Repair step: Add background job to set the lookup server share state for users
Repair step: Add token cleanup job
Repair step: Clean up abandoned apps
Repair step: Add possibly missing system config
Repair step: Add AI tasks cleanup job
Repair step: Queue a job to generate metadata
Repair step: migrate lazy config values
Starting code integrity check...
Finished code integrity check
Update successful
Maintenance mode is kept active
Resetting log level

Updater run in non-interactive mode - will disable maintenance mode now.
Maintenance mode disabled

Any idea how to recovery from this ? (without a restore from yesterday)
ps: I’m another “cedr-x”, not the same guy

Without restoration, I have:

  1. Switched NC to offline mode: occ maintenance:mode --on
  2. Modified the parameter 'version' => '29.0.0.19'
  3. Ran the upgrade command: occ upgrade
  4. Switched back to online mode: occ maintenance:mode --off

It’s now okay!

Thanxx for the ideas

My best guess is that the version.php file from your prior version was cached still.

You can manually see what is in your /version.php file within your installation folder (note: I’m referring to the dedicated file, not the version variable in config.php).

If my hypothesis is correct, I think a web server (if using mod_php) or fpm restart might resolve it.

Though I’m not sure why this would be a issue newly cropping up now if your environment has been upgraded before w/o this occurring. :thinking:

Oh !
I’ve restored my VM without even restart php_fpm. I can’t tell you.
Maybe it’s due to APCu (v5.1.23 )
I’ll try another ugrade this evening and see if I can reproduce this issue

The version.php was:

<?php 
$OC_Version = array(29,0,1,1);
$OC_VersionString = '29.0.1';
$OC_Edition = '';
$OC_Channel = 'stable';
$OC_VersionCanBeUpgradedFrom = array (
  'nextcloud' => 
  array (
    '28.0' => true,
    '29.0' => true,
  ),
  'owncloud' => 
  array (
    '10.13' => true,
  ),
);
$OC_Build = '2024-05-23T15:20:00+00:00 3bb0c9b012f0e87ccddd37e4782d3fb5ae2025a6';
$vendor = 'nextcloud';

while the version variable in config.php

  'version' => '29.0.1.1'

Thank you both, Cédrix and jtr for the help.
Cédric

You should better to restart the redis server.

sudo systemctl restart redis-server.service

Redis shouldn’t be a factor in this case This is at the PHP opcache level. Having non-default validation/re-validation settings for example: PHP: Runtime Configuration - Manual

In extreme cases, some people turn off validation completely in an attempt to optimize performance, but then forget that it means restarts are required nearly for sure after major updates/code changes. Even leaving enabled but having larger (non-default) values can cause this sort of behavior. Technically, even the defaults can cause this behavior, though it’s less likely.

I’ve re-run an updater.phar
And the problem occurred again. I’ve just reboot, and things worked back again :slight_smile:
Sorry, I did not analyse deeper (service first!) but I bet that it’s a opcache issue
I’ll restart php-fpm in my nightly script after an update, it wont cost a penny
Have a good weed end
Cédric

2 Likes

This topic was automatically closed 8 days after the last reply. New replies are no longer allowed.