[LTP] [COMMITTED][PATCH 1/2] test_net.sh: flush IPsec config when initializing test interfaces
Alexey Kodanev
alexey.kodanev@oracle.com
Wed Feb 15 12:47:46 CET 2017
Signed-off-by: Alexey Kodanev <alexey.kodanev@oracle.com>
---
testcases/lib/test_net.sh | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/testcases/lib/test_net.sh b/testcases/lib/test_net.sh
index 37cc939..6135032 100644
--- a/testcases/lib/test_net.sh
+++ b/testcases/lib/test_net.sh
@@ -216,6 +216,8 @@ tst_init_iface()
tst_resm TINFO "initialize '$type' '$iface' interface"
if [ "$type" = "lhost" ]; then
+ ip xfrm policy flush || return $?
+ ip xfrm state flush || return $?
ip link set $iface down || return $?
ip route flush dev $iface || return $?
ip addr flush dev $iface || return $?
@@ -223,6 +225,8 @@ tst_init_iface()
return $?
fi
+ tst_rhost_run -c "ip xfrm policy flush" || return $?
+ tst_rhost_run -c "ip xfrm state flush" || return $?
tst_rhost_run -c "ip link set $iface down" || return $?
tst_rhost_run -c "ip route flush dev $iface" || return $?
tst_rhost_run -c "ip addr flush dev $iface" || return $?
--
1.7.1
More information about the ltp
mailing list