[Pacemaker] About "record-pending"

Andrew Beekhof beekhof at gmail.com
Mon Oct 27 05:08:27 EDT 2008


On Oct 27, 2008, at 10:07 AM, Yan Gao wrote:

> On Sun, 2008-10-26 at 12:47 +0200, Andrew Beekhof wrote:
>> On Thu, Oct 23, 2008 at 17:02, Yan Gao <ygao at novell.com> wrote:
>>> On Thu, 2008-10-23 at 14:23 +0200, Andrew Beekhof wrote:
>>>>>
>>>>> It seems that the set cannot be found in the hash table.
>>>>>
>>>>> te_actions.c:461
>>>>> value = g_hash_table_lookup(action->params,
>>>>> crm_meta_name(XML_OP_ATTR_PENDING));
>>>>>
>>>>> Did I make any mistake? Really strange...
>>>>
>>>> Hmm....
>>>>
>>>> Can you try the following patch and see if it helps pls?
>>>>
>>>> diff -r 59a110c159f3 pengine/graph.c
>>>> --- a/pengine/graph.c Thu Oct 16 16:17:21 2008 +0200
>>>> +++ b/pengine/graph.c Thu Oct 23 14:22:47 2008 +0200
>>>> @@ -486,6 +486,7 @@ action2xml(action_t *action, gboolean as
>>>>                      XML_RSC_ATTR_INCARNATION_NODEMAX,
>>>>                      XML_RSC_ATTR_MASTER_MAX,
>>>>                      XML_RSC_ATTR_MASTER_NODEMAX,
>>>> +                     XML_RSC_ATTR_PENDING,
>>>>              };
>>>>
>>>>              for(lpc = 0; lpc < DIMOF(meta_list); lpc++) {
>>>
>>> You meant
>>> +                      XML_OP_ATTR_PENDING,
>>> ?
>>> I tried it, and still cannot be found.
>>
>> Can you try this one instead?
>>
>> diff -r 23c237ed0cbe crmd/te_actions.c
>> --- a/crmd/te_actions.c	Sun Oct 26 11:20:37 2008 +0100
>> +++ b/crmd/te_actions.c	Sun Oct 26 11:47:06 2008 +0100
>> @@ -458,7 +458,7 @@ send_rsc_command(crm_action_t *action)
>> 		te_start_action_timer(action);
>> 	}
>>
>> -	value = g_hash_table_lookup(action->params,
>> crm_meta_name(XML_OP_ATTR_PENDING));
>> +	value = g_hash_table_lookup(action->params,  
>> crm_meta_name("record_pending"));
>> 	if(crm_is_true(value)) {
>> 	    /* write a "pending" entry to the CIB, inhibit notification */
>> 	    crm_info("Recording pending op %s in the CIB", task_uuid);
>
> It works :-), while I'm still using "record-pending" as attribute  
> name.

Right.  That was the problem.  We weren't setting and getting meta  
attributes consistently.
This is now fixed in
    http://hg.clusterlabs.org/pacemaker/stable-1.0/rev/1eca6b7f73b3

>
> Another issue is it doesn't trigger cib notify, hence mgmtd cannot be
> aware of the event.

Is the crm sending the update with the cib_inhibit_notify flag?




More information about the Pacemaker mailing list