Very slow upload on big files
chrkuznos1 opened this issue · 1 comments
chrkuznos1 commented
Hi, thanks for this tool, it is very useful, although I noticed that the upload procedure takes alot of time when the file is very big, for example 10G.
Is there any way to improve this?
virtualzone commented
Hi @chrkuznos1,
version 0.7 adds a parameter to control the upload range size. I've run several tests using a 15 MB file:
$ time build/onedrive-uploader_macos_amd64_v0.7.0 -c ./config.json -u 320 upload /tmp/random15.bin /
Uploading random15.bin... 100% |████████████████████| (15/15 MB, 255 kB/s)
build/onedrive-uploader_macos_amd64_v0.7.0 -c ./config.json -u 0.76s user 1.03s system 2% cpu 1:00.47 total
$ time build/onedrive-uploader_macos_amd64_v0.7.0 -c ./config.json -u 9600 upload /tmp/random15.bin /
Uploading random15.bin... 100% |████████████████████| (15/15 MB, 308 kB/s)
build/onedrive-uploader_macos_amd64_v0.7.0 -c ./config.json -u 0.72s user 1.00s system 3% cpu 50.537 total
$ time build/onedrive-uploader_macos_amd64_v0.7.0 -c ./config.json -u 32000 upload /tmp/random15.bin /
Uploading random15.bin... 100% |████████████████████| (15/15 MB, 308 kB/s)
build/onedrive-uploader_macos_amd64_v0.7.0 -c ./config.json -u 0.74s user 1.08s system 3% cpu 50.500 total
As you can see, choosing a higher range size than the default setting of 9,600 KB (320 * 30) didn't make much of difference in my test. However, you could try to change this parameter and check if your upload procedure gets faster.