[Solved] Verifying integrity - Not exact 3 files existent in folder

Nextcloud version: 12.0.6
Operating system and version: Debian9
Apache or nginx version: Apache/2.4.25
PHP version: 7.1

I have the problem that when upgrading to the version 13.0.0.1 I at the step “Verifying integrity” not get further it comes the following message: “Not exact 3 files existent in folder” Since I have no idea which 3 files should be missing there I do not really continue here either. the problem is independent of the server for all installations.

Hm, can not anyone help?

Could solve the problem now, thanks!

That’s great, could you leave a bit more details how you solved it for other people running into the same problem?

Hi, Sure, I can. After a good 30 days obviously no one had a solution. I have replaced Nextcloud with OwnCloud and now it works. It is certainly not the solution that is welcome here. But for me it works.

The preferred solution would be to help you in running Nextcloud. I haven’t heard of this specific error and now it’s probably too late to go into it.

ownCloud is much better than proprietary solutions.

Too late, I would not say but after almost 30 days problem finding, you are looking for alternatives slowly. Since OwnCloud is not necessarily the first choice of my side.

  • Basically, the problem only occurs during the update. Whether web or CLI
  • php-zip is installed and works on both web and CLI
  • php.ini are the recommended settings

Obviously NextCloud does not seem to be able to unpack the update file. Below is the log entry from the updater.log

2018-05-05T19:28:02+0000 4MkBuUCKZd [info] storage location: /var/www/clients/client1/web6/web/nextcloud/data/updater-oczpi36u5gw0/downloads/

2018-05-05T19:28:02+0000 4MkBuUCKZd [error] POST request failed with other exception

2018-05-05T19:28:02+0000 4MkBuUCKZd [error] Exception: Exception

Message: Not exact 3 files existent in folder

Code:0

Trace:

#0 /var/www/clients/client1/web6/web/nextcloud/updater/index.php(717): Updater->getDownloadedFilePath()

#1 /var/www/clients/client1/web6/web/nextcloud/updater/index.php(1300): Updater->verifyIntegrity()

#2 {main}

File:/var/www/clients/client1/web6/web/nextcloud/updater/index.php

Line:663
1 Like

Same problem with update from 16.0.5 to nextcloud 17 with updater!

How to solve ?

Hi Witzker,
i got stuck on upgrade from 16.0.5 to 17.0.1 too. Verification failed here:
Got “Message: Signature of update is not valid” and “Message: Not exact 3 files existent in folder”
Reason: Updater expects only latest zip file in download folder with correct signature.

Solution:
Read end of updater.log and find out download path, mine was /volume1/Nextcloud/updater-oc2mk9t8au24/downloads on Synology. Go to this path on Nextcloud server and check out what is there, write down file permissions, mine was rw-r–r-- http:http

Download latest (17.0.1) [nextcloud-17.0.1.zip] from https://download.nextcloud.com/server/releases/ by hand and place it to this folder delete/move the old one so only the latest zip file is in download folder nothing else.
click retry update

Hello
i try to update with 16.0.8 but i have this error message :

Not exact 3 files existent in folder

change with owncloud is not a solution !!!

can you help me please
Thanks

Same problem here:

root@momo ~# cd /srv/nextcloud/updater/
root@momo /s/n/updater# sudo -u www-data php updater.phar
Nextcloud Updater - version: v16.0.3-3-ga0c2b25 dirty

Current version is 18.0.2.

Update to Nextcloud 18.0.3 available. (channel: "stable")
Following file will be downloaded automatically: https://download.nextcloud.com/server/releases/nextcloud-18.0.3.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
[✔] Downloading
[✘] Verify integrity failed
Not exact 3 files existent in folder

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

I had the same problem and realized that the updater checks if there are 3 files in the directory: ., .., and the downloaded zip file. The problem is that on some file systems (e.g. S3QL) the . and .. do not exist.

In my opinion it would be better to actually check for the downloaded zip file instead.

1 Like

I found the issue from my side!
The 3 missing files were not created because of hosting limitations.

  • the maximum numbers of files stored was reached
  • It could have been the same with a disk running out of space
    (in my case: Ionos fake “unlimited” offer, actually 2 TB capacity limit with max nb. of 262 144 files).

I fixed it this way and updated all the way from 19.0 through 22.x

A tip if you have a limitation in the nb of file hosted, when you get an error updating:

  1. if the “Create backup” step is in error (no explicit error for max nb of files reached), you need first to remove some files (thousands) from your hosted folders via FTP or from Nextcloud (ensure you empty the trash) then run the update again (retry button).
  2. if the “Create backup” step is successfully passed, you probably succeedeed the “Downloading” step but failed the “Extracting” step:
  • clean up the extract folder by deleting /data/updater-xxxxx/backups/nextcloud folder (which is the extract of the zipped updater in the folder above)
  • retrieve the backup files from the following folder /data/updater-xxxxx/backups/ via FTP (or create a zip file on the server remotely) then delete the original files (without deleting the zip file of course) then run the update again (retry button).

I hope this will help…

Eventually one suggestion to :information_source: Support developers for the future version of the NC updater: zip the backup to save on space and files nb. limitation…