On Tue, Nov 10, 2015 at 11:44 AM, Krishna Kumar (Engineering)
<krishna...@flipkart.com> wrote:
> Dear all,
>
> I am comparing 1.6.1 with 1.5.12. Following are the relevant snippets from the
> configuration file:
>
> global
>            maxconn 100
> defaults
>            option http-keep-alive
>            option clitcpka
>            option srvtcpka
> frontend private-frontend
>            maxconn 100
>            mode http
>            bind IP1:80
>            default_backend private-backend
> backend private-backend
>             http-reuse always (only in the 1.6.1 configuration)
>             server IP2 IP2:80 maxconn 10
>
> Client runs a single command to retrieve file of 128 bytes:
>           ab -k -n 20 -c 12 http://<IP1>/128
>
> Tcpdump shows that 12 connections were established to the frontend, 10
> connections
> were then made to the server, and after the 10 were serviced once (GET), two 
> new
> connections were opened to the server and serviced once (GET), finally
> 8 requests
> were done on the first set of server connections. Finally all 12
> connections were
> closed together. There is no difference in #packets between 1.5.12 and
> 1.6.1 or the
> sequence of packets.
>
> How do I actually re-use idle connections? Do I need to run ab's in
> parallel with
> some delay, etc, to see old connections being reused? I also ran separately 
> the
> following script to get file of 4K, to introduce parallel connections
> with delay's, etc:
>
> for i in {1..20}
> do
>         ab -k -n 100 -c 50 http://10.34.73.174/4K &
>         sleep 0.4
> done
> wait
>
> But the total# packets for 1.5.12 and 1.6.1 were similar (no drops in tcpdump,
> no Connection drop in client, with 24.6K packets for 1.5.12 and 24.8K packets
> for 1.6.1). Could someone please let me know what I should change in the
> configuration or the client to see the effect of http-reuse?
>
> Thanks,
> - Krishna Kumar
>


Hi Krishna,

Actually, your timeouts are also very important as well.
I would also enable "option prefer-last-server", furthermore if you
have many servers in the farm.

Now, to test the reuse, simply try opening a session using telnet, and
fake a keepalive session.
then do a few wget and confirm all the traffic uses the session
previously established.

Baptiste

Reply via email to