From 1b71d153bea096f9cdbf41ca22b0eb5d3da215cf Mon Sep 17 00:00:00 2001 From: Li Xi Date: Fri, 22 Mar 2024 20:30:57 +0800 Subject: [PATCH] LU-17666: configure lnet before add net in sanity-sec:31 If "options lnet config_on_load=1" is not configured in modprobe.d, the lnet will not be configured when trying to add a network. The command will hit problem. /usr/sbin/lnetctl net add --if eth1 --net tcp999 add: - net: errno: -22 descr: "cannot add network: Invalid argument" Test-Parameters: trivial testlist=sanity-sec env=ONLY=31 Lustre-change: https://review.whamcloud.com/54543 Lustre-commit: e163883f76dac45a516b7d89671513d31063b7d6 Change-Id: If65b7cb372d4f04a10ea066d62f3ae43029fcf65 Signed-off-by: Li Xi Reviewed-by: Sebastien Buisson Reviewed-by: James Simmons Reviewed-on: https://review.whamcloud.com/c/ex/lustre-release/+/54654 Reviewed-by: Andreas Dilger Tested-by: jenkins Tested-by: Maloo --- lustre/tests/sanity-sec.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lustre/tests/sanity-sec.sh b/lustre/tests/sanity-sec.sh index 505e95e..e12e6ef 100755 --- a/lustre/tests/sanity-sec.sh +++ b/lustre/tests/sanity-sec.sh @@ -2566,7 +2566,8 @@ test_31() { do_rpc_nodes $(comma_list $(all_nodes)) load_modules || error "unable to load modules on $(all_nodes)" for node in $(all_nodes); do - do_node $node "$LNETCTL lnet configure" + do_node $node "$LNETCTL lnet configure" || + error "unable to configure lnet on node $node" infname=inf_$(echo $node | cut -d'.' -f1 | sed s+-+_+g) do_node $node "$LNETCTL net add --if ${!infname} --net $net2" || error "unable to configure NID on $net2 for node $node" -- 1.8.3.1