LVS
lvs-users
Google
 
Web LinuxVirtualServer.org

Re: Unwanted persistance

To: lvs-users@xxxxxxxxxxxxxxxxxxxxxx
Subject: Re: Unwanted persistance
From: Joseph Mack <mack.joseph@xxxxxxx>
Date: Thu, 17 Oct 2002 11:40:19 -0400
Chris Williams wrote:
> 

> Although I've now got a working system I have encountered a problem
> whereby if I cut a real server down, ipvsadm takes the real server off
> of its list but traffic still gets directed to the 'dead' real server.

presumably you've read

http://www.linuxvirtualserver.org/Joseph.Mack/HOWTO/LVS-HOWTO-6.html#ss6.7

the proper way to bring down a realserver is to set the weight to 0

http://www.linuxvirtualserver.org/Joseph.Mack/HOWTO/LVS-HOWTO-5.html#ss5.1

and then wait till the clients have disconnected.

> LVS persistance is set to 0 so that's not the problem. After 2-5 minutes
> requests stop being sent to the dead server and everything is hunky-dory
> again.

no new connections should be made after you quiesce the realserver, but
you have to let the client complete their connection.

> So maybe it is something to do with TCP timeouts? I checked out
> /proc/sys/net/ipv4/tcp_keepalive_timeout but that was set to 7200 (2
> hours,) which is far longer then the problem I am encountering.

keepalive is for maintaining an idle connection. The 2 minute timeout
is the FIN_WAIT for an InActConn to clear.

> 
> 2 minutes is too long to be throwing away requests, how can I improve
> the speed so that when a real server drops out, no one (except me)
> notices?

you're not allowed to remove connected clients no matter how long they're
connected. It's a feature.

Joe

-- 
Joseph Mack PhD, Senior Systems Engineer, SAIC contractor 
to the National Environmental Supercomputer Center, 
mailto:mack.joseph@xxxxxxx ph# 919-541-0007, RTP, NC, USA


<Prev in Thread] Current Thread [Next in Thread>