From: Roberto Nibali <ratz@drugphish.ch>
To: Marcelo Tosatti <marcelo.tosatti@cyclades.com>
Cc: Willy Tarreau <willy@w.ods.org>, linux-kernel@vger.kernel.org, ja@ssi.bg
Subject: [PATCH 2.4] [IPVS] fix missing refcnt put with expire_nodest_conn
Date: Fri, 04 Nov 2005 10:41:57 +0100 [thread overview]
Message-ID: <436B2CE5.5070400@drugphish.ch> (raw)
In-Reply-To: <20051101063402.GA3311@logos.cnet>
[-- Attachment #1: Type: text/plain, Size: 1087 bytes --]
Hello Marcelo,
It seems we forgot to fix one place where ip_vs_conn_expire_now
is used. Callers should hold write lock or cp->refcnt (and not forget
it). This results in hanging template entries when expire_nodest_conn is
kicking in and trying to remove all connection entries for a specific
destination.
Julian Anastasov created a patch to fix this and asked me to forward it
for inclusion, after test and verification, which have happened the last
24 hours.
This problem also exists in 2.6.x kernels, patch will be sent to netdev.
Signed-off-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Roberto Nibali <ratz@drugphish.ch>
Please apply this before releasing 2.4.32.
Best regards,
Roberto Nibali, ratz
--
-------------------------------------------------------------
addr://Kasinostrasse 30, CH-5001 Aarau tel://++41 62 823 9355
http://www.terreactive.com fax://++41 62 823 9356
-------------------------------------------------------------
terreActive AG Wir sichern Ihren Erfolg
-------------------------------------------------------------
[-- Attachment #2: linux-2.4.32-rc2-ip_vs_conn_expire_now-fix_refcnt-dec-1.diff --]
[-- Type: text/plain, Size: 626 bytes --]
diff -ur v2.4.32-rc2/linux/net/ipv4/ipvs/ip_vs_core.c linux/net/ipv4/ipvs/ip_vs_core.c
--- v2.4.32-rc2/linux/net/ipv4/ipvs/ip_vs_core.c 2005-11-03 01:20:02.000000000 +0200
+++ linux/net/ipv4/ipvs/ip_vs_core.c 2005-11-03 01:22:36.347895544 +0200
@@ -1111,11 +1111,10 @@
if (sysctl_ip_vs_expire_nodest_conn) {
/* try to expire the connection immediately */
ip_vs_conn_expire_now(cp);
- } else {
- /* don't restart its timer, and silently
- drop the packet. */
- __ip_vs_conn_put(cp);
}
+ /* don't restart its timer, and silently
+ drop the packet. */
+ __ip_vs_conn_put(cp);
return NF_DROP;
}
next prev parent reply other threads:[~2005-11-04 9:42 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-10-31 17:57 Linux 2.4.32-rc2 Marcelo Tosatti
2005-11-01 4:06 ` Grant Coady
2005-11-01 7:49 ` Willy Tarreau
2005-11-01 6:34 ` Marcelo Tosatti
2005-11-01 20:00 ` Roberto Nibali
2005-11-02 0:28 ` Willy Tarreau
2005-11-02 11:02 ` Roberto Nibali
2005-11-02 12:29 ` Willy Tarreau
2005-11-03 10:19 ` Roberto Nibali
2005-11-04 0:09 ` Willy Tarreau
2005-11-04 8:50 ` Roberto Nibali
2005-11-03 5:43 ` Willy Tarreau
2005-11-03 6:41 ` Willy TARREAU
2005-11-04 9:41 ` Roberto Nibali [this message]
2005-11-01 10:56 ` Willy Tarreau
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=436B2CE5.5070400@drugphish.ch \
--to=ratz@drugphish.ch \
--cc=ja@ssi.bg \
--cc=linux-kernel@vger.kernel.org \
--cc=marcelo.tosatti@cyclades.com \
--cc=willy@w.ods.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox