# Copyright (c) 2007, 2009 Javier Fernandez-Sanguino <jfs@debian.org>
#
# This is free software; you may redistribute it and/or modify
# Copyright (c) 2007, 2009 Javier Fernandez-Sanguino <jfs@debian.org>
#
# This is free software; you may redistribute it and/or modify
NAME=ovs-controller # Introduce the short server's name here
DESC=ovs-controller # Introduce a short description here
LOGDIR=/var/log/openvswitch # Log directory to use
NAME=ovs-controller # Introduce the short server's name here
DESC=ovs-controller # Introduce a short description here
LOGDIR=/var/log/openvswitch # Log directory to use
test -x $DAEMON || exit 0
. /lib/lsb/init-functions
# Default options, these can be overriden by the information
test -x $DAEMON || exit 0
. /lib/lsb/init-functions
# Default options, these can be overriden by the information
DAEMON_OPTS="" # Additional options given to the server
DODTIME=10 # Time to wait for the server to die, in seconds
DAEMON_OPTS="" # Additional options given to the server
DODTIME=10 # Time to wait for the server to die, in seconds
- stop_server
- # Wait some sensible amount, some server need this
- [ -n "$DIETIME" ] && sleep $DIETIME
+ if running; then
+ stop_server
+ # Wait some sensible amount, some server need this.
+ [ -n "$DODTIME" ] && sleep $DODTIME
+ fi