WebDAV: rclone copy runs into locked files

What is the problem you are having with rclone?

Task: copy 2.5GB file from local (Linux) to Owncloud WebDAV.
Problem: sometimes copies file to remote, but never realises locally and then tries to copy again (see log). I guess some check fails.

What is your rclone version (output from rclone version)

1.57.0

Which OS you are using and how many bits (eg Windows 7, 64 bit)

Ubuntu 18.04

Which cloud storage system are you using? (eg Google Drive)

Owncloud WebDAV

The command you were trying to run (eg rclone copy /tmp remote:tmp)

rclone copy -P --use-cookies --log-file ~/rclone.log --log-level DEBUG --retries 1 --low-level-retries 2 /data/dir remote:dir

The rclone config contents with secrets removed.

[remote]
type = webdav
url = https://url.to/webdav
vendor = owncloud

A log from the command with the -vv flag

2021/11/24 10:29:06 DEBUG : rclone: Version "v1.57.0" starting with parameters ["rclone" "copy" "-P" "--use-cookies" "--log-file" "/home/user/rclone.log" "--log-level" "DEBUG" "--retries" "1" "--low-level-retries" "2" "/data/dir" "remote:dir"]
2021/11/24 10:29:06 DEBUG : Creating backend with remote "/data/dir"
2021/11/24 10:29:06 DEBUG : Using config file from "/home/user/.config/rclone/rclone.conf"
2021/11/24 10:29:06 DEBUG : Creating backend with remote "remote:dir"
2021/11/24 10:29:06 DEBUG : found headers: 
2021/11/24 10:29:07 DEBUG : webdav root 'dir': Waiting for checks to finish
2021/11/24 10:29:07 DEBUG : webdav root 'dir': Waiting for transfers to finish
2021/11/24 10:29:07 DEBUG : pacer: low level retry 1/2 (error "dir" is locked: OCA\DAV\Connector\Sabre\Exception\FileLocked: 423 Locked)
2021/11/24 10:29:07 DEBUG : pacer: Rate limited, increasing sleep to 20ms
2021/11/24 10:29:07 DEBUG : pacer: Reducing sleep to 15ms
2021/11/24 10:29:07 DEBUG : pacer: Reducing sleep to 11.25ms
2021/11/24 10:29:09 DEBUG : pacer: Reducing sleep to 10ms
2021/11/24 10:29:09 DEBUG : file1: md5 = 0d11c89284e72e0f2535c528bd85d592 OK
2021/11/24 10:29:09 INFO  : file1: Copied (new)
2021/11/24 10:35:09 DEBUG : pacer: low level retry 1/1 (error Put "https://url.to/webdav/dir/file2": net/http: timeout awaiting response headers)
2021/11/24 10:35:09 DEBUG : pacer: Rate limited, increasing sleep to 20ms
2021/11/24 10:35:10 DEBUG : pacer: low level retry 1/2 (error "dir/file2" is locked: OCA\DAV\Connector\Sabre\Exception\FileLocked: 423 Locked)
2021/11/24 10:35:10 DEBUG : pacer: Rate limited, increasing sleep to 40ms
2021/11/24 10:35:11 DEBUG : pacer: low level retry 2/2 (error "dir/file2" is locked: OCA\DAV\Connector\Sabre\Exception\FileLocked: 423 Locked)
2021/11/24 10:35:11 DEBUG : pacer: Rate limited, increasing sleep to 80ms
2021/11/24 10:35:11 DEBUG : file2: Received error: Put "https://url.to/webdav/dir/file2": net/http: timeout awaiting response headers - low level retry 1/2
2021/11/24 10:35:11 DEBUG : pacer: Reducing sleep to 60ms
2021/11/24 10:36:05 DEBUG : pacer: low level retry 1/1 (error "dir/file2" is locked: OCA\DAV\Connector\Sabre\Exception\FileLocked: 423 Locked)
2021/11/24 10:36:05 DEBUG : pacer: Rate limited, increasing sleep to 120ms
2021/11/24 10:36:07 DEBUG : pacer: Reducing sleep to 90ms
2021/11/24 10:36:07 ERROR : file2: Failed to copy: "dir/file2" is locked: OCA\DAV\Connector\Sabre\Exception\FileLocked: 423 Locked
2021/11/24 10:36:07 ERROR : Attempt 1/1 failed with 1 errors and: "dir/file2" is locked: OCA\DAV\Connector\Sabre\Exception\FileLocked: 423 Locked
2021/11/24 10:36:07 INFO  : 
Transferred:   	    4.969 GiB / 4.969 GiB, 100%, 78.868 MiB/s, ETA 0s
Errors:                 1 (retrying may help)
Transferred:            1 / 1, 100%
Elapsed time:       7m0.8s

2021/11/24 10:36:07 DEBUG : 6 go routines active
2021/11/24 10:36:07 Failed to copy: "dir/file2" is locked: OCA\DAV\Connector\Sabre\Exception\FileLocked: 423 Locked

This is the root cause of the problem.

Try increasing the --timeout parameter and the --contimeout parameter.

Thanks Nick, this works. I also ran into timeouts with cadavar, so this makes a lot sense. Can be closed.

1 Like

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