From owner-freebsd-rc@FreeBSD.ORG Wed Jul 21 17:37:43 2004 Return-Path: Delivered-To: freebsd-rc@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id DD3E616A4CE for ; Wed, 21 Jul 2004 17:37:43 +0000 (GMT) Received: from smtp1.utdallas.edu (smtp1.utdallas.edu [129.110.10.12]) by mx1.FreeBSD.org (Postfix) with ESMTP id B40E043D1F for ; Wed, 21 Jul 2004 17:37:43 +0000 (GMT) (envelope-from pauls@utdallas.edu) Received: from utd49554 (utd49554.utdallas.edu [129.110.3.85]) by smtp1.utdallas.edu (Postfix) with ESMTP id 8D6DF389005 for ; Wed, 21 Jul 2004 12:37:00 -0500 (CDT) Date: Wed, 21 Jul 2004 12:36:57 -0500 From: Paul Schmehl To: freebsd-rc@freebsd.org Message-ID: In-Reply-To: References: X-Mailer: Mulberry/3.1.6 (Linux/x86) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline Subject: Re: rc script won't start daemon on reboot X-BeenThere: freebsd-rc@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussion related to /etc/rc.d design and implementation. List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 21 Jul 2004 17:37:44 -0000 --On Wednesday, July 21, 2004 09:59:21 AM +0200 Oliver Eikemeier wrote: > > Try > echo 'rc_debug="YES"' >> /etc/rc.conf > > and look at the trace info in /var/log/messages. > Here it is: /var/log/messages: Jul 21 12:23:06 smblure root: /usr/local/etc/rc.d/extractor.sh: INFO: checkyesno: extractor_enable is set to YES. Jul 21 12:23:06 smblure root: /usr/local/etc/rc.d/extractor.sh: INFO: run_rc_command: _doit: /usr/local/bin/extractor -D Despite this, the daemon did not start. bash-2.05b# /usr/local/etc/rc.d/extractor.sh status /usr/local/etc/rc.d/extractor.sh: DEBUG: checkyesno: extractor_enable is set to YES. extractor is not running. bash-2.05b# /usr/local/etc/rc.d/extractor.sh start /usr/local/etc/rc.d/extractor.sh: DEBUG: checkyesno: extractor_enable is set to YES. Starting extractor. /usr/local/etc/rc.d/extractor.sh: DEBUG: run_rc_command: _doit: /usr/local/bin/extractor -D DeepSight Extractor 4.3 Copyright 2000-2004, Symantec Using sensors file: /root/.extractor/Timestamps Using config file: /root/.extractor/ConfigFile.ini Initializing Daemon Mode. ********* * NOTE: * ********* When any of your logfiles are moved/renamed or rolled, you must kill -HUP the Extractor process. Please see the README-FIRST file for details. bash-2.05b# /usr/local/etc/rc.d/extractor.sh status /usr/local/etc/rc.d/extractor.sh: DEBUG: checkyesno: extractor_enable is set to YES. extractor is running as pid 229. This is really strange. It appears that the exact same command that fails during boot succeeds from the commandline. Is there a way to use ktrace to capture everything that's going on with this script during the reboot? I wonder if it matters that /usr/local/bin/extractor is a symlink to /usr/local/extractor/bin/extractor? bash-2.05b# ls -lsa /usr/local/bin/extractor 0 lrwxr-xr-x 1 root wheel 34 Jul 12 15:34 /usr/local/bin/extractor -> /usr/local/extractor/bin/extractor Paul Schmehl (pauls@utdallas.edu) Adjunct Information Security Officer The University of Texas at Dallas AVIEN Founding Member http://www.utdallas.edu/ir/security/