Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 21 Jul 2004 12:36:57 -0500
From:      Paul Schmehl <pauls@utdallas.edu>
To:        freebsd-rc@freebsd.org
Subject:   Re: rc script won't start daemon on reboot
Message-ID:  <C1E3DC239D41EF003C3ABF8E@utd49554.utdallas.edu>
In-Reply-To: <E001044F-DAEB-11D8-BA2D-00039312D914@fillmore-labs.com>
References:  <E001044F-DAEB-11D8-BA2D-00039312D914@fillmore-labs.com>

next in thread | previous in thread | raw e-mail | index | archive | help
--On Wednesday, July 21, 2004 09:59:21 AM +0200 Oliver Eikemeier 
<eikemeier@fillmore-labs.com> 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/



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