[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: conditionally signalling processes

From: Alan Sparks
Subject: Re: conditionally signalling processes
Date: Wed, 22 Nov 2000 11:41:22 -0700

address@hidden wrote:
> In cfengine 1.6.0.b3 you can say:
> processes:
> "XXX" matches=<20  action=bymatch signal=kill
> which will signal all XXX processes if there are more than 20.
> See also the new filter possibilities. I'll be putting this out
> within a few hours.

Observations about b3 (been looking at it a couple hours):

1) Looks like the "negating classes" patch I submitted didn't make it
into this version...

2) The "bymatch" action (as you describe above) has nasty interactions
with the "restart" clause.  If you try both, you'll likely see something
like what I see with my test:

        "a.out" matches=1 action=bymatch signal=term
                restart "/export/home/asparks/a.out"

where successive runs of cfengine will describe the actions:
a) no "a.out" process running, restarting (1 copy running)
b) one running, no signals, restart (2nd copy -- BAD)
c) two running, send signals to all, restart (1 copy running)
d) one running, no signals, restart (2nd copy -- BAD)

3) Suggestion:  I see that the "cfengine-die" facility is not supported
for shellcommands as for processes.  I've had some shell commands that
have needed the cfengine-die facility, since they seem to hang cfengine
exactly as they do in the processes restart clause.  Perhaps that
functionality should be added to the shellcommands handler.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]