- Newest
- Most votes
- Most comments
Hi,
Have a look at https://bobcares.com/blog/curl-18-transfer-closed-with-outstanding-read-data-remaining/ for solutions to fix curl error 18.
Best
Didier
Elaborating more on to Didiers Comment, I would like to explain here that the error states is related to content-length. Such cases arise when the server initially reports an expected transfer size, and then delivers data that doesn’t match the previously sent size. It means a Partial file i.e. only a part of the file was transferred.Some of the causes for this error are:
* The connection gets timed-out due to the keep-alives not sent.
* An incorrect Content-Length header was sent by the peer.
For connection timed-out to fix this issue, add the –keepalive-time.
The Keep-Alive general header allows the sender to hint about how the connection may be used to set a timeout and a maximum amount of requests.
Content-Length header is one of the ways to indicate the length of the message and it can be resolved by suppressing the ‘Expect: 100-continue’ header that cURL usually sends. You can refer the below documentations for more information on this:
[+] https://bobcares.com/blog/curl-18-transfer-closed-with-outstanding-read-data-remaining/ [+] https://stackoverflow.com/questions/1759956/curl-error-18-transfer-closed-with-outstanding-read-data-remaining
Relevant content
- asked 6 years ago
- asked a year ago
- AWS OFFICIALUpdated 2 years ago
- AWS OFFICIALUpdated 2 months ago
- AWS OFFICIALUpdated 9 months ago
- AWS OFFICIALUpdated a year ago