nextcloud / server

☁️ Nextcloud server, a safe home for all your data
https://nextcloud.com
GNU Affero General Public License v3.0
27.23k stars 4.05k forks source link

Deleting files from MacOS produces LockedException #6371

Closed fynnlyte closed 6 years ago

fynnlyte commented 7 years ago

Relates to https://github.com/nextcloud/server/issues/5262 Occured on a hosted Nextcloud while syncing it for the first time.

Steps to reproduce

  1. Move a folder to the synchronized local Nextcloud-Folder on MacOS
  2. Wait until synchronization starts
  3. Delete the local folder before synchronization is completed

Expected behaviour

The folder and all its content will be removed from the Nextcloud server

Actual behaviour

The folder and some of its contents are still on the Nextcloud server; The files in the folder are locked even after hours; Changes to the folder (trying to manually delete its content) or its parent directory (like renaming) result in error.

Server configuration (hosted)

Database: MySQL/MariaDB

Nextcloud version: (see Nextcloud admin page) 12.0.2 Stable

http://example.com/index.php/settings/integrity/failed 
"No errors have been found."

List of activated apps:

- All official ones except Auditing/Logging, External storage & user support, LDAP user and group backend - Brute-force settings - Calender - Collabora Online - Contacts - Notes - Tasks

Are you using external storage, if yes which one: no

Are you using encryption: yes

Are you using an external user-backend, if yes which one: no

Client configuration

Browser: Firefox 55.0.3

Operating system: MacOS 10.12.6 nextcloud_lytefm_log.txt

MorrisJobke commented 7 years ago

cc @rullzer @pfiff45

fynnlyte commented 7 years ago

My hoster changed to the Redis-Backend for locking. Afterwards, I could successfully edit/delete/synchronize my folders again. Apperently this problem with the default-locking seems to persist:

https://help.nextcloud.com/t/file-is-locked-how-to-unlock/1883

MorrisJobke commented 6 years ago

Thanks for the feedback. In more recent versions (13.0.4 and 12.0.9) we also reduced drastically the amount of lock statements which should avoid most of the problems in here. Thus I will close it. If there is still stuff that breaks have a look at #9305 and it's linked issues.

Another workaround to make those errors even less likely: use Redis as locking backend as written already.