Several of the LNet sanity test create a fake network device and
setup an IP. Only a IPv4 was setup so also setup a IPv6 address
to increase the testing coverage for large NID support.
Test-Parameters: trivial testlist=sanity-lnet
Change-Id: If29adf74f1fe6449ad3f48663c2872a39bf4664c
Signed-off-by: James Simmons <jsimmons@infradead.org>
Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/53599
Reviewed-by: Chris Horn <chris.horn@hpe.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
Reviewed-by: Frank Sehr <fsehr@whamcloud.com>
Reviewed-by: Serguei Smirnov <ssmirnov@whamcloud.com>
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
FAKE_IF="test1pg"
FAKE_IP="10.1.2.3"
FAKE_IP_ALIAS="10.1.2.31"
+FAKE_IPV6="2001:0db8:0:f101::1"
do_ns() {
echo "ip netns exec $TESTNS $*"
ip netns exec $TESTNS "$@"
ip link set 'test1pl' up
if [[ -n $netns ]]; then
do_ns ip addr add "${FAKE_IP}/31" dev $FAKE_IF
+ do_ns ip -6 addr add "${FAKE_IPV6}/64" dev $FAKE_IF
do_ns ip link set $FAKE_IF up
else
ip addr add "${FAKE_IP}/31" dev $FAKE_IF
+ ip -6 addr add "${FAKE_IPV6}/64" dev $FAKE_IF
ip link set $FAKE_IF up
fi
}