cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: Sporadic "Couldn't resolve host" error on windows with libcurl 7.30.0

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Sat, 20 Sep 2014 23:35:38 +0200 (CEST)

On Fri, 19 Sep 2014, arif khan wrote:

> To narrow down the problem I wrote a multi-threaded app which runs 100
> threads, in each thread if requests http page in a loop of range 1000. In
> total 100000 requests, I can see 6-10 requests fails with above error.

Sounds like it could potentially be running out of some resources? I think it
would help if you figured out exactly which function call that returns
failure, as I suspect it is actually the underlying getaddrinfo() that returns
failure and then it feels like the problem is in Windows and not in libcurl.

> Interestingly I do not see such error on linux 64 bit machine in the same
> network with locally compiled libcurl 7.30.0.

That's another indication that it might not be libcurl that considers this an
error, as the code running on linux is almost identical to the code running on
windows.

But which resolver backend did you use in the linux case? It'd be a good test
if you made sure the linux case also used the threaded resolver backend.

-- 
  / daniel.haxx.se
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette:  http://curl.haxx.se/mail/etiquette.html
Received on 2014-09-20