[ClusterLabs] [Question and Request] QUERY behavior of glue's plugin.

Ken Gaillot kgaillot at redhat.com
Wed Sep 12 18:56:42 EDT 2018


On Sun, 2018-09-02 at 09:14 +0900, renayama19661014 at ybb.ne.jp wrote:
> Hi All,
> 
> The behavior of glue-based STONITH plug-in such as external / ipmi
> has been changed since PM 1.1.16.
> Up to PM 1.1.15, "status" was executed in QUERY of STONITH.
> For PM 1.1.16 and later, "list" is executed.
> 
> This is due to the following changes.
>  -
> https://github.com/ClusterLabs/pacemaker/commit/3f2d1b1302adc40d9647e
> 854187b7a85bd38f8fb
> We want to use the same status behavior as PM 1.1.15.
> 
> I confirmed the source code, it looks like the following.
> 
> ---
> static const char *
> target_list_type(stonith_device_t * dev)
> {
>     const char *check_type = NULL;
> 
>     check_type = g_hash_table_lookup(dev->params,
> STONITH_ATTR_HOSTCHECK);
> 
>     if (check_type == NULL) {
> 
>         if (g_hash_table_lookup(dev->params, STONITH_ATTR_HOSTLIST))
> {
>             check_type = "static-list";
>         } else if (g_hash_table_lookup(dev->params,
> STONITH_ATTR_HOSTMAP)) {
>             check_type = "static-list";
>         } else if(is_set(dev->flags, st_device_supports_list)){
>             check_type = "dynamic-list";
>         } else if(is_set(dev->flags, st_device_supports_status)){
>             check_type = "status";
>         } else {
>             check_type = "none";
>         }
>     }
> 
>     return check_type;
> }
> ---

Your analysis is correct. That commit added support for the "list"
command to fence_legacy. Since support for "list" takes precedence over
support for "status" when determining the default for pcmk_host_check,
it changed the behavior when pcmk_host_check is left unset.

> 
> We have made the following settings in order to execute "status" even
> after PM 1.1.16.
> Is this setting correct?
> 
> (snip)
>         params \
>                 pcmk_host_check="status" \
> (snip)

Yes, that will do it.

> 
> Also, if this setting is correct, there is no document for "status"
> setting.
> 
>  - http://clusterlabs.org/pacemaker/doc/en-US/Pacemaker/1.1/html/Pace
> maker_Explained/_differences_of_stonith_resources.html
>  - http://clusterlabs.org/pacemaker/doc/en-US/Pacemaker/2.0/html/Pace
> maker_Explained/_special_treatment_of_stonith_resources.html
> 
> Can you add a description such as "status" to the document?
> 
> Best Regards,
> Hideo Yamauchi.

Thanks for catching that -- I'll document it.
-- 
Ken Gaillot <kgaillot at redhat.com>



More information about the Users mailing list