renay****@ybb*****
renay****@ybb*****
2009年 10月 15日 (木) 12:09:49 JST
稲垣さん こんにちは。メイトリックスの山内です。 同一環境で試していませんが、mysqlのstopに失敗していることが原因です。 mysqlのlsbスクリプトの停止実行(stop)で、mysqlがkillされている状態の場合に、正しい戻り値(0)が返ってい るかどうか確認してみてください。 以上、よろしくお願いいたします。 --- 稲垣 <tadas****@gmail*****> wrote: > お世話になっております。稲垣と申します。 > > 掲題の件について質問させてください。 > Heartbeatのリリース2の場合、プロセスもしくはサービス(本環境ではMySQLのプロセス)が停止するとフェイ ルオーバするものと思っておりますが、 > 現環境ではフェイルオーバが実行されず、下記【手順】のようになってしまいます。 > 尚、プロセスをkillする場合とinitスクリプトを停止する場合でも同じ結果となりました。 > 添付したcib.xmlファイルに不備等ありますか? > > 【手順】 > # ps -ef | grep mysql > root 2397 27259 0 18:22 pts/1 00:00:00 grep mysql > root 3068 1 0 01:38 ? 00:00:00 /bin/sh > /usr/bin/mysqld_safe --datadir=/var/lib/mysql > --socket=/var/lib/mysql/mysql.sock --log-error=/var/log/mysqld.log > --pid-file=/var/run/mysqld/mysqld.pid --federated --user=mysql > mysql 3182 3068 0 01:38 ? 00:00:01 /usr/libexec/mysqld > --basedir=/usr --datadir=/var/lib/mysql --user=mysql --federated > --log-error=/var/log/mysqld.log --pid-file=/var/run/mysqld/mysqld.pid > --socket=/var/lib/mysql/mysql.sock > > # kill -9 2397 3068 > > # crm_mon -1 > > > ============ > Last updated: Sat Oct 17 07:29:25 2009 > Current DC: hoge02.example.com (91e0db86-1aaf-47a9-a80f-bc198c4c8969) > 2 Nodes configured. > 1 Resources configured. > ============ > > Node: hoge02.example.com (91e0db86-1aaf-47a9-a80f-bc198c4c8969): online > Node: hoge01.example.com (dbdb4396-8c57-4f70-878f-a6984ec7d554): online > > Resource Group: test-db > IPaddr2_1 (ocf::heartbeat:IPaddr2): Started hoge01.example.com > drbddisk_2 (heartbeat:drbddisk): Started hoge01.example.com > Filesystem_3 (ocf::heartbeat:Filesystem): Started > hoge01.example.com > mysqld_4 (lsb:mysqld): Started hoge01.example.com (unmanaged) FAILED > > Failed actions: > mysqld_4_monitor_120000 (node=hoge01.example.com, call=13, rc=7): complete > mysqld_4_stop_0 (node=hoge01.example.com, call=14, rc=1): complete > > > 検証環境は以下の通りです。 > OS: CentOS5.3 > Heartbeat 2.1.4-1 > > > 以上、宜しくお願いいたします。 > > <cib admin_epoch="0" generated="true" have_quorum="true" ignore_dtd="false" num_peers="2" > cib_feature_revision="2.0" crm_feature_set="2.0" ccm_transition="2" epoch="69" > dc_uuid="91e0db86-1aaf-47a9-a80f-bc198c4c8969" num_updates="3" cib-last-written="Fri Oct 16 > 01:38:10 2009"> > <configuration> > <crm_config> > <cluster_property_set id="cib-bootstrap-options"> > <attributes> > <nvpair id="cib-bootstrap-options-symmetric-cluster" name="symmetric-cluster" > value="true"/> > <nvpair id="cib-bootstrap-options-no-quorum-policy" name="no-quorum-policy" > value="stop"/> > <nvpair id="cib-bootstrap-options-default-resource-stickiness" > name="default-resource-stickiness" value="INFINITY"/> > <nvpair id="cib-bootstrap-options-default-resource-failure-stickiness" > name="default-resource-failure-stickiness" value="0"/> > <nvpair id="cib-bootstrap-options-stonith-enabled" name="stonith-enabled" > value="false"/> > <nvpair id="cib-bootstrap-options-stonith-action" name="stonith-action" > value="reboot"/> > <nvpair id="cib-bootstrap-options-startup-fencing" name="startup-fencing" > value="true"/> > <nvpair id="cib-bootstrap-options-stop-orphan-resources" name="stop-orphan-resources" > value="true"/> > <nvpair id="cib-bootstrap-options-stop-orphan-actions" name="stop-orphan-actions" > value="true"/> > <nvpair id="cib-bootstrap-options-remove-after-stop" name="remove-after-stop" > value="false"/> > <nvpair id="cib-bootstrap-options-short-resource-names" name="short-resource-names" > value="true"/> > <nvpair id="cib-bootstrap-options-transition-idle-timeout" > name="transition-idle-timeout" value="5min"/> > <nvpair id="cib-bootstrap-options-default-action-timeout" > name="default-action-timeout" value="20s"/> > <nvpair id="cib-bootstrap-options-is-managed-default" name="is-managed-default" > value="true"/> > <nvpair id="cib-bootstrap-options-cluster-delay" name="cluster-delay" value="60s"/> > <nvpair id="cib-bootstrap-options-pe-error-series-max" name="pe-error-series-max" > value="-1"/> > <nvpair id="cib-bootstrap-options-pe-warn-series-max" name="pe-warn-series-max" > value="-1"/> > <nvpair id="cib-bootstrap-options-pe-input-series-max" name="pe-input-series-max" > value="-1"/> > <nvpair id="cib-bootstrap-options-dc-version" name="dc-version" > value="2.1.4-fb84f606a422 tip"/> > </attributes> > </cluster_property_set> > </crm_config> > <nodes> > <node id="91e0db86-1aaf-47a9-a80f-bc198c4c8969" uname="hoge02.example.com" type="normal"> > <instance_attributes id="nodes-91e0db86-1aaf-47a9-a80f-bc198c4c8969"> > <attributes> > <nvpair id="standby-91e0db86-1aaf-47a9-a80f-bc198c4c8969" name="standby" > value="off"/> > </attributes> > </instance_attributes> > </node> > <node id="dbdb4396-8c57-4f70-878f-a6984ec7d554" uname="hoge01.example.com" > type="normal"/> > </nodes> > <resources> > <group id="test-db"> > <primitive class="ocf" id="IPaddr2_1" provider="heartbeat" type="IPaddr2"> > <operations> > <op id="IPaddr2_1_mon" interval="5s" name="monitor" timeout="5s"/> > </operations> > <instance_attributes id="IPaddr2_1_inst_attr"> > <attributes> > <nvpair id="IPaddr2_1_attr_0" name="ip" value="172.31.208.220"/> > <nvpair id="IPaddr2_1_attr_1" name="nic" value="eth0"/> > <nvpair id="IPaddr2_1_attr_2" name="cidr_netmask" value="24"/> > <nvpair id="IPaddr2_1_attr_3" name="broadcast" value="172.31.208.255"/> > </attributes> > </instance_attributes> > </primitive> > <primitive class="heartbeat" id="drbddisk_2" provider="heartbeat" type="drbddisk"> > <operations> > <op id="drbddisk_2_mon" interval="120s" name="monitor" timeout="60s"/> > </operations> > <instance_attributes id="drbddisk_2_inst_attr"> > <attributes> > <nvpair id="drbddisk_2_attr_1" name="1" value="r0"/> > </attributes> > </instance_attributes> > </primitive> > <primitive class="ocf" id="Filesystem_3" provider="heartbeat" type="Filesystem"> > <operations> > <op id="Filesystem_3_mon" interval="120s" name="monitor" timeout="60s"/> > </operations> > <instance_attributes id="Filesystem_3_inst_attr"> > <attributes> > <nvpair id="Filesystem_3_attr_0" name="device" value="/dev/drbd0"/> > <nvpair id="Filesystem_3_attr_1" name="directory" value="/var/lib/mysql"/> > <nvpair id="Filesystem_3_attr_2" name="fstype" value="ext3"/> > <nvpair id="Filesystem_3_attr_3" name="options" value="noatime,defaults"/> > </attributes> > </instance_attributes> > </primitive> > <primitive class="lsb" id="mysqld_4" provider="heartbeat" type="mysqld"> > <operations> > <op id="mysqld_4_mon" interval="120s" name="monitor" timeout="60s"/> > </operations> > </primitive> > </group> > </resources> > <constraints> > <rsc_location id="rsc_location_test-db" rsc="test-db"> > <rule id="prefered_location_test-db" score="100"> > <expression attribute="#uname" id="prefered_location_test-db_expr" operation="eq" > value="hoge01.example.com"/> > </rule> > </rsc_location> > <rsc_location id="pingd" rsc="test-db"> > <rule id="pingd:connected:rule" score="-INFINITY" boolean_op="or"> > <expression id="pingd:expr:undefined" attribute="default_ping_set" > operation="not_defined"/> > <expression id="pingd:expr:zero" attribute="default_ping_set" operation="lte" > value="0"/> > </rule> > </rsc_location> > </constraints> > </configuration> > </cib> > > _______________________________________________ > Linux-ha-japan mailing list > Linux****@lists***** > http://lists.sourceforge.jp/mailman/listinfo/linux-ha-japan >