[[ ]] syntax is not supported, at least, by dash that Debian, Ubuntu and other
linux distributions may use instead of bash.
This commit uses, instead, a POSIX way that is compatible with any POSIX
shell (bash, dash, busybox sh, etc).
CC: Martin Xu <martinxu9.ovs@gmail.com>
Fixes: 9763d17fbd05 ("utilities: check datapath exists before conntrack flush")
Signed-off-by: Timothy Redaelli <tredaelli@redhat.com>
Signed-off-by: Ben Pfaff <blp@ovn.org>
Acked-by: Aaron Conole <aconole@redhat.com>
stop_ovsdb
start_ovsdb || return 1
- if [[ $(ovs-dpctl show) ]]; then
+ if [ -n "$(ovs-dpctl show)" ]; then
action "Flush old conntrack entries" ovs-appctl dpctl/flush-conntrack
fi
stop_forwarding