forwarding_enable
vrf_prepare
h1_create
h2_create
sw1_flat_create gre $ol1 $ul1
sw2_flat_create gre $ol2 $ul2
ip stats set dev g1a l3_stats on
ip stats set dev g2a l3_stats on
}
cleanup()
{
pre_cleanup
ip stats set dev g1a l3_stats off
ip stats set dev g2a l3_stats off
send_packets_ipv4()
{ # Send 21 packets instead of 20, because the first one might trap and go # through the SW datapath, which might not bump the HW counter.
$MZ $h1 -c 21 -d 20msec -p 100 \
-a own -b $ol1mac -A 192.0.2.1 -B 192.0.2.18 \
-q -t udp sp=54321,dp=12345
}
test_stats()
{
local dev=$1; shift
local dir=$1; shift
local a
local b
RET=0
a=$(hw_stats_get l3_stats $dev $dir packets)
send_packets_ipv4
b=$(busywait "$TC_HIT_TIMEOUT" until_counter_is ">= $a + 20" \
hw_stats_get l3_stats $dev $dir packets)
check_err $? "Traffic not reflected in the counter: $a -> $b"
log_test "Test $dir packets: $prot"
}
test_stats_tx()
{
test_stats g1a tx
}
test_stats_rx()
{
test_stats g2a rx
}
trap cleanup EXIT
setup_prepare
setup_wait
tests_run
exit $EXIT_STATUS
Messung V0.5
¤ Dauer der Verarbeitung: 0.11 Sekunden
(vorverarbeitet)
¤
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.