Update to Nextcloud 27.1.2 (Create backup stage failed)

Hello, I’m trying to update my Nextcloud from version 27.1.1 to 27.1.2.
but I always get an error during backup.

I already checked the rights but it didn’t help: sudo chown -R www-data:www-data /mnt/NAS/nextcloud_data/

There is also enough memory. Does anyone have an idea why this might be?

# sudo -u www-data php --define apc.enable_cli=1 /var/www/nextcloud/updater/updater.phar
Nextcloud Updater - version: v27.1.0rc3-15-gfa7af53

Current version is 27.1.1.

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

Steps that will be executed:
[ ] 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

Start update? [y/N] y

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 ...PHP Warning:  copy(/var/www/nextcloud/config/config.backup.php): Failed to open stream: Permission denied in phar:///var/www/nextcloud/updater/updater.phar/lib/Updater.php on line 412
[✘] Create backup failed
Could not copy "/var/www/nextcloud/config/config.backup.php" to "/mnt/NAS/nextcloud_data/updater-ockke7nz9yxb/backups/nextcloud-". Source /var/www/nextcloud/config/config.backup.php is not readable. Destination /mnt/NAS/nextcloud_data/updater-ockke7nz9yxb/backups/nextcloud- is not writable

Update failed. To resume or retry just execute the updater again.

i do that and now i can update my Nextcloud!

sudo chmod o+r /var/www/nextcloud/config/config.backup.php

Thanks for writing this! My backups stopped all the time whne trying to update via the web interface. And there were no error messages. But with this command “# sudo -u www-data php --define apc.enable_cli=1 /var/www/nextcloud/updater/updater.phar” I can see the problem. It is just a reading issue with the backup of the config files.

Thank you!!!

1 Like