Rclone Nextcloud WebDAV mount - server-side move extremly slow

What is the problem you are having with rclone?

Hey all :slight_smile:
I am having problems with my WebDAV mount.
Up- & download are amazingly fast, as both my computer and the server running Nextcloud are connected via 10Gbit/s Ethernet. But recently I've been moving my images to other subdirectories on my Nextcloud server.
These move commands seem to be executed server-side and and should be correspondingly even faster than if the data were first cached locally on my computer.
But somehow the transfer rate is extremely slow - between 0.6-1 items per second!
Since I move thousands of images, this is quite a problem.
Copying files is - compared to moving and deleting files - super fast. Also, when moving/deleting entire folders, these folders seem to be treated as one item and are therefore moved/deleted in the same way as if I were to move/delete a single file.

Run the command 'rclone version' and share the full output of the command.

rclone v1.64.0
- os/version: Microsoft Windows 11 Pro 22H2 (64 bit)
- os/kernel: 10.0.22621.2283 (x86_64)
- os/type: windows
- os/arch: amd64
- go/version: go1.21.1
- go/linking: static
- go/tags: cmount

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

Nextcloud v27.1.1 running on TrueNAS SCALE v22.12.2

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

Here the exiftool command:

exiftool -v -r -directory=%d/03-JPG_Other -if 'not $model =~ /D70s/' -ext JPG

Please run 'rclone config redacted' and share the full output. If you get command not found, please make sure to update rclone.

[nextcloud]
type = webdav
pass = XXX
url = https://nextcloud.DOMAIN.TLD/remote.php/dav/files/USER%20NAME
user = XXX
vendor = nextcloud
nextcloud_chunk_size = 8Gi

My rclone.bat file that I use to automatically mount my WebDAV mount

@set RCLONE_CONFIG=rclone.conf
@set rclone=C:\rclone\rclone.exe
@set logfile=C:\rclone\log.txt
@set log=--log-level=INFO --log-file=%logfile%

@del %logfile%
start %rclone% selfupdate %log%
start %rclone% mount nextcloud:\ N: --volname Nextcloud --check-first --checkers 50 --transfers 50 --order-by name --vfs-cache-mode full  %log%

I already tried adding --disable move to my rclone mount command to disable server-side move commands. But without success.
Adding --transfers 50 seems to only impact up- and downloads but since those move commands are server-side, there is no impact on concurrent server-side moves.
Adding -checkers 50 didn't seem to change server-side concurrency either...

I was trying to move files both with the default Windows Explorer GUI and some script exiftool script I made to automatically sort my pictures depending on their extension and camera model.
Here is the rclone logfile output if I set the log-level in the above posted bat-file to DEBUG

welcome to the forum,

so, is this a server issue or a rclone issue?
what other copy tools have you tested?

does nothing on a mount.

not sure what you mean, what was not successful?
what exactly did rclone do and/or not do?

fwiw, should be easier to test, on a single file using rclone move
and the less flags the better, so i would remove nextcloud_chunk_size = 8Gi

Thanks for your reply :slight_smile:

That's the question. I am not sure.
But I don't know where I could tune these server-side move settings within nextcloud.

You mean copy/move tools? Well, mainly the built-in copy/move function within Windows Explorer and - as mentioned above - exiftool via CLI.

I mean it didn't improved the move speed at all as I added --disable move to my rclone mount command.

I just removed all unneccessary flags.
Here my rclone config:

[nextcloud]
type = webdav
pass = XXX
url = https://nextcloud.DOMAIN.TLD/remote.php/dav/files/USER%20NAME
user = XXX
vendor = nextcloud
### Double check the config for sensitive info before posting publicly

and here my rclone mount bat file:

@set RCLONE_CONFIG=rclone.conf
@set rclone=C:\rclone\rclone.exe
@set logfile=C:\rclone\log.txt
@set log=--log-level=DEBUG --log-file=%logfile%

@del %logfile%
start %rclone% selfupdate %log%
start %rclone% mount nextcloud:\ N: --volname Nextcloud --vfs-cache-mode full %log%

And as proposed, I used rclone move command to test the performance:

C:\rclone>rclone move "N:\Pictures\2009\testfolder" "N:\Pictures\2009\testfolder-2" --include "*.JPG" -vv
2023/10/10 19:45:40 DEBUG : rclone: Version "v1.64.0" starting with parameters ["rclone" "move" "N:\\Pictures\\2009\\testfolder" "N:\\Pictures\\2009\\testfolder-2" "--include" "*.JPG" "-vv"]
2023/10/10 19:45:40 DEBUG : Creating backend with remote "N:\\Pictures\\2009\\testfolder"
2023/10/10 19:45:40 DEBUG : Using config file from "C:\\rclone\\rclone.conf"
2023/10/10 19:45:41 DEBUG : fs cache: renaming cache item "N:\\Pictures\\2009\\testfolder" to be canonical "//?/N:/Pictures/2009/testfolder"
2023/10/10 19:45:41 DEBUG : Creating backend with remote "N:\\Pictures\\2009\\testfolder-2"
2023/10/10 19:45:41 DEBUG : fs cache: renaming cache item "N:\\Pictures\\2009\\testfolder-2" to be canonical "//?/N:/Pictures/2009/testfolder-2"
2023/10/10 19:45:41 DEBUG : IMGP1540 - Copy.JPG: Need to transfer - File not found at Destination
2023/10/10 19:45:41 DEBUG : IMGP1540.JPG: Need to transfer - File not found at Destination
2023/10/10 19:45:41 DEBUG : IMGP1541 - Copy.JPG: Need to transfer - File not found at Destination
2023/10/10 19:45:41 DEBUG : IMGP1541.JPG: Need to transfer - File not found at Destination
2023/10/10 19:45:41 DEBUG : IMGP1542 - Copy.JPG: Need to transfer - File not found at Destination
2023/10/10 19:45:41 DEBUG : IMGP1542.JPG: Need to transfer - File not found at Destination
2023/10/10 19:45:41 DEBUG : IMGP1543 - Copy.JPG: Need to transfer - File not found at Destination
2023/10/10 19:45:41 DEBUG : IMGP1543.JPG: Need to transfer - File not found at Destination
2023/10/10 19:45:41 DEBUG : IMGP1544 - Copy.JPG: Need to transfer - File not found at Destination
2023/10/10 19:45:41 DEBUG : IMGP1544.JPG: Need to transfer - File not found at Destination
2023/10/10 19:45:41 DEBUG : IMGP1545 - Copy.JPG: Need to transfer - File not found at Destination
2023/10/10 19:45:41 DEBUG : IMGP1545.JPG: Need to transfer - File not found at Destination
2023/10/10 19:45:41 DEBUG : IMGP1546 - Copy.JPG: Need to transfer - File not found at Destination
2023/10/10 19:45:41 DEBUG : IMGP1546.JPG: Need to transfer - File not found at Destination
2023/10/10 19:45:41 DEBUG : Local file system at //?/N:/Pictures/2009/testfolder-2: Waiting for checks to finish
2023/10/10 19:45:41 DEBUG : Local file system at //?/N:/Pictures/2009/testfolder-2: Waiting for transfers to finish
2023/10/10 19:45:44 INFO  : IMGP1541 - Copy.JPG: Moved (server-side)
2023/10/10 19:45:45 INFO  : IMGP1540.JPG: Moved (server-side)
2023/10/10 19:45:46 INFO  : IMGP1540 - Copy.JPG: Moved (server-side)
2023/10/10 19:45:46 INFO  : IMGP1541.JPG: Moved (server-side)
2023/10/10 19:45:47 INFO  : IMGP1542 - Copy.JPG: Moved (server-side)
2023/10/10 19:45:49 INFO  : IMGP1542.JPG: Moved (server-side)
2023/10/10 19:45:50 INFO  : IMGP1543.JPG: Moved (server-side)
2023/10/10 19:45:50 INFO  : IMGP1543 - Copy.JPG: Moved (server-side)
2023/10/10 19:45:52 INFO  : IMGP1544.JPG: Moved (server-side)
2023/10/10 19:45:53 INFO  : IMGP1544 - Copy.JPG: Moved (server-side)
2023/10/10 19:45:54 INFO  : IMGP1545.JPG: Moved (server-side)
2023/10/10 19:45:54 INFO  : IMGP1545 - Copy.JPG: Moved (server-side)
2023/10/10 19:45:57 INFO  : IMGP1546 - Copy.JPG: Moved (server-side)
2023/10/10 19:45:57 INFO  : IMGP1546.JPG: Moved (server-side)
2023/10/10 19:45:57 INFO  : There was nothing to transfer
2023/10/10 19:45:57 INFO  :
Transferred:              0 B / 0 B, -, 0 B/s, ETA -
Checks:                14 / 14, 100%
Renamed:               14
Server Side Moves:     14 @ 28.846 MiB
Elapsed time:        16.5s

2023/10/10 19:45:57 DEBUG : 2 go routines active

So the performance seems the same whether I use the rclone mount command or Windows Explorer/exiftool...

Here the rclone debug logfile:

kill the rclone mount, do not use the mount, do not use N:\
test using a simple command, rclone move of a single file.

you state that your server is extremely slow for server-side move.
and rclone does not have control over that.

i suggested that you test with another copy tool and compare performance to rclone.
such as filezilla or windows native support for webdav.

oh right, makes sense!

rclone move "nextcloud:testfolder/IMAGE_023.jpg" "nextcloud:testfolder-2" -vv
2023/10/10 20:21:40 DEBUG : rclone: Version "v1.64.0" starting with parameters ["rclone" "move" "nextcloud:testfolder/IMAGE_023.jpg" "nextcloud:testfolder-2" "-vv"]
2023/10/10 20:21:40 DEBUG : Creating backend with remote "nextcloud:testfolder/IMAGE_023.jpg"
2023/10/10 20:21:40 DEBUG : Using config file from "C:\\rclone\\rclone.conf"
2023/10/10 20:21:40 DEBUG : found headers:
2023/10/10 20:21:40 NOTICE: Chunks temporary upload directory: https://nextcloud.DOMAIN.TLD/remote.php/dav/uploads/USER%20NAME/
2023/10/10 20:21:40 DEBUG : fs cache: adding new entry for parent of "nextcloud:testfolder/IMAGE_023.jpg", "nextcloud:testfolder"
2023/10/10 20:21:40 DEBUG : Creating backend with remote "nextcloud:testfolder-2"
2023/10/10 20:21:40 DEBUG : found headers:
2023/10/10 20:21:40 NOTICE: Chunks temporary upload directory: https://nextcloud.DOMAIN.TLD/remote.php/dav/uploads/USER%20NAME/
2023/10/10 20:21:41 DEBUG : IMAGE_023.jpg: Need to transfer - File not found at Destination
2023/10/10 20:21:41 DEBUG : IMAGE_023.jpg: Setting modtime after copy to 2009-05-04 16:44:42 +0000 GMT
2023/10/10 20:21:42 INFO  : IMAGE_023.jpg: Moved (server-side)
2023/10/10 20:21:42 INFO  :
Transferred:              0 B / 0 B, -, 0 B/s, ETA -
Checks:                 1 / 1, 100%
Renamed:                1
Server Side Moves:      1 @ 335.334 KiB
Elapsed time:         1.5s

2023/10/10 20:21:42 DEBUG : 3 go routines active

Alright, I think that's the next what I'll try!

EDIT:

Here the same output when moving all files from that folder - much faster!

  • 16.6s with rclone mount
  • 3.3s with rclone move (without mounting WebDAV first)
C:\rclone>rclone move "nextcloud:testfolder" "nextcloud:testfolder-2" --include "*.JPG" -vv
2023/10/10 20:25:50 DEBUG : rclone: Version "v1.64.0" starting with parameters ["rclone" "move" "nextcloud:testfolder" "nextcloud:testfolder-2" "--include" "*.JPG" "-vv"]
2023/10/10 20:25:50 DEBUG : Creating backend with remote "nextcloud:testfolder"
2023/10/10 20:25:50 DEBUG : Using config file from "C:\\rclone\\rclone.conf"
2023/10/10 20:25:50 DEBUG : found headers:
2023/10/10 20:25:50 NOTICE: Chunks temporary upload directory: https://nextcloud.DOMAIN.TLD/remote.php/dav/uploads/USER%20NAME/
2023/10/10 20:25:51 DEBUG : Creating backend with remote "nextcloud:testfolder-2"
2023/10/10 20:25:51 DEBUG : found headers:
2023/10/10 20:25:51 NOTICE: Chunks temporary upload directory: https://nextcloud.DOMAIN.TLD/remote.php/dav/uploads/USER%20NAME/
2023/10/10 20:25:51 DEBUG : IMAGE_023 - Copy.jpg: Excluded
2023/10/10 20:25:51 DEBUG : IMAGE_024 - Copy.jpg: Excluded
2023/10/10 20:25:51 DEBUG : IMAGE_024.jpg: Excluded
2023/10/10 20:25:51 DEBUG : IMAGE_025 - Copy.jpg: Excluded
2023/10/10 20:25:51 DEBUG : IMAGE_025.jpg: Excluded
2023/10/10 20:25:51 DEBUG : IMAGE_026 - Copy.jpg: Excluded
2023/10/10 20:25:51 DEBUG : IMAGE_026.jpg: Excluded
2023/10/10 20:25:51 DEBUG : IMAGE_027 - Copy.jpg: Excluded
2023/10/10 20:25:51 DEBUG : IMAGE_027.jpg: Excluded
2023/10/10 20:25:51 DEBUG : IMAGE_023.jpg: Excluded
2023/10/10 20:25:51 DEBUG : IMGP1540 - Copy.JPG: Need to transfer - File not found at Destination
2023/10/10 20:25:51 DEBUG : IMGP1540.JPG: Need to transfer - File not found at Destination
2023/10/10 20:25:51 DEBUG : IMGP1541 - Copy.JPG: Need to transfer - File not found at Destination
2023/10/10 20:25:51 DEBUG : IMGP1541.JPG: Need to transfer - File not found at Destination
2023/10/10 20:25:51 DEBUG : IMGP1542 - Copy.JPG: Need to transfer - File not found at Destination
2023/10/10 20:25:51 DEBUG : IMGP1542.JPG: Need to transfer - File not found at Destination
2023/10/10 20:25:51 DEBUG : IMGP1543 - Copy.JPG: Need to transfer - File not found at Destination
2023/10/10 20:25:51 DEBUG : IMGP1543.JPG: Need to transfer - File not found at Destination
2023/10/10 20:25:51 DEBUG : IMGP1544 - Copy.JPG: Need to transfer - File not found at Destination
2023/10/10 20:25:51 DEBUG : IMGP1544.JPG: Need to transfer - File not found at Destination
2023/10/10 20:25:51 DEBUG : IMGP1545 - Copy.JPG: Need to transfer - File not found at Destination
2023/10/10 20:25:51 DEBUG : IMGP1545.JPG: Need to transfer - File not found at Destination
2023/10/10 20:25:51 DEBUG : IMGP1546 - Copy.JPG: Need to transfer - File not found at Destination
2023/10/10 20:25:51 DEBUG : IMGP1546.JPG: Need to transfer - File not found at Destination
2023/10/10 20:25:51 DEBUG : webdav root 'testfolder-2': Waiting for checks to finish
2023/10/10 20:25:51 DEBUG : webdav root 'testfolder-2': Waiting for transfers to finish
2023/10/10 20:25:52 DEBUG : IMGP1541.JPG: Setting modtime after copy to 2009-06-13 10:32:46 +0000 GMT
2023/10/10 20:25:52 DEBUG : IMGP1541 - Copy.JPG: Setting modtime after copy to 2009-06-13 10:32:46 +0000 GMT
2023/10/10 20:25:52 DEBUG : IMGP1540.JPG: Setting modtime after copy to 2009-06-13 10:30:30 +0000 GMT
2023/10/10 20:25:52 DEBUG : IMGP1540 - Copy.JPG: Setting modtime after copy to 2009-06-13 10:30:30 +0000 GMT
2023/10/10 20:25:52 INFO  : IMGP1541.JPG: Moved (server-side)
2023/10/10 20:25:52 INFO  : IMGP1541 - Copy.JPG: Moved (server-side)
2023/10/10 20:25:52 INFO  : IMGP1540 - Copy.JPG: Moved (server-side)
2023/10/10 20:25:52 INFO  : IMGP1540.JPG: Moved (server-side)
2023/10/10 20:25:52 DEBUG : IMGP1542 - Copy.JPG: Setting modtime after copy to 2009-06-13 10:32:50 +0000 GMT
2023/10/10 20:25:52 DEBUG : IMGP1543 - Copy.JPG: Setting modtime after copy to 2009-06-13 10:32:58 +0000 GMT
2023/10/10 20:25:52 DEBUG : IMGP1542.JPG: Setting modtime after copy to 2009-06-13 10:32:50 +0000 GMT
2023/10/10 20:25:52 DEBUG : IMGP1543.JPG: Setting modtime after copy to 2009-06-13 10:32:58 +0000 GMT
2023/10/10 20:25:52 INFO  : IMGP1542 - Copy.JPG: Moved (server-side)
2023/10/10 20:25:53 INFO  : IMGP1543 - Copy.JPG: Moved (server-side)
2023/10/10 20:25:53 INFO  : IMGP1542.JPG: Moved (server-side)
2023/10/10 20:25:53 INFO  : IMGP1543.JPG: Moved (server-side)
2023/10/10 20:25:53 DEBUG : IMGP1544 - Copy.JPG: Setting modtime after copy to 2009-06-13 11:57:26 +0000 GMT
2023/10/10 20:25:53 DEBUG : IMGP1544.JPG: Setting modtime after copy to 2009-06-13 11:57:26 +0000 GMT
2023/10/10 20:25:53 DEBUG : IMGP1545 - Copy.JPG: Setting modtime after copy to 2009-06-13 11:57:32 +0000 GMT
2023/10/10 20:25:53 DEBUG : IMGP1545.JPG: Setting modtime after copy to 2009-06-13 11:57:32 +0000 GMT
2023/10/10 20:25:53 INFO  : IMGP1544 - Copy.JPG: Moved (server-side)
2023/10/10 20:25:53 INFO  : IMGP1544.JPG: Moved (server-side)
2023/10/10 20:25:53 INFO  : IMGP1545 - Copy.JPG: Moved (server-side)
2023/10/10 20:25:53 INFO  : IMGP1545.JPG: Moved (server-side)
2023/10/10 20:25:53 DEBUG : IMGP1546 - Copy.JPG: Setting modtime after copy to 2009-06-13 11:57:38 +0000 GMT
2023/10/10 20:25:54 DEBUG : IMGP1546.JPG: Setting modtime after copy to 2009-06-13 11:57:38 +0000 GMT
2023/10/10 20:25:54 INFO  : IMGP1546 - Copy.JPG: Moved (server-side)
2023/10/10 20:25:54 INFO  : IMGP1546.JPG: Moved (server-side)
2023/10/10 20:25:54 INFO  : There was nothing to transfer
2023/10/10 20:25:54 INFO  :
Transferred:              0 B / 0 B, -, 0 B/s, ETA -
Checks:                14 / 14, 100%
Renamed:               14
Server Side Moves:     14 @ 28.846 MiB
Elapsed time:         3.3s

2023/10/10 20:25:54 DEBUG : 3 go routines active

Update: In the meantime, I tried using Windows' native, built-in WebDAV mount support. The speed results are just as bad as using rclone mount when doing server-side file moves, for example.
FileZilla, btw, does not have WebDAV support.

So so far the only way to get fast results is to use rclone move - but I don't see any way to use these commands together with my exiftool scripts.
But still - this somehow proves that the bottleneck is not the server itself, but either something related to rclone mount or something related to Windows...

so if i understand,

when doing a server-side-move of a single file:
rclone mount is extermly slow as compared to rclone move?

Yes, that is exactly the case. I might also try Linux operating systems in the next few days. But for some applications I'm still tied to Windows and I would prefer to find a solution for that in the first place...

ok, so that would be a rclone issue.
from your logs, in both cases, the move is server-side, so this is a bit of a mystery.

good idea.

fwiw, i would try a test to confirm. find a larger file, that would take approx. five minutes to move using rclone mount
and move that file over the rclone mount and using rclone move. then compare the results.

and to take a much deeper look into what rclone is doing, use --dump=headers

The reason rclone move is faster is that it can do multiple things in parallel (see --transfers and --checkers), whereas the mount will be doing exactly as many things in parallel as the application using it is doing (so likely just 1).

This suggests a way of speeding things up though - do things in parallel in your app. Whether this is easy or not I have no idea, but it will speed things up here.

image

hmh ok, but I also tested rclone move on the WebDAV drive mounted with rclone mount with the same result - see Rclone Nextcloud WebDAV mount - server-side move extremly slow - #3 by JY5NQfmf
Shouldn't this at least be faster if there is no problem with rclone mount?

So there is no way to tell rclone to do these server-side moves in the background, similar to --vfs-cache-mode?
and I am currently trying to run two of my exiftool scripts in parallel on my WebDAV drive mounted with rclone mount. But it's not like these would double the speed overall. For example, if one script moved 0.8 items/s before, it's now 0.4 items/s for both scripts - resulting in the same slow speed overall as before.

And browsing the WebDAV connection with Windows Explorer while running these scripts is almost impossible now, because the load time is so slow...

@asdffdsa
That's FileZilla Pro, not FileZilla (the open-source version). And there isn't even a trial version available.

There is probably a lock on the directory preventing more than one rename at once in the same directory. That would be my guess.

Rclone could do that, but then it would need more smoke and mirrors to convince the application that the files were in the correct place when they weren't.

It would be worth using -vv --dump headers to work out exactly how many HTTP operations rclone is doing for each rename - there may be some scope for optimization there.

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