[Pacemaker] Monitor a resource without the cluster reacting to the result...

Andrew Beekhof beekhof at gmail.com
Fri Mar 27 13:15:27 UTC 2009


On Fri, Mar 27, 2009 at 13:54, Joe Bill <foxycode at yahoo.com> wrote:
>
> --- On Fri, 3/27/09, Andrew Beekhof <beekhof at gmail.com> wrote:
>
>>>> I saw later that you want to prevent the cluster
>>>> from doing anything for the resource, simply set
>>>> is-managed=false for the resource in question.
>
>>> This is incorrect. I want the cluster to react to
>>> everything BUT to this specific invocation of MONITOR.
>
>>
>> Then I don't understand what the purpose of the monitor is as there
>> will be no other actions for the resource until the monitor completes.
>
> Sorry my answer above was incomplete, I just tried to counter-point your statement above it.
>
> What I would expect is for my "mostly harmless" monitor operation to have the same "blocking" effect, at least on other monitoring operations, as a "fully effective" monitor operation. No more, no less.

There are just actions.  None are any more or less fully effective
than anything else.
Why don't you back up and explain what you want to achieve instead of
specifying the implementation.

> What happens if I manually issue a "target role=stopped" on a resource while it's "is managed=true" and a monitor operation is running ?

Which part of "no two actions for a single resource are ever performed
concurrently" is not clear?
It waits.

>
> Will the cluster interrupt/kill the currently running monitor operation before invoking the stop resource operation ?
>
> I suppose no.

Correct

> Will the cluster let the currently running monitor operation complete by itself, and only then invoke the stop resource operation ?
>
> I suppose yes, while the monitor operation hasn't reached it's timeout.

Correct

> Now I would expect that once ***any*** monitoring operation reached its timeout, the cluster would kill it, wouldn't it ?

All actions, not just monitors, have timeouts.  Once they are hit,
then the child process executing the action is killed with -KILL.
Monitors are not special in this.

> And this whether a resource "stop" is pending or not.
>
> Do you confirm ?
>
>>> Won't the cluster NEVER interrupt an ongoing
>>> MONITOR operation beyond a certain amount of time ?
>
>> Two actions will absolutely never be concurrently
>> performed for a single resource.
>> This is enforced by the lrmd.
>
> That is why I would expect the cluster to ***interrupt*** the ongoing MONITOR operation once the timeout has been reached, no ?

Not interrupt, kill.  There distinction is important.

>>> Also what happens if, while a MONITOR operation
>>> is going on, I issue a:
>>> "crm_resource -M" on the same resource to migrate it ?
>>>
>>> Will the cluster wait until the monitor operation is finished ?
>
>> Clearly it must.
>> Otherwise the monitor would fail.
>
> At this point, if a "crm_resource -M" was issued and the resource migration is pending, who cares about the completion status of the ongoing MONITOR function ? Who cares that it even completes at all ?

Did it stop or did it fail?  How is the cluster supposed to know?
It just sees the stop return "ok" and then a monitor return with an error.




More information about the Pacemaker mailing list