Whamcloud - gitweb
LU-17006 lnet: set up routes for going across subnets 21/51921/4
authorSerguei Smirnov <ssmirnov@whamcloud.com>
Fri, 11 Aug 2023 00:58:11 +0000 (17:58 -0700)
committerOleg Drokin <green@whamcloud.com>
Thu, 31 Aug 2023 06:38:37 +0000 (06:38 +0000)
commit7f60b2b5580f67ca55e53a78dbaf7d50b5b7ab47
tree39354d762c9fd6407ad8c5a6aa4180bf52a54a35
parent8a9c503c002d08d0587894a748761e30c1b9a445
LU-17006 lnet: set up routes for going across subnets

Modify ksocklnd-config to set up route which features
default gateway for the subnet in case if default gateway
is defined, for example:
        ip route add default via <gw_for_eth0> dev eth0 table eth0
which results in a route similar to the following added to
the eth0 route table:
        default via <gw_for_eth0> dev eth0

If there's no gateway found for the eth0 subnet, keep the old
behaviour which results in the following added to eth0
route table:
        <eth0_subnet> dev eth0 proto kernel scope link src <eth0_ip>

This makes sure that MR traffic goes out the intended interface
as selected by LNet no matter whether going across subnets or not.

Test-Parameters: trivial testlist=sanity-lnet
Signed-off-by: Serguei Smirnov <ssmirnov@whamcloud.com>
Change-Id: I84a299c8b7eb4cdb4fc24408a1e42ad0283d9219
Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/51921
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Chris Horn <chris.horn@hpe.com>
Reviewed-by: Frank Sehr <fsehr@whamcloud.com>
Reviewed-by: Cyril Bordage <cbordage@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lustre/scripts/ksocklnd-config