python: Break unixctl implementation into registry, client, and server.
[sliver-openvswitch.git] / xenserver / etc_init.d_openvswitch
index 29f2cf6..b2248b7 100755 (executable)
@@ -5,7 +5,7 @@
 # chkconfig: 2345 09 91
 # description: Manage Open vSwitch kernel modules and user-space daemons
 
-# Copyright (C) 2009, 2010, 2011 Nicira Networks, Inc.
+# Copyright (C) 2009, 2010, 2011 Nicira, Inc.
 #
 # Licensed under the Apache License, Version 2.0 (the "License");
 # you may not use this file except in compliance with the License.
@@ -120,10 +120,9 @@ case $1 in
         ;;
     reload|force-reload)
         # The main OVS daemons keep up-to-date, but ovs-xapi-sync needs help.
-        pidfile=/var/run/openvswitch/ovs-xapi-sync.pid
-        if test -e "$pidfile"; then
-            pid=`cat "$pidfile"`
-            action "Configuring Open vSwitch external IDs" kill -HUP $pid
+        if daemon_is_running ovs-xapi-sync; then
+            action "Configuring Open vSwitch external IDs" \
+                ovs-appctl -t ovs-xapi-sync flush-cache
         fi
         ;;
     status)