* [net-next 1/2] tipc: update cluster capabilities if node deleted
@ 2019-11-06 6:26 Hoang Le
2019-11-06 6:26 ` [net-next 2/2] tipc: reduce sensitive to retransmit failures Hoang Le
` (2 more replies)
0 siblings, 3 replies; 6+ messages in thread
From: Hoang Le @ 2019-11-06 6:26 UTC (permalink / raw)
To: jon.maloy, maloy, netdev, tipc-discussion
There are two improvements when re-calculate cluster capabilities:
- When deleting a specific down node, need to re-calculate.
- In tipc_node_cleanup(), do not need to re-calculate if node
is still existing in cluster.
Acked-by: Jon Maloy <jon.maloy@ericsson.com>
Signed-off-by: Hoang Le <hoang.h.le@dektech.com.au>
---
net/tipc/node.c | 12 +++++++++++-
1 file changed, 11 insertions(+), 1 deletion(-)
diff --git a/net/tipc/node.c b/net/tipc/node.c
index 742c04756d72..a20fabd09e7e 100644
--- a/net/tipc/node.c
+++ b/net/tipc/node.c
@@ -665,6 +665,11 @@ static bool tipc_node_cleanup(struct tipc_node *peer)
}
tipc_node_write_unlock(peer);
+ if (!deleted) {
+ spin_unlock_bh(&tn->node_list_lock);
+ return deleted;
+ }
+
/* Calculate cluster capabilities */
tn->capabilities = TIPC_NODE_CAPABILITIES;
list_for_each_entry_rcu(temp_node, &tn->node_list, list) {
@@ -2041,7 +2046,7 @@ int tipc_nl_peer_rm(struct sk_buff *skb, struct genl_info *info)
struct net *net = sock_net(skb->sk);
struct tipc_net *tn = net_generic(net, tipc_net_id);
struct nlattr *attrs[TIPC_NLA_NET_MAX + 1];
- struct tipc_node *peer;
+ struct tipc_node *peer, *temp_node;
u32 addr;
int err;
@@ -2082,6 +2087,11 @@ int tipc_nl_peer_rm(struct sk_buff *skb, struct genl_info *info)
tipc_node_write_unlock(peer);
tipc_node_delete(peer);
+ /* Calculate cluster capabilities */
+ tn->capabilities = TIPC_NODE_CAPABILITIES;
+ list_for_each_entry_rcu(temp_node, &tn->node_list, list) {
+ tn->capabilities &= temp_node->capabilities;
+ }
err = 0;
err_out:
tipc_node_put(peer);
--
2.20.1
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [net-next 2/2] tipc: reduce sensitive to retransmit failures
2019-11-06 6:26 [net-next 1/2] tipc: update cluster capabilities if node deleted Hoang Le
@ 2019-11-06 6:26 ` Hoang Le
2019-11-06 21:07 ` Jon Maloy
2019-11-07 1:38 ` David Miller
2019-11-06 19:16 ` [net-next 1/2] tipc: update cluster capabilities if node deleted Jon Maloy
2019-11-07 1:37 ` David Miller
2 siblings, 2 replies; 6+ messages in thread
From: Hoang Le @ 2019-11-06 6:26 UTC (permalink / raw)
To: jon.maloy, maloy, netdev, tipc-discussion
With huge cluster (e.g >200nodes), the amount of that flow:
gap -> retransmit packet -> acked will take time in case of STATE_MSG
dropped/delayed because a lot of traffic. This lead to 1.5 sec tolerance
value criteria made link easy failure around 2nd, 3rd of failed
retransmission attempts.
Instead of re-introduced criteria of 99 faled retransmissions to fix the
issue, we increase failure detection timer to ten times tolerance value.
Fixes: 77cf8edbc0e7 ("tipc: simplify stale link failure criteria")
Acked-by: Jon Maloy <jon.maloy@ericsson.com>
Signed-off-by: Hoang Le <hoang.h.le@dektech.com.au>
---
net/tipc/link.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/net/tipc/link.c b/net/tipc/link.c
index 038861bad72b..2aed7a958a8c 100644
--- a/net/tipc/link.c
+++ b/net/tipc/link.c
@@ -1087,7 +1087,7 @@ static bool link_retransmit_failure(struct tipc_link *l, struct tipc_link *r,
return false;
if (!time_after(jiffies, TIPC_SKB_CB(skb)->retr_stamp +
- msecs_to_jiffies(r->tolerance)))
+ msecs_to_jiffies(r->tolerance * 10)))
return false;
hdr = buf_msg(skb);
--
2.20.1
^ permalink raw reply related [flat|nested] 6+ messages in thread
* RE: [net-next 1/2] tipc: update cluster capabilities if node deleted
2019-11-06 6:26 [net-next 1/2] tipc: update cluster capabilities if node deleted Hoang Le
2019-11-06 6:26 ` [net-next 2/2] tipc: reduce sensitive to retransmit failures Hoang Le
@ 2019-11-06 19:16 ` Jon Maloy
2019-11-07 1:37 ` David Miller
2 siblings, 0 replies; 6+ messages in thread
From: Jon Maloy @ 2019-11-06 19:16 UTC (permalink / raw)
To: Hoang Huu Le, maloy, netdev, tipc-discussion
Acked-by: Jon
> -----Original Message-----
> From: Hoang Le <hoang.h.le@dektech.com.au>
> Sent: 6-Nov-19 01:26
> To: Jon Maloy <jon.maloy@ericsson.com>; maloy@donjonn.com; netdev@vger.kernel.org; tipc-
> discussion@lists.sourceforge.net
> Subject: [net-next 1/2] tipc: update cluster capabilities if node deleted
>
> There are two improvements when re-calculate cluster capabilities:
>
> - When deleting a specific down node, need to re-calculate.
> - In tipc_node_cleanup(), do not need to re-calculate if node
> is still existing in cluster.
>
> Acked-by: Jon Maloy <jon.maloy@ericsson.com>
> Signed-off-by: Hoang Le <hoang.h.le@dektech.com.au>
> ---
> net/tipc/node.c | 12 +++++++++++-
> 1 file changed, 11 insertions(+), 1 deletion(-)
>
> diff --git a/net/tipc/node.c b/net/tipc/node.c
> index 742c04756d72..a20fabd09e7e 100644
> --- a/net/tipc/node.c
> +++ b/net/tipc/node.c
> @@ -665,6 +665,11 @@ static bool tipc_node_cleanup(struct tipc_node *peer)
> }
> tipc_node_write_unlock(peer);
>
> + if (!deleted) {
> + spin_unlock_bh(&tn->node_list_lock);
> + return deleted;
> + }
> +
> /* Calculate cluster capabilities */
> tn->capabilities = TIPC_NODE_CAPABILITIES;
> list_for_each_entry_rcu(temp_node, &tn->node_list, list) {
> @@ -2041,7 +2046,7 @@ int tipc_nl_peer_rm(struct sk_buff *skb, struct genl_info *info)
> struct net *net = sock_net(skb->sk);
> struct tipc_net *tn = net_generic(net, tipc_net_id);
> struct nlattr *attrs[TIPC_NLA_NET_MAX + 1];
> - struct tipc_node *peer;
> + struct tipc_node *peer, *temp_node;
> u32 addr;
> int err;
>
> @@ -2082,6 +2087,11 @@ int tipc_nl_peer_rm(struct sk_buff *skb, struct genl_info *info)
> tipc_node_write_unlock(peer);
> tipc_node_delete(peer);
>
> + /* Calculate cluster capabilities */
> + tn->capabilities = TIPC_NODE_CAPABILITIES;
> + list_for_each_entry_rcu(temp_node, &tn->node_list, list) {
> + tn->capabilities &= temp_node->capabilities;
> + }
> err = 0;
> err_out:
> tipc_node_put(peer);
> --
> 2.20.1
^ permalink raw reply [flat|nested] 6+ messages in thread
* RE: [net-next 2/2] tipc: reduce sensitive to retransmit failures
2019-11-06 6:26 ` [net-next 2/2] tipc: reduce sensitive to retransmit failures Hoang Le
@ 2019-11-06 21:07 ` Jon Maloy
2019-11-07 1:38 ` David Miller
1 sibling, 0 replies; 6+ messages in thread
From: Jon Maloy @ 2019-11-06 21:07 UTC (permalink / raw)
To: Hoang Huu Le, maloy, netdev, tipc-discussion
Acked-by: Jon
> -----Original Message-----
> From: Hoang Le <hoang.h.le@dektech.com.au>
> Sent: 6-Nov-19 01:26
> To: Jon Maloy <jon.maloy@ericsson.com>; maloy@donjonn.com; netdev@vger.kernel.org; tipc-
> discussion@lists.sourceforge.net
> Subject: [net-next 2/2] tipc: reduce sensitive to retransmit failures
>
> With huge cluster (e.g >200nodes), the amount of that flow:
> gap -> retransmit packet -> acked will take time in case of STATE_MSG
> dropped/delayed because a lot of traffic. This lead to 1.5 sec tolerance
> value criteria made link easy failure around 2nd, 3rd of failed
> retransmission attempts.
>
> Instead of re-introduced criteria of 99 faled retransmissions to fix the
> issue, we increase failure detection timer to ten times tolerance value.
>
> Fixes: 77cf8edbc0e7 ("tipc: simplify stale link failure criteria")
> Acked-by: Jon Maloy <jon.maloy@ericsson.com>
> Signed-off-by: Hoang Le <hoang.h.le@dektech.com.au>
> ---
> net/tipc/link.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/net/tipc/link.c b/net/tipc/link.c
> index 038861bad72b..2aed7a958a8c 100644
> --- a/net/tipc/link.c
> +++ b/net/tipc/link.c
> @@ -1087,7 +1087,7 @@ static bool link_retransmit_failure(struct tipc_link *l, struct tipc_link *r,
> return false;
>
> if (!time_after(jiffies, TIPC_SKB_CB(skb)->retr_stamp +
> - msecs_to_jiffies(r->tolerance)))
> + msecs_to_jiffies(r->tolerance * 10)))
> return false;
>
> hdr = buf_msg(skb);
> --
> 2.20.1
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [net-next 1/2] tipc: update cluster capabilities if node deleted
2019-11-06 6:26 [net-next 1/2] tipc: update cluster capabilities if node deleted Hoang Le
2019-11-06 6:26 ` [net-next 2/2] tipc: reduce sensitive to retransmit failures Hoang Le
2019-11-06 19:16 ` [net-next 1/2] tipc: update cluster capabilities if node deleted Jon Maloy
@ 2019-11-07 1:37 ` David Miller
2 siblings, 0 replies; 6+ messages in thread
From: David Miller @ 2019-11-07 1:37 UTC (permalink / raw)
To: hoang.h.le; +Cc: jon.maloy, maloy, netdev, tipc-discussion
From: Hoang Le <hoang.h.le@dektech.com.au>
Date: Wed, 6 Nov 2019 13:26:09 +0700
> There are two improvements when re-calculate cluster capabilities:
>
> - When deleting a specific down node, need to re-calculate.
> - In tipc_node_cleanup(), do not need to re-calculate if node
> is still existing in cluster.
>
> Acked-by: Jon Maloy <jon.maloy@ericsson.com>
> Signed-off-by: Hoang Le <hoang.h.le@dektech.com.au>
Applied.
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [net-next 2/2] tipc: reduce sensitive to retransmit failures
2019-11-06 6:26 ` [net-next 2/2] tipc: reduce sensitive to retransmit failures Hoang Le
2019-11-06 21:07 ` Jon Maloy
@ 2019-11-07 1:38 ` David Miller
1 sibling, 0 replies; 6+ messages in thread
From: David Miller @ 2019-11-07 1:38 UTC (permalink / raw)
To: hoang.h.le; +Cc: jon.maloy, maloy, netdev, tipc-discussion
From: Hoang Le <hoang.h.le@dektech.com.au>
Date: Wed, 6 Nov 2019 13:26:10 +0700
> With huge cluster (e.g >200nodes), the amount of that flow:
> gap -> retransmit packet -> acked will take time in case of STATE_MSG
> dropped/delayed because a lot of traffic. This lead to 1.5 sec tolerance
> value criteria made link easy failure around 2nd, 3rd of failed
> retransmission attempts.
>
> Instead of re-introduced criteria of 99 faled retransmissions to fix the
> issue, we increase failure detection timer to ten times tolerance value.
>
> Fixes: 77cf8edbc0e7 ("tipc: simplify stale link failure criteria")
> Acked-by: Jon Maloy <jon.maloy@ericsson.com>
> Signed-off-by: Hoang Le <hoang.h.le@dektech.com.au>
Applied.
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2019-11-07 1:38 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-11-06 6:26 [net-next 1/2] tipc: update cluster capabilities if node deleted Hoang Le
2019-11-06 6:26 ` [net-next 2/2] tipc: reduce sensitive to retransmit failures Hoang Le
2019-11-06 21:07 ` Jon Maloy
2019-11-07 1:38 ` David Miller
2019-11-06 19:16 ` [net-next 1/2] tipc: update cluster capabilities if node deleted Jon Maloy
2019-11-07 1:37 ` David Miller
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.