[SRU][X, Z, A, B][PATCH 0/1] ipv6: Do not consider linkdown nexthops during multipath

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

[SRU][X, Z, A, B][PATCH 0/1] ipv6: Do not consider linkdown nexthops during multipath

Joseph Salisbury-3
BugLink: http://bugs.launchpad.net/bugs/1738219

== SRU Justification ==
When the 'ignore_routes_with_linkdown' sysctl is set, we should not
consider linkdown nexthops during route lookup.

While the code correctly verifies that the initially selected route
('match') has a carrier, it does not perform the same check in the
subsequent multipath selection, resulting in a potential packet loss.

In case the chosen route does not have a carrier and the sysctl is set,
choose the initially selected route.

This is a regression introduced by commit 35103d11173b in 4.3-rc1.  Commit
bbfcd7763 resolves this regression and is mainline as of 4.15-rc1.    

== Fix ==
commit bbfcd77631573ac4a9f57eb6169e04256a111bc1
Author: Ido Schimmel <[hidden email]>
Date:   Tue Nov 21 09:50:12 2017 +0200

    ipv6: Do not consider linkdown nexthops during multipath

== Regression Potential ==
This fix is specific to ipv6 and fixes a current regression.

== Test Case ==
A test kernel was built with this patch and tested by the original bug reporter.
The bug reporter states the test kernel resolved the bug.
Ido Schimmel (1):
  ipv6: Do not consider linkdown nexthops during multipath

 net/ipv6/route.c | 5 +++++
 1 file changed, 5 insertions(+)

--
2.7.4


--
kernel-team mailing list
[hidden email]
https://lists.ubuntu.com/mailman/listinfo/kernel-team
Reply | Threaded
Open this post in threaded view
|

[PATCH] ipv6: Do not consider linkdown nexthops during multipath

Joseph Salisbury-3
From: Ido Schimmel <[hidden email]>

BugLink: http://bugs.launchpad.net/bugs/1738219

When the 'ignore_routes_with_linkdown' sysctl is set, we should not
consider linkdown nexthops during route lookup.

While the code correctly verifies that the initially selected route
('match') has a carrier, it does not perform the same check in the
subsequent multipath selection, resulting in a potential packet loss.

In case the chosen route does not have a carrier and the sysctl is set,
choose the initially selected route.

Fixes: 35103d11173b ("net: ipv6 sysctl option to ignore routes when nexthop link is down")
Signed-off-by: Ido Schimmel <[hidden email]>
Acked-by: David Ahern <[hidden email]>
Acked-by: Andy Gospodarek <[hidden email]>
Signed-off-by: David S. Miller <[hidden email]>
(cherry picked from commit bbfcd77631573ac4a9f57eb6169e04256a111bc1)
Signed-off-by: Joseph Salisbury <[hidden email]>
---
 net/ipv6/route.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/net/ipv6/route.c b/net/ipv6/route.c
index 09f2644..6e09bd4 100644
--- a/net/ipv6/route.c
+++ b/net/ipv6/route.c
@@ -465,6 +465,11 @@ static struct rt6_info *rt6_multipath_select(struct rt6_info *match,
  &match->rt6i_siblings, rt6i_siblings) {
  route_choosen--;
  if (route_choosen == 0) {
+ struct inet6_dev *idev = sibling->rt6i_idev;
+
+ if (!netif_carrier_ok(sibling->dst.dev) &&
+    idev->cnf.ignore_routes_with_linkdown)
+ break;
  if (rt6_score_route(sibling, oif, strict) < 0)
  break;
  match = sibling;
--
2.7.4


--
kernel-team mailing list
[hidden email]
https://lists.ubuntu.com/mailman/listinfo/kernel-team
Reply | Threaded
Open this post in threaded view
|

ACK/APPLIED[B]: [SRU][X, Z, A, B][PATCH 0/1] ipv6: Do not consider linkdown nexthops during multipath

Seth Forshee
In reply to this post by Joseph Salisbury-3
On Fri, Dec 15, 2017 at 09:40:09AM -0500, Joseph Salisbury wrote:

> BugLink: http://bugs.launchpad.net/bugs/1738219
>
> == SRU Justification ==
> When the 'ignore_routes_with_linkdown' sysctl is set, we should not
> consider linkdown nexthops during route lookup.
>
> While the code correctly verifies that the initially selected route
> ('match') has a carrier, it does not perform the same check in the
> subsequent multipath selection, resulting in a potential packet loss.
>
> In case the chosen route does not have a carrier and the sysctl is set,
> choose the initially selected route.
>
> This is a regression introduced by commit 35103d11173b in 4.3-rc1.  Commit
> bbfcd7763 resolves this regression and is mainline as of 4.15-rc1.    
>
> == Fix ==
> commit bbfcd77631573ac4a9f57eb6169e04256a111bc1
> Author: Ido Schimmel <[hidden email]>
> Date:   Tue Nov 21 09:50:12 2017 +0200
>
>     ipv6: Do not consider linkdown nexthops during multipath
>
> == Regression Potential ==
> This fix is specific to ipv6 and fixes a current regression.
>
> == Test Case ==
> A test kernel was built with this patch and tested by the original bug reporter.
> The bug reporter states the test kernel resolved the bug.

Acked-by: Seth Forshee <[hidden email]>

Applied to bionic/master-next, thanks!

--
kernel-team mailing list
[hidden email]
https://lists.ubuntu.com/mailman/listinfo/kernel-team
Reply | Threaded
Open this post in threaded view
|

ACK[X,A]/NACK[Z]: [PATCH] ipv6: Do not consider linkdown nexthops during multipath

Stefan Bader-2
In reply to this post by Joseph Salisbury-3
On 15.12.2017 15:40, Joseph Salisbury wrote:

> From: Ido Schimmel <[hidden email]>
>
> BugLink: http://bugs.launchpad.net/bugs/1738219
>
> When the 'ignore_routes_with_linkdown' sysctl is set, we should not
> consider linkdown nexthops during route lookup.
>
> While the code correctly verifies that the initially selected route
> ('match') has a carrier, it does not perform the same check in the
> subsequent multipath selection, resulting in a potential packet loss.
>
> In case the chosen route does not have a carrier and the sysctl is set,
> choose the initially selected route.
>
> Fixes: 35103d11173b ("net: ipv6 sysctl option to ignore routes when nexthop link is down")
> Signed-off-by: Ido Schimmel <[hidden email]>
> Acked-by: David Ahern <[hidden email]>
> Acked-by: Andy Gospodarek <[hidden email]>
> Signed-off-by: David S. Miller <[hidden email]>
> (cherry picked from commit bbfcd77631573ac4a9f57eb6169e04256a111bc1)
> Signed-off-by: Joseph Salisbury <[hidden email]>
Acked-by: Stefan Bader <[hidden email]>

> ---
>  net/ipv6/route.c | 5 +++++
>  1 file changed, 5 insertions(+)
>
> diff --git a/net/ipv6/route.c b/net/ipv6/route.c
> index 09f2644..6e09bd4 100644
> --- a/net/ipv6/route.c
> +++ b/net/ipv6/route.c
> @@ -465,6 +465,11 @@ static struct rt6_info *rt6_multipath_select(struct rt6_info *match,
>   &match->rt6i_siblings, rt6i_siblings) {
>   route_choosen--;
>   if (route_choosen == 0) {
> + struct inet6_dev *idev = sibling->rt6i_idev;
> +
> + if (!netif_carrier_ok(sibling->dst.dev) &&
> +    idev->cnf.ignore_routes_with_linkdown)
> + break;
>   if (rt6_score_route(sibling, oif, strict) < 0)
>   break;
>   match = sibling;
>


--
kernel-team mailing list
[hidden email]
https://lists.ubuntu.com/mailman/listinfo/kernel-team

signature.asc (836 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

APPLIED[X,A]: [SRU][X, Z, A, B][PATCH 0/1] ipv6: Do not consider linkdown nexthops during multipath

Khalid Elmously
In reply to this post by Joseph Salisbury-3
Applied to X and A

On 2017-12-15 09:40:09 , Joseph Salisbury wrote:

> BugLink: http://bugs.launchpad.net/bugs/1738219
>
> == SRU Justification ==
> When the 'ignore_routes_with_linkdown' sysctl is set, we should not
> consider linkdown nexthops during route lookup.
>
> While the code correctly verifies that the initially selected route
> ('match') has a carrier, it does not perform the same check in the
> subsequent multipath selection, resulting in a potential packet loss.
>
> In case the chosen route does not have a carrier and the sysctl is set,
> choose the initially selected route.
>
> This is a regression introduced by commit 35103d11173b in 4.3-rc1.  Commit
> bbfcd7763 resolves this regression and is mainline as of 4.15-rc1.    
>
> == Fix ==
> commit bbfcd77631573ac4a9f57eb6169e04256a111bc1
> Author: Ido Schimmel <[hidden email]>
> Date:   Tue Nov 21 09:50:12 2017 +0200
>
>     ipv6: Do not consider linkdown nexthops during multipath
>
> == Regression Potential ==
> This fix is specific to ipv6 and fixes a current regression.
>
> == Test Case ==
> A test kernel was built with this patch and tested by the original bug reporter.
> The bug reporter states the test kernel resolved the bug.
> Ido Schimmel (1):
>   ipv6: Do not consider linkdown nexthops during multipath
>
>  net/ipv6/route.c | 5 +++++
>  1 file changed, 5 insertions(+)
>
> --
> 2.7.4
>
>
> --
> kernel-team mailing list
> [hidden email]
> https://lists.ubuntu.com/mailman/listinfo/kernel-team

--
kernel-team mailing list
[hidden email]
https://lists.ubuntu.com/mailman/listinfo/kernel-team