[Pacemaker] unexpected demote request on master

K Mehta kiranmehta1981 at gmail.com
Fri May 30 06:28:54 UTC 2014


any update ?


On Thu, May 29, 2014 at 9:08 AM, K Mehta <kiranmehta1981 at gmail.com> wrote:

> In which pcs version is this issue fixed ?
>
>
> On Wednesday, May 28, 2014, K Mehta <kiranmehta1981 at gmail.com> wrote:
> > Chris,
> > Here is the required information
> > [root at vsanqa11 ~]# rpm -qa | grep pcs ; rpm -qa | grep pacemaker ;
> uname -a ; cat /etc/redhat-release
> > pcs-0.9.90-2.el6.centos.2.noarch
> > pacemaker-cli-1.1.10-14.el6_5.3.x86_64
> > pacemaker-libs-1.1.10-14.el6_5.3.x86_64
> > pacemaker-1.1.10-14.el6_5.3.x86_64
> > pacemaker-cluster-libs-1.1.10-14.el6_5.3.x86_64
> > Linux vsanqa11 2.6.32-279.el6.x86_64 #1 SMP Fri Jun 22 12:19:21 UTC 2012
> x86_64 x86_64 x86_64 GNU/Linux
> > CentOS release 6.3 (Final)
> >
> > Regards,
> >  Kiran
> >
> > On Wed, May 28, 2014 at 2:47 AM, Chris Feist <cfeist at redhat.com> wrote:
> >
> > On 05/27/14 05:38, K Mehta wrote:
> >
> > One more question.
> > With crmsh, it was easy to add constraint to avoid a resource from
> running only
> > a subset(say vsanqa11 and vsanqa12) of nodes using the following command
> >
> > crm configure location ms-${uuid}-nodes ms-$uuid rule -inf: \#uname ne
> vsanqa11
> > and \#uname ne  vsanqa12
> > [root at vsanqa11 ~]# pcs constraint show --full
> > Location Constraints:
> >    Resource: ms-c6933988-9e5c-419e-8fdf-744100d76ad6
> >      Constraint: ms-c6933988-9e5c-419e-8fdf-744100d76ad6-nodes
> >        Rule: score=-INFINITY
> >   (id:ms-c6933988-9e5c-419e-8fdf-744100d76ad6-nodes-rule)
> >          Expression: #uname ne vsanqa11
> >   (id:ms-c6933988-9e5c-419e-8fdf-744100d76ad6-nodes-expression)
> >          Expression: #uname ne vsanqa12
> >   (id:ms-c6933988-9e5c-419e-8fdf-744100d76ad6-nodes-expression-0)
> > Ordering Constraints:
> > Colocation Constraints:
> >
> > So, both expression are part of the same rule as expected.
> >
> >
> >
> > With pcs, I am not sure how to use avoid constraints if I need a
> resource to run
> > on vsanqa11 and vsanqa12 and not on any other node.
> > So I tried adding location constraint as follows:
> > pcs -f $CLUSTER_CREATE_LOG constraint location vha-$uuid rule
> score=-INFINITY
> > \#uname ne vsanqa11 and \#uname ne vsanqa12
> > Even though no error is thrown, the condition after "and" is silently
> dropped as
> > shown below
> >
> > [root at vsanqa11 ~]# pcs constraint show --full
> > Location Constraints:
> >    Resource: ms-c6933988-9e5c-419e-8fdf-744100d76ad6
> >      Constraint: location-vha-c6933988-9e5c-419e-8fdf-744100d76ad6
> >        Rule: score=-INFINITY
> >   (id:location-vha-c6933988-9e5c-419e-8fdf-744100d76ad6-rule)
> >          Expression: #uname ne vsanqa11
> >   (id:location-vha-c6933988-9e5c-419e-8fdf-744100d76ad6-rule-expr)
> > Ordering Constraints:
> > Colocation Constraints:
> >
> >
> > Then I tried the following
> > pcs -f $CLUSTER_CREATE_LOG constraint location vha-$uuid rule
> score=-INFINITY
> > \#uname ne vsanqa11
> > pcs -f $CLUSTER_CREATE_LOG constraint location vha-$uuid rule
> score=-INFINITY
> > \#uname ne vsanqa12
> >
> > but running these two commands did not help either. Expressions were
> added to
> > separate rules.
> >
> > [root at vsanqa11 ~]# pcs constraint show --full
> > Location Constraints:
> >    Resource: ms-c6933988-9e5c-419e-8fdf-744100d76ad6
> >      Constraint: location-vha-c6933988-9e5c-419e-8fdf-744100d76ad6-1
> >        Rule: score=-INFINITY
> >   (id:location-vha-c6933988-9e5c-419e-8fdf-744100d76ad6-1-rule)
> >          Expression: #uname ne vsanqa12
> >   (id:location-vha-c6933988-9e5c-419e-8fdf-744100d76ad6-1-rule-expr)
> >      Constraint: location-vha-c6933988-9e5c-419e-8fdf-744100d76ad6
> >        Rule: score=-INFINITY
> >   (id:location-vha-c6933988-9e5c-419e-8fdf-744100d76ad6-rule)
> >          Expression: #uname ne vsanqa11
> >   (id:location-vha-c6933988-9e5c-419e-8fdf-744100d76ad6-rule-expr)
> > Ordering Constraints:
> > Colocation Constraints:
> >
> >
> > Also, tried using multistate resource name
> > [root at vsanqa11 ~]# pcs constraint location
> > ms-c6933988-9e5c-419e-8fdf-744100d76ad6 rule score=-INFINITY \#uname ne
> vsanqa11
> > Error: 'ms-c6933988-9e5c-419e-8fdf-744100d76ad6' is not a resource
> >
> >
> > Can anyone let me correct command for this ?
> >
> > Which version of pcs are you using (and what distribution)?  This has
> been fixed upstream.  (Below is a test from my system using the upstream
> pcs).
> >
> > [root at rh7-1 pcs]# pcs constraint location D1 rule score=-INFINITY
> \#uname ne vsanqa11 and \#uname ne vsanqa12
> > [root at rh7-1 pcs]# pcs constraint
> > Location Constraints:
> >   Resource: D1
> >     Constraint: location-D1
> >       Rule: score=-INFINITY boolean-op=and
> >         Expression: #uname ne vsanqa11
> >         Expression: #uname ne vsanqa12
> >
> > Thanks,
> > Chris
> >
> >
> >
> >
> >
> >
> > On Tue, May 27, 2014 at 11:01 AM, Andrew Beekhof <andrew at beekhof.net
> > <mailto:
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.clusterlabs.org/pipermail/pacemaker/attachments/20140530/8dd742db/attachment.htm>


More information about the Pacemaker mailing list