cURL / Mailing Lists / curl-users / Single Mail

curl-users

Disabling keepalive not working?

From: Igor Sverkos <igor.sverkos_at_googlemail.com>
Date: Sat, 20 Apr 2013 01:25:47 +0200

Hi,

I am trying to deactivate keepalive but I am not sure if it is really
deactivated -- would say no:

# curl --verbose --no-keepalive --output /dev/null
http://curl.haxx.se/ds-curlicon.png --output /dev/null
http://curl.haxx.se/ds-libcurlicon.png
* Adding handle: conn: 0x1ffbaa0
* Adding handle: send: 0
* Adding handle: recv: 0
* Curl_addHandleToPipeline: length: 1
* - Conn 0 (0x1ffbaa0) send_pipe: 1, recv_pipe: 0
  % Total % Received % Xferd Average Speed Time Time Time
Current
                                 Dload Upload Total Spent Left
Speed
  0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:--
    0* About to connect() to curl.haxx.se port 80 (#0)
* Trying 2a00:1a28:1200:9::2...
* Failed to connect to 2a00:1a28:1200:9::2: Network is unreachable
* Trying 80.67.6.50...
* Connected to curl.haxx.se (80.67.6.50) port 80 (#0)
> GET /ds-curlicon.png HTTP/1.1
> User-Agent: curl/7.30.0
> Host: curl.haxx.se
> Accept: */*
>
< HTTP/1.1 200 OK
< Date: Fri, 19 Apr 2013 23:20:32 GMT
* Server Apache is not blacklisted
< Server: Apache
< Last-Modified: Thu, 26 Jun 2003 13:04:19 GMT
< ETag: "1aadba-c8c-3c100764c3ac0"
< Accept-Ranges: bytes
< Content-Length: 3212
< Content-Type: image/png
<
{ [data not shown]
100 3212 100 3212 0 0 51490 0 --:--:-- --:--:-- --:--:--
52655
* Connection #0 to host curl.haxx.se left intact
* Found bundle for host curl.haxx.se: 0x1ffc220
* Re-using existing connection! (#0) with host curl.haxx.se
* Connected to curl.haxx.se (80.67.6.50) port 80 (#0)
* Adding handle: conn: 0x1ffbaa0
* Adding handle: send: 0
* Adding handle: recv: 0
* Curl_addHandleToPipeline: length: 1
* - Conn 0 (0x1ffbaa0) send_pipe: 1, recv_pipe: 0
> GET /ds-libcurlicon.png HTTP/1.1
> User-Agent: curl/7.30.0
> Host: curl.haxx.se
> Accept: */*
>
< HTTP/1.1 200 OK
< Date: Fri, 19 Apr 2013 23:20:32 GMT
* Server Apache is not blacklisted
< Server: Apache
< Last-Modified: Thu, 26 Jun 2003 13:04:19 GMT
< ETag: "1aadbc-10c7-3c100764c3ac0"
< Accept-Ranges: bytes
< Content-Length: 4295
< Content-Type: image/png
<
{ [data not shown]
100 4295 100 4295 0 0 125k 0 --:--:-- --:--:-- --:--:--
 125k
* Connection #0 to host curl.haxx.se left intact

Comparing the output above with the output from the same command without
"--no-keepalive" (or comparing the trace output) doesn't show any
difference to me.

I am not expecting

> * Re-using existing connection! (#0) with host curl.haxx.se

and

> * Connection #0 to host curl.haxx.se left intact

Tested with

# curl --version
curl 7.30.0 (x86_64-pc-linux-gnu) libcurl/7.30.0 OpenSSL/1.0.1e
zlib/1.2.7 c-ares/1.9.1 libidn/1.26
Protocols: dict file ftp ftps gopher http https imap imaps pop3 pop3s
rtsp smtp smtps telnet tftp
Features: AsynchDNS IDN IPv6 Largefile NTLM NTLM_WB SSL libz TLS-SRP

-- 
Regards,
Igor
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-users
FAQ:        http://curl.haxx.se/docs/faq.html
Etiquette:  http://curl.haxx.se/mail/etiquette.html
Received on 2013-04-20