From owner-freebsd-questions@FreeBSD.ORG Tue Oct 9 01:07:33 2007 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 274DD16A468 for ; Tue, 9 Oct 2007 01:07:33 +0000 (UTC) (envelope-from sdafreebsduk@rowyerboat.com) Received: from rutherford.zen.co.uk (rutherford.zen.co.uk [212.23.3.142]) by mx1.freebsd.org (Postfix) with ESMTP id E7DB213C45D for ; Tue, 9 Oct 2007 01:07:32 +0000 (UTC) (envelope-from sdafreebsduk@rowyerboat.com) Received: from [82.70.166.86] (helo=[192.168.0.200]) by rutherford.zen.co.uk with esmtp (Exim 4.50) id 1If3ZL-0006CG-3z for freebsd-questions@freebsd.org; Tue, 09 Oct 2007 01:07:31 +0000 Message-ID: <470AD44A.4070601@rowyerboat.com> Date: Tue, 09 Oct 2007 02:07:22 +0100 From: Stephen Allen User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.3) Gecko/20070326 Thunderbird/2.0.0.0 Mnenhy/0.7.5.666 MIME-Version: 1.0 To: FreeBSD Questions References: <470AB2FC.8070006@rowyerboat.com> <6.0.0.22.2.20071008183414.025a1e88@mail.computinginnovations.com> In-Reply-To: <6.0.0.22.2.20071008183414.025a1e88@mail.computinginnovations.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Originating-Rutherford-IP: [82.70.166.86] Subject: Re: Question about rc-scripts X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 09 Oct 2007 01:07:33 -0000 Hi Derek, > Not all scripts create a pid file is the simple answer. I didn't see how the isc-dhcpd script or dovecot created a pid, so I assumed it was something that rc.subr took care of. > Your script should create the pid file on start, remove it on stop, and > simply cat that file on a status. If you want help with your script, > post it, and I'm sure one of us will give you a hand. Again, I thought the rc.subr functions took care of all that for you (unless you wanted something special from those commands). I've posted the script (changed quite a lot from vendor supplied) at: http://www.pastebin.ca/730238 If you (or anyone) were to suggest changes, I would very much appreciate the reasons why, so I can learn. Many thanks, Steve