Hi there.

I'm trying to figure out how to write an rc.d script that
doesn't redirect stderr to stdout and send both to logger.

Suppose I wanted to keep them separate, and perhaps
pipe one (stdout) to a file or another program. How would
I go about doing that? I tried figuring that out from rc.subr
and these lines seem to be where the magic happens:

${_rcexec} "${daemon_logger:+set -o pipefail; } \
${daemon_execdir:+cd ${daemon_execdir} && } \
$@ \
${daemon_logger:+ 2>&1 | logger -isp ${daemon_logger} -t ${_name}}"

But quite frankly I'm having difficulty understanding these
lines and how I would go about having a script that modifies
or overrides that. Will appreciate any help.

Thanks!

Reply via email to