We forget to check forced_send when using nsna_ping link_watch. Ns is sent from all ports, which cause switch mac flapping. Some reply packets are delivered to disabled port and dropped directly.
Fix it by checking forced_send and only send ns on enabled port.
Reported-by: LiLiang liali@redhat.com Signed-off-by: Hangbin Liu liuhangbin@gmail.com --- teamd/teamd_lw_nsna_ping.c | 3 +++ 1 file changed, 3 insertions(+)
diff --git a/teamd/teamd_lw_nsna_ping.c b/teamd/teamd_lw_nsna_ping.c index 127d950..82371c4 100644 --- a/teamd/teamd_lw_nsna_ping.c +++ b/teamd/teamd_lw_nsna_ping.c @@ -203,6 +203,9 @@ static int lw_nsnap_send(struct lw_psr_port_priv *psr_ppriv) struct sockaddr_in6 sendto_addr; struct ns_packet nsp;
+ if (!(psr_ppriv->common.forced_send)) + return 0; + err = teamd_getsockname_hwaddr(psr_ppriv->sock, &ll_my, sizeof(nsp.hwaddr)); if (err)
Thu, Feb 21, 2019 at 10:37:46AM CET, liuhangbin@gmail.com wrote:
We forget to check forced_send when using nsna_ping link_watch. Ns is sent from all ports, which cause switch mac flapping. Some reply packets are delivered to disabled port and dropped directly.
Fix it by checking forced_send and only send ns on enabled port.
Reported-by: LiLiang liali@redhat.com Signed-off-by: Hangbin Liu liuhangbin@gmail.com
applied. Thanks!
libteam@lists.fedorahosted.org