- if [ -e /var/run/openvswitch/ovs-vswitchd.pid ]; then
- ovs-appctl -t ovs-vswitchd vlog/reopen
- fi
- if [ -e /var/run/openvswitch/ovsdb-server.pid ]; then
- ovs-appctl -t ovsdb-server vlog/reopen
+ if [ -d /var/run/openvswitch ]; then
+ for pidfile in `cd /var/run/openvswitch && echo *.pid`; do
+ ovs-appctl -t "${pidfile%%.pid}" vlog/reopen
+ done