It could be. To fix it place the Seafile directory out of DFS. There is a hidden directory which is heavily being used. You can still sync libraries on DFS.
I did as you told me and placed the Seafile directory on a local drive not SYNCED With DFS.
I do not encounter any problem anymore.
I think that it could be mentioned during the client Installation process and on the manual.
Actually, there is not a lot of information no best pratices about the client.
I’m pretty sure the issues involved in such a setup have been discussed multiple times. Inotify (a mechanism to get notified when a file changed) does not work with CIFS/DFS, thus the client needs to rescan the whole library over and over again (using the sync interval). That can be a resource hungry process and is likely going to take more and more time the more files there are.
This is exactly what happens. And it could also be the reason why the process is so long on huge libraries (>5Go).
Tiis is a major issue for us. I hope this can be fixed in future releases of the client, but i’m not very optimitic.
Are you, @daniel.pan ?
The client has to scan all the folder, checking the timestamp for all the files. It does not read the actual file content. So the performance depends on the number of files. This can’t be improved in the future.
It is not really the case. It is still the client which is syncing. In the best case synchronization always happens from the machine the disk is in. The client was always developed to synchronize local file systems.
Performance Tuning using Change Notify
This section describes performance tuning using the Change Notify feature and internationalization.
NOTE: Starting with the Samba 3.0.25 version, the Change Notify Timeout feature is deprecated.
The Change Notify Timeout feature is replaced with the Change Notify feature. This new feature
depends on Linux iNotify, which is not available in HP-UX operating systems.
The Samba Server supports a new feature called Change Notify. Change Notify provides the
ability for a client to request notification from the server when changes occur to files or subdirectories
below a directory on a mapped file share. When a file or directory which is contained within the
specified directory is modified, the server notifies the client. The purpose of this feature is to keep
the client screen display up-to-date in Windows Explorer. The result: if a file you are looking at in
Windows Explorer is changed while you are looking at it, you will see the changes on the screen
almost immediately.
The only way to implement this feature in Samba is to periodically scan through every file and
subdirectory below the directory in question and check for changes made since the last scan. This
is a resource intensive operation which has the potential to affect the performance of Samba as
well as other applications running on the system. Two major factors affect how resource intensive
a scan is: the number of directories having a Change Notify request on them, and the size of those
directories. If you have many clients running Windows Explorer (or other file browsers) or if you
have directories on shares with a large number of files and/or subdirectories, each scan cycle
might be very CPU intensive.
I’m very concerned about his issue because most of our users start using the client while their data is on CIFS shares.
Is there any tuning that can be done :
on the client (Other protocol than Inotifiy ?)
on the server (CIFS / SMB on a DELL R530 + Windows Server 2016)
Sync subscribes to OS notifications to get immediate updates about file changes and start delivering changed files. However, if a synced folder is located on SMB share, it may not be possible to subscribe to file update notifications. Only SMB 3.0 and newer supports notifications (which means, that both your client and server should have SMB 3.0 to get working notifications). If Sync is unable to get notifications, it will only detect file changes during full folder rescan.
Microsoft introduced SMB 3.0 in Windows 8, though it may be installed to your OS with Microsoft Updates (or via any other updates if you are using non-MS OS)
Windows 2016 Server uses SMB 3.1.1, is there any workaround ?
The client will periodically scan the folder CIFS if sync interval is set. The performance depends on the number of files. If you have only a few thousands of files, you don’t need to worry about the performance.
Then i should set Sync interval to 60 seconds and limit the number of files.
Because is depends of user parameters, it may be a potential issue and leads users thinking the client is not working good.
I’ll keep in mind the problem and i also recommand you to think about implemetaing a different event handling process compatible with CIFS, is possible.