Try removing all the operations in p_mysql.
They should only be defined in ms_mysql

On Fri, May 14, 2010 at 9:20 PM, John Ratz <[email protected]> wrote:
> Hi,
> I did have different interval times, but the problem seems to be that
> a separate monitor function (monitor_Master_0) in the mysql script is needed
> in order to support a separate monitor op.
>
> Here's my config before and after the change:
>
> crm(live)configure# show
> node $id="58397566-b452-43f3-ac8e-45549776d863" node2
> node $id="611d50bd-62c1-4629-bb16-c29ec6210807" node1
> primitive p_clusterip ocf:heartbeat:IPaddr2 \
>         params ip="10.176.1.167" cidr_netmask="32" \
>         op monitor interval="3s" \
>         meta target-role="Started"
> primitive p_mysql ocf:heartbeat:mysql \
>         params binary="/usr/bin/mysqld_safe" config="/etc/my.cnf"
> socket="/var/run/mysqld/mysql.sock" datadir="/var/lib/mysql"
> replication_user="root" replication_passwd="xxxx"
> pid="/var/run/mysqld/mysqld.pid" test_user="root" test_passwd="xxxx" \
>         op start interval="0" timeout="120s" \
>         op stop interval="0" timeout="120s" \
>         op monitor interval="30" timeout="30" OCF_LEVEL_CHECK="1"
> ms ms_mysql p_mysql \
>         meta notify="true" master-max="1" is-managed="true"
> target-role="Started"
> location l_master ms_mysql \
>         rule $id="l_master-rule" $role="Master" 50: #uname eq node1
> colocation mysql_master_on_ip inf: p_clusterip ms_mysql:Master
> order mysql_before_ip inf: ms_mysql:promote p_clusterip:start
> property $id="cib-bootstrap-options" \
>         dc-version="1.0.8-9881a7350d6182bae9e8e557cf20a3cc5dac3ee7" \
>         cluster-infrastructure="Heartbeat" \
>         stonith-enabled="false" \
>         no-quorum-policy="ignore" \
>         last-lrm-refresh="1273611238"
> rsc_defaults $id="rsc-options" \
>         resource-stickiness="100"
> crm(live)configure# edit p_mysql
> WARNING: p_mysql: action monitor_Master_0 not advertised in meta-data, it
> may not be supported by the RA
> crm(live)configure# show
> node $id="58397566-b452-43f3-ac8e-45549776d863" node2
> node $id="611d50bd-62c1-4629-bb16-c29ec6210807" node1
> primitive p_clusterip ocf:heartbeat:IPaddr2 \
>         params ip="10.176.1.167" cidr_netmask="32" \
>         op monitor interval="3s" \
>         meta target-role="Started"
> primitive p_mysql ocf:heartbeat:mysql \
>         params binary="/usr/bin/mysqld_safe" config="/etc/my.cnf"
> socket="/var/run/mysqld/mysql.sock" datadir="/var/lib/mysql"
> replication_user="root" replication_passwd="xxxx"
> pid="/var/run/mysqld/mysqld.pid" test_user="root" test_passwd="xxxx" \
>         op start interval="0" timeout="120s" \
>         op stop interval="0" timeout="120s" \
>         op monitor interval="20" role="Slave" timeout="20"
> OCF_LEVEL_CHECK="1" \
>         op monitor interval="10" role="Master" timeout="20"
> OCF_LEVEL_CHECK="1"
> ms ms_mysql p_mysql \
>         meta notify="true" master-max="1" is-managed="true"
> target-role="Started"
> location l_master ms_mysql \
>         rule $id="l_master-rule" $role="Master" 50: #uname eq node1
> colocation mysql_master_on_ip inf: p_clusterip ms_mysql:Master
> order mysql_before_ip inf: ms_mysql:promote p_clusterip:start
> property $id="cib-bootstrap-options" \
>         dc-version="1.0.8-9881a7350d6182bae9e8e557cf20a3cc5dac3ee7" \
>         cluster-infrastructure="Heartbeat" \
>         stonith-enabled="false" \
>         no-quorum-policy="ignore" \
>         last-lrm-refresh="1273611238"
> rsc_defaults $id="rsc-options" \
>         resource-stickiness="100"
> crm(live)configure# commit
> WARNING: p_mysql: action monitor_Master_0 not advertised in meta-data, it
> may not be supported by the RA
> crm(live)configure#
>
> I know that the drbd script file supports seperate a seperate monitor op for
> the Master.  I tried changing
>
> <action name="monitor" depth="0" timeout="30" interval="10" />
>
> in the mysql file to
>
> <action name="monitor" depth="0" timeout="20" interval="20" role="Slave" />
> <action name="monitor" depth="0" timeout="20" interval="10" role="Master" />
>
> so that it matched what's in the drbd script file.  Doing this prevents the
> above warning, but this still fails and crashes the Master/Slave set.  I
> think that it's attempting to run the same monitor op with the same interval
> on both nodes despite having specified different intervals in the config.
>  Perhaps a fix is needed somewhere in Pacemaker itself?
>
> It seems that it is not conforming
> to http://www.clusterlabs.org/doc/en-US/Pacemaker/1.1/html/Pacemaker_Explained/ch10s03s03s03.html
>
> Thanks,
>
> John
> On Fri, May 14, 2010 at 3:37 AM, Raoul Bhatia [IPAX] <[email protected]>
> wrote:
>>
>> On 05/12/2010 09:30 PM, [email protected] wrote:
>> > Hello All,
>> >
>> > I've been testing out the newly added Master/Slave capability for MySQL,
>> > but it seems to be missing the monitor operation for the Master instance,
>> > i.e. the monitor op for the primitive mysql object only runs on the slave
>> > resource, and an added monitor op with role="Master" fails.  Is this
>> > intended behavior?
>>
>> hi,
>>
>> did you specify two monitor operations with different intervals?
>>
>> e.g. [1]
>>
>> > crm configure
>> >
>> > primitive drbd0 ocf:heartbeat:drbd \
>> >  params drbd_resource=drbd0 \
>> >  op monitor role=Master interval=59s timeout=30s \
>> >  op monitor role=Slave interval=60s timeout=30s
>> >
>> > ms ms-drbd0 drbd0 \
>> >  meta clone-max=2 notify=true globally-unique=false target-role=stopped
>>
>> thanks,
>> raoul
>> [1] http://www.clusterlabs.org/wiki/DRBD_HowTo_1.0
>> --
>> ____________________________________________________________________
>> DI (FH) Raoul Bhatia M.Sc.          email.          [email protected]
>> Technischer Leiter
>>
>> IPAX - Aloy Bhatia Hava OG          web.          http://www.ipax.at
>> Barawitzkagasse 10/2/2/11           email.            [email protected]
>> 1190 Wien                           tel.               +43 1 3670030
>> FN 277995t HG Wien                  fax.            +43 1 3670030 15
>> ____________________________________________________________________
>> _______________________________________________________
>> Linux-HA-Dev: [email protected]
>> http://lists.linux-ha.org/mailman/listinfo/linux-ha-dev
>> Home Page: http://linux-ha.org/
>
>
> _______________________________________________________
> Linux-HA-Dev: [email protected]
> http://lists.linux-ha.org/mailman/listinfo/linux-ha-dev
> Home Page: http://linux-ha.org/
>
>
_______________________________________________________
Linux-HA-Dev: [email protected]
http://lists.linux-ha.org/mailman/listinfo/linux-ha-dev
Home Page: http://linux-ha.org/

Reply via email to