Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 25 Aug 2005 21:01:32 +0100
From:      RW <list-freebsd-2004@morbius.sent.com>
To:        freebsd-questions@freebsd.org
Subject:   stunnel not stopped by rc.d script
Message-ID:  <200508252101.33284.list-freebsd-2004@morbius.sent.com>

next in thread | raw e-mail | index | archive | help
If I try to stop stunnel  with it's rc.d script I get

    # /usr/local/etc/rc.d/stunnel.sh stop
    stunnel not running? (check /var/run/stunnel.pid).

but the PID file is actually in /var/tmp. 

I don't have anything in my stunnel.conf or rc.conf  file that's relevant.

This is /usr/local/etc/rc.d/stunnel.sh:

---------------------------------------------------------------------------
# PROVIDE: stunnel
# REQUIRE: NETWORKING SERVERS
# BEFORE: DAEMON
# KEYWORD: shutdown

#
# Add some of the following variables to /etc/rc.conf to configure stunnel:
# stunnel_enable (bool):        Set to "NO" by default.
#                               Set it to "YES" to enable stunnel.
# stunnel_config (str):         Default "/usr/local/etc/stunnel/stunnel.conf"
#                               Set it to the full path to the config file
#                               that stunnel will use during the automated
#                               start-up.
# stunnel_pidfile (str):        Default "/usr/local/var/stunnel/stunnel.pid"
#                               Set it to the value of 'pidfile' in
#                               the stunnel.conf file.
#

. /etc/rc.subr

name="stunnel"
rcvar=`set_rcvar`
stunnel_config="/usr/local/etc/stunnel/${name}.conf"
stunnel_pidfile="/var/run/${name}.pid"
command="/usr/local/sbin/stunnel"

[ -z "$stunnel_enable" ]                && stunnel_enable="NO"

load_rc_config $name

command_args=${stunnel_config}
pidfile=${stunnel_pidfile}

required_files="${stunnel_config}"

run_rc_command "$1"
---------------------------------------------------------------------------



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200508252101.33284.list-freebsd-2004>