Download a .zip larger than 20 GB from OneDrive

Viewed 30

I am trying to download a 157gb .zip file from OneDrive (I have tried both curl and wget) to a machine on which I am ssh connected. I usually run screen, launch the download and then detach and disconnect. I have noticed that each time the download ends without error with an output of exactly 20GB, and this seems to be a limitation of OneDrive. In fact, as you can read in this discussion:

https://answers.microsoft.com/en-us/msoffice/forum/all/onedrive-web-version-cannot-download-files-larger/2d88fc5f-beb9-49e2-9411-d30636e6e88b

Is there any way around this problem?

1 Answers

As first thing check if wget do indeed see file of size 157GB under given URL, by doing

wget --spider URLTOFILE

you would get basic information about file withoud download it, filesize will be described as Length:, then check if it does support Partial gimmick as follows

wget --server-response --spider URLTOFILE

and then check if output contain Accept-Ranges: bytes, if yes then it might be possible to exploit Partial gimmick to get whole file, start following command

wget -c -O file.zip URLTOFILE

and then after it do get first 20GB then run it again and observe if it does download further part of your file.

Related