curl / Mailing Lists / curl-users / Single Mail
Buy commercial curl support from WolfSSL. We help you work out your issues, debug your libcurl applications, use the API, port to new platforms, add new features and more. With a team lead by the curl founder himself.

Re: Overcoming curl Error 28

From: Daniel Stenberg via curl-users <>
Date: Sat, 28 Mar 2020 17:31:56 +0100 (CET)

On Sat, 28 Mar 2020, Michael Newman via curl-users wrote:

> It runs once every four minutes and uploads small webcam JPEGs to a web
> host. Most of the time it works just fine. But, about once an hour or so the
> transfer dies with error 28. Based on the verbose output, it looks like one
> chunk gets transferred immediately and then that's it.

This is not something curl can do anying about. It will upload the data as
fast as it can. In your case, something makes the transfer stall.

> It also appears that error 28 is not a "transient error" (I still don't know
> what that means), so the upload is not retried.

The man page explains what it is. It means the server needs to return an error
code within the "transient" error range. An error that by definition might not
happen again if you try again later. An error 28 is not that.

> Is there some way to get curl to retry under these conditions

There isn't. Jay has a PR going that *could* perhaps do it in the future but
I'm not sure exactly where that's going. It seems we don't quite agree on what
it should do or behave...

> do I just have to put something in my shell script?

For now that's the only thing you can do.

  / | Commercial curl support up to 24x7 is available!
                   | Private help, bug fixes, support, ports, new features
Received on 2020-03-28