Home
last modified time | relevance | path

Searched refs:ns1 (Results 1 – 25 of 41) sorted by relevance

12

/tools/testing/selftests/net/mptcp/
Dpm_netlink.sh29 ns1="ns1-$rndh"
36 ip netns del $ns1
49 ip netns add $ns1 || exit $ksft_skip
50 ip -net $ns1 link set lo up
51 ip netns exec $ns1 sysctl -q net.mptcp.enabled=1
75 check "ip netns exec $ns1 ./pm_nl_ctl dump" "" "defaults addr list"
77 default_limits="$(ip netns exec $ns1 ./pm_nl_ctl limits)"
79 check "ip netns exec $ns1 ./pm_nl_ctl limits" "accept 0
83 ip netns exec $ns1 ./pm_nl_ctl add 10.0.1.1
84 ip netns exec $ns1 ./pm_nl_ctl add 10.0.1.2 flags subflow dev lo
[all …]
Dmptcp_join.sh50 ns1="ns1-$rndh"
53 for netns in "$ns1" "$ns2";do
71 ip link add ns1eth$i netns "$ns1" type veth peer name ns2eth$i netns "$ns2"
72 ip -net "$ns1" addr add 10.0.$i.1/24 dev ns1eth$i
73 ip -net "$ns1" addr add dead:beef:$i::1/64 dev ns1eth$i nodad
74 ip -net "$ns1" link set ns1eth$i up
89 tc -n $ns1 qdisc add dev ns1eth$i root netem rate 20mbit delay 1
98 for netns in "$ns1" "$ns2"; do
121 for netns in "$ns1" "$ns2";do
138 ip netns exec $ns1 sysctl -q net.mptcp.add_addr_timeout=1
[all …]
Dsimult_flows.sh7 ns1="ns1-$rndh"
32 for netns in "$ns1" "$ns2" "$ns3";do
64 for i in "$ns1" "$ns2" "$ns3";do
71 ip link add ns1eth1 netns "$ns1" type veth peer name ns2eth1 netns "$ns2"
72 ip link add ns1eth2 netns "$ns1" type veth peer name ns2eth2 netns "$ns2"
75 ip -net "$ns1" addr add 10.0.1.1/24 dev ns1eth1
76 ip -net "$ns1" addr add dead:beef:1::1/64 dev ns1eth1 nodad
77 ip -net "$ns1" link set ns1eth1 up mtu 1500
78 ip -net "$ns1" route add default via 10.0.1.2
79 ip -net "$ns1" route add default via dead:beef:1::2
[all …]
Dmptcp_sockopt.sh40 ns1="ns1-$rndh"
43 for netns in "$ns1" "$ns2";do
52 ip link add ns1eth$i netns "$ns1" type veth peer name ns2eth$i netns "$ns2"
53 ip -net "$ns1" addr add 10.0.$i.1/24 dev ns1eth$i
54 ip -net "$ns1" addr add dead:beef:$i::1/64 dev ns1eth$i nodad
55 ip -net "$ns1" link set ns1eth$i up
64 ip netns exec $ns1 ./pm_nl_ctl add 10.0.$i.1 flags signal
65 ip netns exec $ns1 ./pm_nl_ctl add dead:beef:$i::1 flags signal
71 ip netns exec $ns1 ./pm_nl_ctl limits 8 8
74 add_mark_rules $ns1 1
[all …]
Dmptcp_connect.sh123 ns1="ns1-$rndh"
137 for netns in "$ns1" "$ns2" "$ns3" "$ns4";do
158 for i in "$ns1" "$ns2" "$ns3" "$ns4";do
168 ip link add ns1eth2 netns "$ns1" type veth peer name ns2eth1 netns "$ns2"
172 ip -net "$ns1" addr add 10.0.1.1/24 dev ns1eth2
173 ip -net "$ns1" addr add dead:beef:1::1/64 dev ns1eth2 nodad
175 ip -net "$ns1" link set ns1eth2 up
176 ip -net "$ns1" route add default via 10.0.1.2
177 ip -net "$ns1" route add default via dead:beef:1::2
210 for i in "$ns1" "$ns2" "$ns3" "$ns4";do
[all …]
/tools/testing/selftests/netfilter/
Dnft_conntrack_helper.sh12 ns1="ns1-$sfx"
18 ip netns del ${ns1}
48 ip netns add ${ns1}
51 ip link add veth0 netns ${ns1} type veth peer name veth0 netns ${ns2} > /dev/null 2>&1
57 ip -net ${ns1} link set lo up
58 ip -net ${ns1} link set veth0 up
63 ip -net ${ns1} addr add 10.0.1.1/24 dev veth0
64 ip -net ${ns1} addr add dead:1::1/64 dev veth0
120 sleep 1 | ip netns exec ${ns1} nc -w 2 10.0.1.2 $port > /dev/null &
123 check_for_helper "$ns1" "ip $msg" $port
[all …]
Dnft_fib.sh10 ns1="ns1-$sfx"
19 ip netns del ${ns1}
53 ip netns add ${ns1}
116 load_ruleset ${ns1}
119 ip link add veth0 netns ${nsrouter} type veth peer name eth0 netns ${ns1} > /dev/null 2>&1
135 ip -net ${ns1} link set lo up
136 ip -net ${ns1} link set eth0 up
141 ip -net ${ns1} addr add 10.0.1.99/24 dev eth0
142 ip -net ${ns1} addr add dead:1::99/64 dev eth0
143 ip -net ${ns1} route add default via 10.0.1.1
[all …]
Dipvs.sh70 ip netns add ns1
73 ip link add veth01 netns ns0 type veth peer name veth10 netns ns1
75 ip link add veth12 netns ns1 type veth peer name veth21 netns ns2
85 ip netns exec ns1 ip link set lo up
86 ip netns exec ns1 ip link set veth10 up
87 ip netns exec ns1 ip addr add ${gip_v4}/24 dev veth10
88 ip netns exec ns1 ip link set veth12 up
89 ip netns exec ns1 ip addr add ${dip_v4}/24 dev veth12
141 ip netns exec ns1 sysctl -qw net.ipv4.ip_forward=1
142 ip netns exec ns1 ipvsadm -A -t ${vip_v4}:${port} -s rr
[all …]
Dnf_nat_edemux.sh12 ns1="ns1-$sfx"
17 ip netns del $ns1
39 ip netns add "$ns1"
41 echo "SKIP: Could not create net namespace $ns1"
51 ip link set netns $ns1 dev veth1
54 ip netns exec $ns1 ip link set up dev lo
55 ip netns exec $ns1 ip link set up dev veth1
56 ip netns exec $ns1 ip addr add 192.168.1.1/24 dev veth1
63 ip netns exec $ns1 iperf3 -s > /dev/null 2>&1 &
Dnft_nat.sh13 ns1="ns1-$sfx"
41 ip netns add "$ns1"
43 echo "SKIP: Could not create net namespace $ns1"
53 ip link add veth0 netns "$ns0" type veth peer name eth0 netns "$ns1" > /dev/null 2>&1
207 cnt=$(ip netns exec "$ns0" nft list counter inet filter ns1${dir} | grep -q "$expect")
209 bad_counter "$ns0" ns1$dir "$expect" "test_local_dnat6 1"
226 cnt=$(ip netns exec "$ns1" nft list counter inet filter ns0${dir} | grep -q "$expect")
228 bad_counter "$ns1" ns0$dir "$expect" "test_local_dnat6 3"
243 test $lret -eq 0 && echo "PASS: ipv6 ping to $ns1 was $family NATted to $ns2"
287 cnt=$(ip netns exec "$ns0" nft list counter inet filter ns1${dir} | grep -q "$expect")
[all …]
Dconntrack_tcp_unreplied.sh13 ns1="ns1-$sfx"
29 ip netns pids $ns1 | xargs kill 2>/dev/null
32 ip netns del $ns1
58 ip netns add $ns1 || exit 1
65 ip -net $ns1 link add name veth1 type veth peer name veth2
66 ip -net $ns1 link set netns $ns2 dev veth2
68 ip -net $ns1 link set up dev lo
70 ip -net $ns1 link set up dev veth1
79 ip netns exec $ns1 iptables -A INPUT -m state --state established,related -j ACCEPT
81 ip -net $ns1 addr add 10.11.11.1/24 dev veth1
[all …]
Dnft_flowtable.sh18 ns1="ns1-$sfx"
46 ip netns add $ns1
51 ip netns del $ns1
66 ip link add veth0 netns $nsr1 type veth peer name eth0 netns $ns1
116 ip -net $ns1 link set eth0 mtu $omtu
137 for ns in $ns1 $ns2;do
149 ip -net $ns1 addr add 10.0.1.99/24 dev eth0
151 ip -net $ns1 route add default via 10.0.1.1
153 ip -net $ns1 addr add dead:1::99/64 dev eth0
155 ip -net $ns1 route add default via dead:1::1
[all …]
Dnft_queue.sh12 ns1="ns1-$sfx"
19 ip netns del ${ns1}
51 ip netns add ${ns1}
54 ip link add veth0 netns ${nsrouter} type veth peer name eth0 netns ${ns1} > /dev/null 2>&1
70 ip -net ${ns1} link set lo up
71 ip -net ${ns1} link set eth0 up
76 ip -net ${ns1} addr add 10.0.1.99/24 dev eth0
77 ip -net ${ns1} addr add dead:1::99/64 dev eth0
78 ip -net ${ns1} route add default via 10.0.1.1
79 ip -net ${ns1} route add default via dead:1::1
[all …]
Dbridge_brouter.sh27 ip netns add ns1
30 ip link add veth0 netns ns0 type veth peer name eth0 netns ns1
72 ip netns exec ns1 ping -q -c 1 10.0.0.12 > /dev/null 2>&1
87 ip netns exec ns1 ping -q -c 1 10.0.0.12 > /dev/null
97 ip netns exec ns1 ping -q -c 1 10.0.0.12 > /dev/null
106 ip netns exec ns1 ping -q -c 1 10.0.0.12 > /dev/null 2>&1
126 ip netns exec ns1 ping -c 1 -q 10.0.0.12 > /dev/null
Dconntrack_vrf.sh40 ns1="ns1-$sfx"
45 ip netns pids $ns1 | xargs kill 2>/dev/null
47 ip netns del $ns0 $ns1
67 ip netns add "$ns1"
75 ip link add veth0 netns "$ns0" type veth peer name veth0 netns "$ns1" > /dev/null 2>&1
92 ip -net $ns1 li set veth0 up
95 ip -net $ns1 addr add $IP1/$PFXL dev veth0
97 ip netns exec $ns1 iperf3 -s > /dev/null 2>&1&
129 ip netns exec $ns1 ping -W 1 -c 1 -I veth0 $IP0 > /dev/null
/tools/testing/selftests/bpf/
Dtest_xdp_vlan.sh56 ip netns del ns1 2> /dev/null
126 ip netns del ns1 2> /dev/null
144 ip netns add ns1
154 ip link set veth1 netns ns1
162 ip netns exec ns1 ethtool -K veth1 rxvlan off
167 ip netns exec ns1 ethtool -K veth1 txvlan off
173 ip netns exec ns1 ip addr add ${IPADDR1}/24 dev veth1
174 ip netns exec ns1 ip link set veth1 up
185 ip netns exec ns1 ip link set lo up
202 ip netns exec ns1 ip link set $DEVNS1 $XDP_MODE object $FILE section $XDP_PROG
[all …]
Dtest_xdp_meta.sh13 ip netns del ns1 2> /dev/null
24 ip netns add ns1
31 ip link set veth1 netns ns1
34 ip netns exec ns1 ip addr add 10.1.1.11/24 dev veth1
37 ip netns exec ns1 tc qdisc add dev veth1 clsact
40 ip netns exec ns1 tc filter add dev veth1 ingress bpf da obj test_xdp_meta.o sec t
43 ip netns exec ns1 ip link set dev veth1 xdp obj test_xdp_meta.o sec x
46 ip netns exec ns1 ip link set dev veth1 up
49 ip netns exec ns1 ping -c 1 10.1.1.22
Dtest_xdp_redirect.sh20 ip netns add ns1
23 ip link add veth1 index 111 type veth peer name veth11 netns ns1
28 ip -n ns1 link set dev veth11 up
31 ip -n ns1 addr add 10.1.1.11/24 dev veth11
39 ip netns del ns1 2> /dev/null
55 ip -n ns1 link set veth11 $xdpmode obj xdp_dummy.o sec xdp &> /dev/null
60 if ip netns exec ns1 ping -c 1 10.1.1.22 &> /dev/null &&
Dtest_tc_tunnel.sh10 readonly ns1="${ns_prefix}1"
28 ip netns add "${ns1}"
31 ip link add dev veth1 mtu 1500 netns "${ns1}" type veth \
34 ip netns exec "${ns1}" ethtool -K veth1 tso off
36 ip -netns "${ns1}" link set veth1 up
39 ip -netns "${ns1}" -4 addr add "${ns1_v4}/24" dev veth1
41 ip -netns "${ns1}" -6 addr add "${ns1_v6}/64" dev veth1 nodad
45 ip -netns "${ns1}" -4 route flush table main
46 ip -netns "${ns1}" -6 route flush table main
47 ip -netns "${ns1}" -4 route add "${ns2_v4}" mtu 1450 dev veth1
[all …]
Dtest_xdp_redirect_multi.sh130 ip netns exec ${NS[1]} tcpdump -i veth0 -nn -l -e &> ${LOG_DIR}/ns1-1_${mode}.log &
131 ip netns exec ${NS[2]} tcpdump -i veth0 -nn -l -e &> ${LOG_DIR}/ns1-2_${mode}.log &
132 ip netns exec ${NS[3]} tcpdump -i veth0 -nn -l -e &> ${LOG_DIR}/ns1-3_${mode}.log &
144 [ $(grep -cF "who-has 192.0.2.254" ${LOG_DIR}/ns1-1_${mode}.log) -eq 4 ] && \
147 [ $(grep -cF "who-has 192.0.2.254" ${LOG_DIR}/ns1-2_${mode}.log) -eq 2 ] && \
150 [ $(grep -cF "who-has 192.0.2.254" ${LOG_DIR}/ns1-3_${mode}.log) -eq 2 ] && \
155 [ $(grep -c "ICMP echo request" ${LOG_DIR}/ns1-1_${mode}.log) -eq 4 ] && \
158 [ $(grep -c "ICMP echo request" ${LOG_DIR}/ns1-2_${mode}.log) -eq 4 ] && \
161 [ $(grep -c "ICMP echo request" ${LOG_DIR}/ns1-3_${mode}.log) -eq 4 ] && \
166 [ $(grep -c "ICMP6, echo request" ${LOG_DIR}/ns1-1_${mode}.log) -eq 4 ] && \
[all …]
Dtest_xdp_veth.sh32 ip netns del ns1 2> /dev/null
80 ip netns add ns1
84 ip link add veth1 index 111 type veth peer name veth11 netns ns1
92 ip -n ns1 addr add 10.1.1.11/24 dev veth11
95 ip -n ns1 link set dev veth11 up
110 ip -n ns1 link set dev veth11 xdp obj xdp_dummy.o sec xdp
116 ip netns exec ns1 ping -c 1 -W 1 10.1.1.33
Dtest_lwt_seg6local.sh44 ip netns del ns1 2> /dev/null
55 ip netns add ns1
70 ip link set veth1 netns ns1
81 ip netns exec ns1 ip link set dev veth1 up
94 ip netns exec ns1 ip -6 addr add fb00::12/16 dev veth1 scope link
95 ip netns exec ns1 ip -6 route add fb00::21 dev veth1 scope link
111 ip netns exec ns1 ip -6 addr add fb00::1/16 dev lo
112 ip netns exec ns1 ip -6 route add fb00::6 dev veth1 via fb00::21
130 ip netns exec ns1 sysctl net.ipv6.conf.all.forwarding=1 > /dev/null
141 ip netns exec ns1 bash -c "echo 'foobar' | nc -w0 -6 -u -p 2121 -s fb00::1 fb00::6 7330"
Dtest_tcp_check_syncookie.sh31 ip netns exec ns1 "$@"
36 ip netns add ns1
50 ip netns del ns1 2>/dev/null || :
/tools/testing/selftests/net/
Dgre_gso.sh53 ip netns add ns1
54 ip netns set ns1 auto
59 ip link set veth1 netns ns1
73 ip netns del ns1
148 a2=$(get_linklocal veth0 ns1)
/tools/testing/selftests/net/forwarding/
Dvxlan_asymmetric.sh390 ip netns add ns1
391 ip link set dev v2 netns ns1
392 in_ns ns1 ns_init
397 ip netns exec ns1 ip link set dev v2 netns 1
398 ip netns del ns1
423 local h1_ns_mac=$(in_ns ns1 mac_get w2)
424 local h2_ns_mac=$(in_ns ns1 mac_get w4)
429 in_ns ns1 macs_populate $h1_mac $h2_mac 10.1.1.101 10.1.2.101 10.0.0.1
493 ip neigh replace 10.1.1.102 lladdr $(in_ns ns1 mac_get w2) nud noarp \
495 ip neigh replace 10.1.2.102 lladdr $(in_ns ns1 mac_get w4) nud noarp \
[all …]

12