Oh potentially helpful openbsd-misc,

I have written a Python script that takes the output of tcpdump from
pflog0, does some processing on it, and sends it to my monitoring
infrastructure for eventual output into Graphite graphs.

I can run the script just fine via the command line, but when I begin to
tie it into rc.d to start upon machine reboot and for easier process
control, it appears to fail.

The rc.d script itself is nothing involving rocket science:
https://gist.github.com/4576625
Merely start and background itself.

But when I attempt to start the daemon via "/etc/rc.d/pfloggraphite start"
I see the following output:
# ./pfloggraphite start
pfloggraphite(failed)

# ./pfloggraphite check
# echo $?
1

One thing to note, is that the (failed) shows up after 5-10 seconds, not
immediately. But the issue is that the Python script itself is actually
running on the machine. Only rc.d claims it has failed.

I have read the rc.d and rc.subr man pages but perhaps am missing an import
detail in my rc.d file or script itself. Anyone able to shed some light?

Cheers,
Jeff

Reply via email to