Re: Problem with a startup script

2013-05-28 Thread C. L. Martinez
On Tue, May 21, 2013 at 6:27 PM, russell russ...@dotplan.dyndns.org wrote: Because pexp uses pkill to do its work and pkill matches on command name only(like ps -c). sorry for the noise I just revisited this and I am wrong. the pkill bits in rc.subr are using pkill -f and that does match

Problem with a startup script

2013-05-22 Thread C. L. Martinez
Hi all, I have a problem with some tcl rc.d startup scripts. Start and status works ok but stop and restart, doesn't. Script: #!/bin/sh -x # # $OpenBSD: suricata_proxyin_agent,v 1.0 daemon=/usr/local/bin/suricata_proxyin_agent.tcl daemon_flags=-c

Re: Problem with a startup script

2013-05-22 Thread Antoine Jacoutot
On Wed, May 22, 2013 at 06:18:04AM +, C. L. Martinez wrote: Hi all, I have a problem with some tcl rc.d startup scripts. Start and status You mean check instead of status, right? works ok but stop and restart, doesn't. Running the rc script in debug mode may give you some clue (-d).

Re: Problem with a startup script

2013-05-22 Thread C. L. Martinez
On Wed, May 22, 2013 at 6:50 AM, Antoine Jacoutot ajacou...@bsdfrog.org wrote: On Wed, May 22, 2013 at 06:18:04AM +, C. L. Martinez wrote: Hi all, I have a problem with some tcl rc.d startup scripts. Start and status You mean check instead of status, right? Yep, you are rigth Antoine

Re: Problem with a startup script

2013-05-22 Thread Antoine Jacoutot
On Wed, May 22, 2013 at 06:57:16AM +, C. L. Martinez wrote: On Wed, May 22, 2013 at 6:50 AM, Antoine Jacoutot ajacou...@bsdfrog.org wrote: On Wed, May 22, 2013 at 06:18:04AM +, C. L. Martinez wrote: Hi all, I have a problem with some tcl rc.d startup scripts. Start and status

Re: Problem with a startup script

2013-05-22 Thread C. L. Martinez
On Wed, May 22, 2013 at 7:02 AM, Antoine Jacoutot ajacou...@bsdfrog.org wrote: On Wed, May 22, 2013 at 06:57:16AM +, C. L. Martinez wrote: On Wed, May 22, 2013 at 6:50 AM, Antoine Jacoutot ajacou...@bsdfrog.org wrote: On Wed, May 22, 2013 at 06:18:04AM +, C. L. Martinez wrote: Hi

Re: Problem with a startup script

2013-05-22 Thread Antoine Jacoutot
On Wed, May 22, 2013 at 07:30:19AM +, C. L. Martinez wrote: On Wed, May 22, 2013 at 7:02 AM, Antoine Jacoutot ajacou...@bsdfrog.org wrote: On Wed, May 22, 2013 at 06:57:16AM +, C. L. Martinez wrote: On Wed, May 22, 2013 at 6:50 AM, Antoine Jacoutot ajacou...@bsdfrog.org wrote:

Re: Problem with a startup script

2013-05-22 Thread Antoine Jacoutot
On Wed, May 22, 2013 at 07:41:38AM +, C. L. Martinez wrote: On Wed, May 22, 2013 at 7:37 AM, Antoine Jacoutot ajacou...@bsdfrog.org wrote: On Wed, May 22, 2013 at 07:30:19AM +, C. L. Martinez wrote: On Wed, May 22, 2013 at 7:02 AM, Antoine Jacoutot ajacou...@bsdfrog.org wrote:

Re: Problem with a startup script

2013-05-22 Thread Vadim Zhukov
22.05.2013 10:19 пользователь C. L. Martinez carlopm...@gmail.com написал: Hi all, I have a problem with some tcl rc.d startup scripts. Start and status works ok but stop and restart, doesn't. Stupid question: does it stop if you kill it by pid directly? I've seen at

Re: Problem with a startup script

2013-05-22 Thread C. L. Martinez
On Wed, May 22, 2013 at 9:15 AM, Vadim Zhukov persg...@gmail.com wrote: 2013/5/22 C. L. Martinez carlopm...@gmail.com On Wed, May 22, 2013 at 8:44 AM, Vadim Zhukov persg...@gmail.com wrote: 22.05.2013 10:19 пользователь C. L. Martinez carlopm...@gmail.com написал: Hi all, I

Re: Problem with a startup script

2013-05-22 Thread Andy
I had a similar problem when writing my own rc.d start script for Snort (compiled instead of package version), and it turned out to be becuase the rc.d script did not implicity incude the variables in 'rc.conf.local' and 'rc.conf' any more. So I just added the following to the top of the rc.d

Re: Problem with a startup script

2013-05-22 Thread russell
On 05/21/2013 11:18 PM, C. L. Martinez wrote: Hi all, I have a problem with some tcl rc.d startup scripts. Start and status works ok but stop and restart, doesn't. Script: #!/bin/sh -x # # $OpenBSD: suricata_proxyin_agent,v 1.0 daemon=/usr/local/bin/suricata_proxyin_agent.tcl

Re: Problem with a startup script

2013-05-22 Thread russell
Because pexp uses pkill to do its work and pkill matches on command name only(like ps -c). sorry for the noise I just revisited this and I am wrong. the pkill bits in rc.subr are using pkill -f and that does match agianst the full arg list. as said before make a better pexp and it should work.