Chunked file upload with curl

Hi to all,

I want to upload files via curl (or phyton requests) in chunks of a given size.
I found some disucssions, that this is implemented via

    curl -X PUT server/path/to/chunk1 -d @chunk1
    curl -X PUT server/path/to/chunk2 -d @chunk2

and then call

curl -X MOVE  --header 'Destination:server/path/to/file' server/path/to/.file

However, I get an error, that .file does not exist. Can this be done in this way?

Thanks and best regards.

EDIT: Solved
I just found, that the destination of the chunks is not an arbitrary folder inside your owncloud, but must be a subfolder of a specific upload folder:

https://server/remote.php/dav/uploads/username/

There the “.file” exists and the move command succeeds.
Sorry for the bother, I keep this post maybe for future reference.

2 Likes