"file has changed since discovery" errors + date bug

I cannot get rid of the desktop sync error:
“file has changed since discovery”. Tried replacing and renaming files in both server or desktop environment, also downgrading desktop client version. It happens in two of my computers for the same files.

This started happening after desktop client update to 3.2 and briefly enabling virtual files.

[/details]

Nextcloud version: 21.0.1
Operating system and version: Ubuntu 18.04
Apache version: 2.4.46
PHP: 7.4.13

The output of your Nextcloud log in Admin > Logging:

26T07:13:15+00:00","remoteAddr":"****","user":"****","app":"core","method":"PROPFIND","url":"/remote.php/dav/files/****/Justo/Photos/Telefo","message":{"Exception":"Doctrine\\DBAL\\Query\\QueryException","Message":"More than 1000 expressions in a list are not allowed on Oracle.","Code":0,"Trace":[{"file":"/var/www/html/lib/private/Comments/Manager.php","line":657,"function":"execute","class":"OC\\DB\\QueryBuilder\\QueryBuilder","type":"->"},{"file":"/var/www/html/apps/dav/lib/Connector/Sabre/CommentPropertiesPlugin.php","line":89,"function":"getNumberOfUnreadCommentsForObjects","class":"OC\\Comments\\Manager","type":"->"},{"file":"/var/www/html/apps/dav/lib/Connector/Sabre/CommentPropertiesPlugin.php","line":117,"function":"cacheDirectory","class":"OCA\\DAV\\Connector\\Sabre\\CommentPropertiesPlugin","type":"->"},{"file":"/var/www/html/3rdparty/sabre/event/lib/WildcardEmitterTrait.php","line":89,"function":"handleGetProperties","class":"OCA\\DAV\\Connector\\Sabre\\CommentPropertiesPlugin","type":"->"},{"file":"/var/www/html/3rdparty/sabre/dav/lib/DAV/Server.php","line":1052,"function":"emit","class":"Sabre\\DAV\\Server","type":"->"},{"file":"/var/www/html/3rdparty/sabre/dav/lib/DAV/Server.php","line":984,"function":"getPropertiesByNode","class":"Sabre\\DAV\\Server","type":"->"},{"file":"/var/www/html/3rdparty/sabre/dav/lib/DAV/Server.php","line":1661,"function":"getPropertiesIteratorForPath","class":"Sabre\\DAV\\Server","type":"->"},{"file":"/var/www/html/3rdparty/sabre/dav/lib/DAV/Server.php","line":1646,"function":"writeMultiStatus","class":"Sabre\\DAV\\Server","type":"->"},{"file":"/var/www/html/3rdparty/sabre/dav/lib/DAV/CorePlugin.php","line":346,"function":"generateMultiStatus","class":"Sabre\\DAV\\Server","type":"->"},{"file":"/var/www/html/3rdparty/sabre/event/lib/WildcardEmitterTrait.php","line":89,"function":"httpPropFind","class":"Sabre\\DAV\\CorePlugin","type":"->"},{"file":"/var/www/html/3rdparty/sabre/dav/lib/DAV/Server.php","line":472,"function":"emit","class":"Sabre\\DAV\\Server","type":"->"},{"file":"/var/www/html/3rdparty/sabre/dav/lib/DAV/Server.php","line":253,"function":"invokeMethod","class":"Sabre\\DAV\\Server","type":"->"},{"file":"/var/www/html/3rdparty/sabre/dav/lib/DAV/Server.php","line":321,"function":"start","class":"Sabre\\DAV\\Server","type":"->"},{"file":"/var/www/html/apps/dav/lib/Server.php","line":332,"function":"exec","class":"Sabre\\DAV\\Server","type":"->"},{"file":"/var/www/html/apps/dav/appinfo/v2/remote.php","line":35,"function":"exec","class":"OCA\\DAV\\Server","type":"->"},{"file":"/var/www/html/remote.php","line":167,"args":["/var/www/html/apps/dav/appinfo/v2/remote.php"],"function":"require_once"}],"File":"/var/www/html/lib/private/DB/QueryBuilder/QueryBuilder.php","Line":268,"CustomMessage":"More than 1000 expressions in a list are not allowed on Oracle."},"userAgent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:88.0) Gecko/20100101 Firefox/88.0","version":"21.0.1.1"}cd

The CONTENTS (not output) of your config.php file in /path/to/nextcloud/config/:

<?php
$CONFIG = array (
  'instanceid' => '***',
  'passwordsalt' => '***',
  'secret' => '***',
  'trusted_domains' =>
  array (
    0 => '192.168.8.107',
    1 => '***',
    2 => '***',
    3 => '***',
    4 => '***',
  ),
  'datadirectory' => '/mnt/diskas1',
  'dbtype' => 'mysql',
  'version' => '21.0.1.1',
  'overwrite.cli.url' => 'http://192.168.8.107',
  'dbname' => 'nc',
  'dbhost' => 'localhost',
  'dbport' => '',
  'dbtableprefix' => 'oc_',
  'dbuser' => '***',
  'dbpassword' => '***',
  'installed' => true,
  'mail_smtpmode' => 'smtp',
  'mail_smtpsecure' => 'ssl',
  'mail_sendmailmode' => 'smtp',
  'mail_from_address' => '',
  'mail_domain' => '***',
  'mail_smtpauthtype' => 'LOGIN',
  'mail_smtpauth' => 1,
  'mail_smtphost' => '***',
  'mail_smtpport' => '465',
  'mail_smtpname' => '***',
  'mail_smtppassword' => '***',
  'maintenance' => false,
  'theme' => '',
  'loglevel' => 2,
  'updater.secret' => '***',
  'has_rebuilt_cache' => true,
  'updater.release.channel' => 'stable',
  'memcache.locking' => '\\OC\\Memcache\\Redis',
  'memcache.distributed' => '\\OC\\Memcache\\Redis',
  'memcache.local' => '\\OC\\Memcache\\Redis',
  'redis' =>
  array (
    'host' => 'localhost',
    'port' => 6379,
    'timeout' => 3,
  ),
  'mysql.utf8mb4' => true,
  'app_install_overwrite' =>
  array (
    0 => 'joplin',
    1 => 'gpxedit',
    2 => 'sharerenamer',
  ),
);

The output of your Apache log in /var/log/apache2/error.log:

[Mon Apr 26 06:25:02.333230 2021] [:error] [pid 1912] python_init: Python version mismatch, expected '2.7.6', found '2.7.17'.
[Mon Apr 26 06:25:02.333345 2021] [:error] [pid 1912] python_init: Python executable found '/usr/bin/python'.
[Mon Apr 26 06:25:02.333352 2021] [:error] [pid 1912] python_init: Python path being used '/usr/lib/python2.7:/usr/lib/python2.7/plat-x86_64-linux-gnu:/$
[Mon Apr 26 06:25:02.333366 2021] [:notice] [pid 1912] mod_python: Creating 8 session mutexes based on 150 max processes and 0 max threads.
[Mon Apr 26 06:25:02.333370 2021] [:notice] [pid 1912] mod_python: using mutex_directory /tmp
[Mon Apr 26 06:25:02.341440 2021] [mpm_prefork:notice] [pid 1912] AH00163: Apache/2.4.46 (Ubuntu) OpenSSL/1.1.1g mod_python/3.3.1 Python/2.7.17 configur$
[Mon Apr 26 06:25:02.341451 2021] [core:notice] [pid 1912] AH00094: Command line: '/usr/sbin/apache2'
[Mon Apr 26 06:49:06.228127 2021] [access_compat:error] [pid 8017] [client //ip//:64924] AH01797: client denied by server configuration: /var/www/$
[Mon Apr 26 07:08:53.431975 2021] [access_compat:error] [pid 9964] [client //ip//:53775] AH01797: client denied by server configuration: /var/www/$
[Mon Apr 26 07:17:01.267934 2021] [access_compat:error] [pid 10313] [client 192.168.8.105:65092] AH01797: client denied by server configuration: /var/ww$
[Mon Apr 26 08:51:11.124142 2021] [php7:error] [pid 15221] [client //ip//:55750] script '/var/www/html/config.php' not found or unable to stat

Edit: wrong timestamp problem was not related, I fixed it by rescanning files on server side. The main problem persists.

I have been getting the “File has changed since discovery” errors too. The files can be accessed by web just fine, but the desktop client is struggling after enabling Virtual Files

1 Like

How did you solve this issue? I am getting this as well and do not know how to get rid of it.

Same here.

EDIT:
After removing synchronisation of the folder and setting it up again, it works :tada:

I have this issue as well. I’m using nextcloud and OneDrive synchronize in the same folder. nextcloud generated a lot hidden files, then I exit Onedrive try to let nextcloud synchronization finish first.

I faced the same issue today.
I set up the new nextcloud instance and connected the desktop folder to it ~1 month ago. The desktop client was set to sync everything with virtual files enabled. Today I decided to not sync every folder from the nextcloud (it created Talk and Calendar folders that I didn’t want on my PC) but I didn’t find the checkboxes to remove some folders from sync.
I needed to disable virtual files support to be able to exclude some folders (make checkboxes active). When I connected exactly the same folder (synced before) to exactly the same server with no changes I got more than a thousand “file has changed since discovery” errors. One for each photo.
I tried pausing the sync, removing the folder sync connection, and adding this folder again. It didn’t help. I decided to wait until it finishes scanning all files. It goes on for 3+ hours as I’m writing this post.

Is there any issue created on github regarding this problem?

I realized it should never consider use onedrive and nextcloud in the same folder, their synchronized mechanism are different, one drive will create a lot of hidden files the sync, but nextcloud it’s in different way. Only solutions will be using the app in nextcloud