| Summary: | rc.subr fails to recognize daemons using interpreters when they use setproctitle | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| Product: | Base System | Reporter: | Mathieu Arnold <mat> | ||||||||
| Component: | conf | Assignee: | freebsd-rc (Nobody) <rc> | ||||||||
| Status: | Open --- | ||||||||||
| Severity: | Affects Many People | CC: | jilles | ||||||||
| Priority: | --- | Keywords: | patch | ||||||||
| Version: | 10.3-RELEASE | ||||||||||
| Hardware: | Any | ||||||||||
| OS: | Any | ||||||||||
| See Also: | https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=221000 | ||||||||||
| Attachments: |
|
||||||||||
Created attachment 184995 [details]
v1bis
And here is a patch that adds a new variable to add to the glob code.
Created attachment 184996 [details]
v2bis
Fixup the alternative patch.
Patch v1 seems sensible. Patch v2bis looks like it will not work (the | is literal, e.g. sh -c 'case "a|b" in a${$+|b}) echo yes;; esac' prints yes) and the extra complexity is probably unnecessary.
|
Created attachment 184994 [details] v1 Some daemon runs, say, with: /usr/local/bin/perl -wT /usr/local/share/munin/munin-asyncd And for the few first milliseconds, `ps -ww -o pid= -o jid= -o command=` that rc.subr uses will return that as the command, and then, it starts working, and then, the command ends up being: munin-asyncd [aragorn.in.absolight.net] [idle] (perl) So, here is a patch that will support "<command_name>*(<interp>)"