On Sun, Jan 20, 2013 at 12:03 AM, Matthew Weigel <uni...@idempot.net> wrote:

> On 1/19/2013 10:23 PM, Forman, Jeffrey wrote:
>
> > 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.
>
> When rc_bg=YES, "rc_cmd start" does the equivalent of "rc_cmd check"
> waiting
> for the named daemon to show up in the process list.
>
> Since /usr/local/pf-graphite/pfloggraphite is a Python script, the process
> listing begins with "/usr/local/bin/python" (or whichever python), *not*
> /usr/local/pf-graphite/pfloggraphite.
>
> > 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?
>
> I believe you need to define pexp after sourcing rc.subr.
>

You were exactly right. I ended up looking at a daemon just like this one,
puppetd which runs under Ruby, and it had a similar pexp variable. I added

pexp=".*python.* ${daemon}"

to my rc.d file after sourcing rc.subr, and things work perfectly. Thanks
Matthew.



> --
>  Matthew Weigel
>  hacker
>  unique & idempot . ent

Reply via email to