Feature request - clear locked files

I get locked file quite regularly, and surely programatically, it would be no task to do as suggested below? This should be on the cloud feature under admin.

Manually disable locking state:

put ownCloud in maintenance mode: edit config/config.php and change this line:
'maintenance' => true,
Empty table oc_file_locks: Use tools such as phpmyadmin or connect directly to your database and run:
DELETE FROM oc_file_locks WHERE 1
disable maintenance mode (undo first step).

ownCloud currently has at least 2 different locking:

I assume in your case, you have trouble with Transactional File Locking. But you shouldn’t see that much locks, and they should self-disappear very fast. Sounds like serious issue with your server setup. (PHP process killed too fast for example). For this reason, a client feature for this doesn’t make sense.

Please check:

  • How long can PHP process run?
  • Use Redis to handle Transactional File Locking

We plan to support Manual File Locking in the client in a future version. (no ETA yet)

1 Like

Enabled Redis thank you. max_execution_time 30 secs PHP.

This is definitely too short. Check server docs, I think there the recommendation is 1h or so. Big file operations can easily be longer than 30s, then the unlock at the end is often missed.


This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.