LVS
lvs-users
Google
 
Web LinuxVirtualServer.org

Re: [PATCH] Invalidate expired persistance templates

To: Horms <horms@xxxxxxxxxxxx>
Subject: Re: [PATCH] Invalidate expired persistance templates
Cc: "LinuxVirtualServer.org user..." <lvs-users@xxxxxxxxxxxxxxxxxxxxxx>
From: Julian Anastasov <ja@xxxxxx>
Date: Mon, 7 Nov 2005 23:44:25 +0200 (EET)
        Hello,

On Mon, 7 Nov 2005, Horms wrote:

> That seems like a good work around to me, though perhaps HZ would
> be better than 10*HZ.
>
> Here is a patch to formalise it slightly. This is for 2.6, i'll send a
> version for 2.5 shortly.

        This patch is ok, it should be the only patch we need for
2.6. Similar patch that preserves current timeout for normal conns
should be 2nd for 2.4, the 1st one being the patch that syncs 
ip_vs_conn_expire_now to 2.6 state. You can send these 3 patches
to DaveM after short testing.

> diff --git a/net/ipv4/ipvs/ip_vs_conn.c b/net/ipv4/ipvs/ip_vs_conn.c
> index f828fa2..f531d59 100644
> --- a/net/ipv4/ipvs/ip_vs_conn.c
> +++ b/net/ipv4/ipvs/ip_vs_conn.c
> @@ -525,7 +525,8 @@ static void ip_vs_conn_expire(unsigned l
>  {
>       struct ip_vs_conn *cp = (struct ip_vs_conn *)data;
>
> -     cp->timeout = 60*HZ;
> +     if (cp->flags & IP_VS_CONN_F_TEMPLATE)
> +             cp->timeout = 10*HZ;
>
>       /*
>        *      hey, I'm using it

Regards

--
Julian Anastasov <ja@xxxxxx>

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