[lvs-users] Connection count mismatch between client and LVS

David Coulson david at davidcoulson.net
Wed Nov 28 18:01:34 GMT 2012


How long do these TCP connections live for? Perhaps they are sitting there with no packets for 15mins (or whatever the TCP timeout is on LVS in your configuration). Based on the timers of the 3 you were able to see, they stick around a while without any activity.

You could configure TCP keepalives on the server side so the connections have periodic traffic to update the LVS timers and avoid the LVS connections expiring before the connections are really closed on the server/client side.

On Nov 26, 2012, at 5:29 PM, Khosrow Ebrahimpour wrote:

> Hi list,
> 
> I am seeing some odd connection behaviour between LVS and clients. I regulary 
> see that the client->LVS connection count is higher from the client side than 
> when I look at it on the LVS.
> 
> 
> For example, on the client side here's what I see:
> 
> client:~# netstat -antp | grep 389
> tcp      197      0 10.10.5.247:32986     10.10.3.169:389       ESTABLISHED 
> 1567/nslcd      
> tcp        0      0 10.10.5.247:33343     10.10.3.169:389       ESTABLISHED 
> 1567/nslcd      
> tcp        0      0 10.10.5.247:33250     10.10.3.169:389       ESTABLISHED 
> 1567/nslcd      
> tcp        0      0 10.10.5.247:32993     10.10.3.169:389       ESTABLISHED 
> 1567/nslcd      
> tcp        0      0 10.10.5.247:60957     10.10.3.169:389       ESTABLISHED 
> 1567/nslcd 
> 
> 
> And at the same time on the lvs I see:
> 
> lb1:~# ipvsadm -Lnc | grep 10.10.5.247
> TCP 08:35  ESTABLISHED 10.10.5.247:33250 10.10.3.169:389  10.10.5.34:389
> TCP 08:35  ESTABLISHED 10.10.5.247:33343 10.10.3.169:389  10.10.5.34:389
> TCP 06:16  ESTABLISHED 10.10.5.247:32993 10.10.3.169:389  10.10.5.38:389
> 
> 
> I am trying to understand why the client has 5 established connections to LVS, 
> while the LVS only has 3 open to the client. Is this normal behaviour?
> 
> I should add that I see this regularly on many systems. 
> 
> * The clients are all running Ubuntu (10.04 or 12.04) with nslcd 0.7.2
> * The LVS is running Ubuntu 12.04, Kernel 3.2.0-24-virtual, ipvsadm 
> 1:1.25.clean-1ubuntu5
> 
> Thanks in advance,
> --
> Khosrow
> 
> _______________________________________________
> Please read the documentation before posting - it's available at:
> http://www.linuxvirtualserver.org/
> 
> LinuxVirtualServer.org mailing list - lvs-users at LinuxVirtualServer.org
> Send requests to lvs-users-request at LinuxVirtualServer.org
> or go to http://lists.graemef.net/mailman/listinfo/lvs-users





More information about the lvs-users mailing list