What do I do if the object whose size exceeds the upper limit fails to be uploaded when I call the PostObject operation?

Updated at:

Problem description

When you call the PostObject operation to upload a small object, the object can be uploaded. However, if the size of the object exceeds the upper limit, the object fails to be uploaded.

Causes

The content-length-range parameter is specified in the PostObject request to limit the size of the objects that you want to upload.

Solutions

Perform the following steps to check the code that is used to upload objects.

  1. Check whether the size limit is specified in the PostObject request. For more information, see PostObject.

    Note

    Example: ["content-length-range", 0, 104857600] indicates that the size of the object that you want to upload must be less than 100 MB.

    • After you modify the content-length-range parameter, retry the upload operation.

    • If you do not want to modify the content-length-range parameter, use ossutil to split a large object into multiple parts and upload the object. For more information, see Multipart upload.

  2. If the issue persists, see How to upload large files to OSS to troubleshoot the issue.

Applicable scope

  • OSS