On Mon, May 5, 2008 at 1:50 PM, Daniel Cid <[EMAIL PROTECTED]> wrote:
>
>  It was supposed to create an entry at /etc/rc.local . Can you check in
>  there? This file is supposed
>  to be called during startup.
>

Ah, yeah, it's there. That'll work, though I suggest putting it in
/usr/local/etc/rc.d/ as it is the current standard location for
startup scripts on FreeBSD, and what FreeBSD admins are accustomed to
seeing. The rc man page on FreeBSD also states:
"The best way to handle rc.local, however, is to separate it out into
rc.d/ style scripts and place them under /usr/local/etc/rc.d/."

This page offers a pretty brief description of how to create startup scripts.
http://www.freebsd.org/doc/en/books/handbook/configtuning-starting-services.html
I took a brief stab at it, but wasn't successful and don't have time
at the moment to really dig into it.

Here's my attempt, which doesn't quite work right but likely isn't far off.
----
#!/bin/sh
#
# OSSEC rc.d startup script for FreeBSD
#
ossec_enable=${ossec_enable-"NO"}

. /etc/rc.subr
name="ossec"
rcvar=`set_rcvar`
command="/var/ossec/bin/ossec-control"

load_rc_config $name

run_rc_command "$1"
----

best,
Chris

Reply via email to