X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=rhel%2Fetc_init.d_openvswitch;h=af332c0b577967893600d9d6b202c02d145195e0;hb=aad12c5f8f6a15681c525d552bd76afd46a1c08b;hp=9f1506c38697469b96ec81d5d6313e96de287706;hpb=d422c1189901d34125cd2d46552391c333d1f647;p=sliver-openvswitch.git diff --git a/rhel/etc_init.d_openvswitch b/rhel/etc_init.d_openvswitch index 9f1506c38..af332c0b5 100755 --- a/rhel/etc_init.d_openvswitch +++ b/rhel/etc_init.d_openvswitch @@ -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. @@ -48,6 +48,7 @@ start () { if test X"$BRCOMPAT" = Xyes; then set "$@" --brcompat fi + set "$@" $OVS_CTL_OPTS "$@" $ovs_ctl --protocol=gre enable-protocol @@ -60,6 +61,15 @@ stop () { rm -f /var/lock/subsys/openvswitch } +restart () { + if [ "$1" = "--save-flows=yes" ]; then + start restart + else + stop + start + fi +} + ovs_ctl=/usr/share/openvswitch/scripts/ovs-ctl case $1 in start) @@ -69,8 +79,8 @@ case $1 in stop ;; restart) - stop - start + shift + restart "$@" ;; reload|force-reload) # Nothing to do.