retry.d 1.1 KB

12345678910111213141516171819202122232425
  1. c: Copyright (C) Daniel Stenberg, <daniel@haxx.se>, et al.
  2. SPDX-License-Identifier: curl
  3. Long: retry
  4. Arg: <num>
  5. Added: 7.12.3
  6. Help: Retry request if transient problems occur
  7. Category: curl
  8. Example: --retry 7 $URL
  9. See-also: retry-max-time
  10. Multi: single
  11. ---
  12. If a transient error is returned when curl tries to perform a transfer, it
  13. will retry this number of times before giving up. Setting the number to 0
  14. makes curl do no retries (which is the default). Transient error means either:
  15. a timeout, an FTP 4xx response code or an HTTP 408, 429, 500, 502, 503 or 504
  16. response code.
  17. When curl is about to retry a transfer, it will first wait one second and then
  18. for all forthcoming retries it will double the waiting time until it reaches
  19. 10 minutes which then will be the delay between the rest of the retries. By
  20. using --retry-delay you disable this exponential backoff algorithm. See also
  21. --retry-max-time to limit the total time allowed for retries.
  22. Since curl 7.66.0, curl will comply with the Retry-After: response header if
  23. one was present to know when to issue the next retry.