rc script won't start daemon on reboot
Paul Schmehl
pauls at utdallas.edu
Wed Jul 21 10:37:44 PDT 2004
--On Wednesday, July 21, 2004 09:59:21 AM +0200 Oliver Eikemeier
<eikemeier at 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 at utdallas.edu)
Adjunct Information Security Officer
The University of Texas at Dallas
AVIEN Founding Member
http://www.utdallas.edu/ir/security/
More information about the freebsd-rc
mailing list