Using obsutil for Resumable Data Transfer
obsutil supports resumable data transfer (upload, download, and copy) for large files by using the multipart algorithms for upload, download, and copy. You can set the threshold size for starting a multipart upload, download, or copy task based on your actual requirements to resume the upload, download, or copy task if the task fails or is interrupted. You can specify the threshold size for starting a multipart task in either of the following ways:
Method 1
Set defaultBigfileThreshold in the configuration file. For details, see Parameter Description.
Method 2
Set threshold, a command-level parameter, when you run commands for object uploads, object downloads, object copy, synchronous uploads of incremental objects, synchronous downloads of incremental objects, and synchronous copy of incremental objects.
Example: obsutil cp d:\temp\test.txt obs://bucket-test/key -threshold=52428800
In this command:
- obsutil cp d:\temp\test.txt obs://bucket-test/key uploads file test.txt in the temp directory under D drive to bucket bucket-test and renames the file key.
- -threshold=52428800 starts a multipart upload when the threshold 50 MB is reached.
obsutil cp d:\temp\test.txt obs://bucket-test/key -threshold=52428800 Parallel: 3 Jobs: 3 Threshold: 50.00MB PartSize: auto Exclude: Include: VerifyLength: false VerifyMd5: false CheckpointDir: xxxx [====================================================] 100.00% 1.68 MB/s 5s Upload successfully, 8.46MB, d:\temp\test.txt --> obs://bucket-test/key
![](https://support.huaweicloud.com/intl/en-us/ae-ad-1-utiltg-obs/public_sys-resources/note_3.0-en-us.png)
- Priority: Command level parameter threshold has higher priority than the defaultBigfileThreshold in the configuration file.
- The threshold size of a multipart task applies to single files or objects. When the size of a file or object is greater than the threshold value, the multipart algorithm is applied to the file or object.
- The multipart algorithm and resumable data transfer are forcibly bound together. That is, once the multipart algorithm is used, the resumable data transfer is enabled for the task.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot