}
# Filter (multiline) vconn debug messages from ovs-vswitchd.log.
-# Use with ofctl_strip()
+# Use with vconn_windows_sub() and ofctl_strip()
print_vconn_debug () { awk -F\| < ovs-vswitchd.log '
BEGIN { prt=0 }
/\|vconn\|DBG\|/ { sub(/[ \t]*$/, ""); print $3 "|" $4 "|" $5; prt=1; next }
'
}
+vconn_windows_sub() {
+ sed '
+s/tcp:127.0.0.1:[0-9][0-9]*:/unix:/
+s/No error/Success/
+'
+}
+
# parse_listening_port [SERVER]
#
# Parses the TCP or SSL port on which a server is listening from the
AT_CHECK([ovs-vsctl -- add-br br0 -- set bridge br0 datapath-type=dummy other-config:datapath-id=fedcba9876543210 other-config:hwaddr=aa:55:aa:55:00:00 protocols=[[OpenFlow10,OpenFlow11,OpenFlow12,OpenFlow13,OpenFlow14,OpenFlow15]] fail-mode=secure -- $1 m4_if([$2], [], [], [| ${PERL} $srcdir/uuidfilt.pl])], [0], [$2])
])
+# check_logs scans through all *.log files (except '*.log' and testsuite.log)
+# and reports all WARN, ERR, EMER log entries. User can add custom sed filters
+# in $1.
m4_divert_push([PREPARE_TESTS])
check_logs () {
+ local logs
+ for log in *.log; do
+ case ${log} in # (
+ '*.log'|testsuite.log) ;; # (
+ *) logs="${logs} ${log}" ;;
+ esac
+ done
+
sed -n "$1
/timeval.*Unreasonably long [[0-9]]*ms poll interval/d
/timeval.*faults: [[0-9]]* minor, [[0-9]]* major/d
/ovs_rcu.*blocked [[0-9]]* ms waiting for .* to quiesce/d
/|WARN|/p
/|ERR|/p
-/|EMER|/p" ovs-vswitchd.log ovsdb-server.log
+/|EMER|/p" ${logs}
}
m4_divert_pop([PREPARE_TESTS])
Tunnel push-pop off
])])
- [AT_CHECK([ovs-appctl ofproto/tnl-push-pop off])])
-
# ADD_OF_PORTS(BRIDGE, OF_PORT[, OF_PORT...])
#
# Creates a dummy interface with an OpenFlow port number of OF_PORT and