Re: [Pacemaker] don't want to restart clone resource

2011-12-17 Thread Sha Fanghao
On Fri, Dec 09, 2011 at 08:23:36AM +1100, Andrew Beekhof wrote:

> Can you file a bug and attach a crm_report to it please?

> Unfortunately there's not enough information here to figure out the

> cause (although it does look like a bug)

 

Anything else except "messages" file?

 

 

Node count drops from three to two,

 rsc:2 becomes the label of "orphaned" resources,

 "orphanes" are to be stopped by default?

 

Something like that?

 

Exactly.

I have tried to set "stop-orphan-resources" and "stop-orphan-actions" options 
to FALSE, 

it couldn't be resolved.

 

> 

> 2011/12/1 Sha Fanghao :

> > Hi,

> >

> >

> >

> > I have a cluster 3 nodes (CentOS 5.2) using pacemaker-1.0.11(also 1.0.12),

> > with heartbeat-3.0.3.

> >

> > You can see the configuration:

> >

> >

> >

> > #crm configure show:

> >

> > node $id="85e0ca02-7aa4-45c8-9911-4035e1e6ee15" node-2

> >

> > node $id="a046bd1e-6267-49e5-902d-c87b6ed1dcb9" node-0

> >

> > node $id="d0f0b2ab-f243-4f78-b541-314fa7d6b346" node-1

> >

> > primitive failover-ip ocf:heartbeat:IPaddr2 \

> >

> > params ip="10.10.5.83" \

> >

> > op monitor interval="5s"

> >

> > primitive master-app-rsc lsb:cluster-master \

> >

> > op monitor interval="5s"

> >

> > primitive node-app-rsc lsb:cluster-node \

> >

> > op monitor interval="5s"

> >

> > group group-dc failover-ip master-app-rsc

> >

> > clone clone-node-app-rsc node-app-rsc

> >

> > location rule-group-dc group-dc \

> >

> > rule $id="rule-group-dc-rule" -inf: #is_dc eq false

> >

> > property $id="cib-bootstrap-options" \

> >

> > start-failure-is-fatal="false" \

> >

> > no-quorum-policy="ignore" \

> >

> > symmetric-cluster="true" \

> >

> > stonith-enabled="false" \

> >

> > dc-version="1.0.11-1554a83db0d3c3e546cfd3aaff6af1184f79ee87" \

> >

> > cluster-infrastructure="Heartbeat"

> >

> >

> >

> > #crm_mon -n -1:

> >

> > 

> >

> > Last updated: Sat Oct 29 08:44:14 2011

> >

> > Stack: Heartbeat

> >

> > Current DC: node-0 (a046bd1e-6267-49e5-902d-c87b6ed1dcb9) - partition with

> > quorum

> >

> > Version: 1.0.11-1554a83db0d3c3e546cfd3aaff6af1184f79ee87

> >

> > 3 Nodes configured, unknown expected votes

> >

> > 2 Resources configured.

> >

> > 

> >

> >

> >

> > Node node-0 (a046bd1e-6267-49e5-902d-c87b6ed1dcb9): online

> >

> > master-app-rsc  (lsb:cluster-master) Started

> >

> > failover-ip (ocf::heartbeat:IPaddr2) Started

> >

> > node-app-rsc:0  (lsb:cluster-node) Started

> >

> > Node node-1 (d0f0b2ab-f243-4f78-b541-314fa7d6b346): online

> >

> > node-app-rsc:1  (lsb:cluster-node) Started

> >

> > Node node-2 (85e0ca02-7aa4-45c8-9911-4035e1e6ee15): online

> >

> > node-app-rsc:2  (lsb:cluster-node) Started

> >

> >

> >

> >

> >

> > The problem:

> >

> > After stopping heartbeat service on node-1, if I remove node-1 with command

> > "hb_delnode node-1 && crm node delete node-1", then

> >

> > the clone resource(node-app-rsc:2) running on the node-2 will restart and

> > change to "node-app-rsc:1".

> >

> > You know, the node-app-rsc is my application, and I don't want it to

> > restart.

> >

> > How could I do, Please?

> >

> >

> >

> > Any help will be very appreciated. :)

> >

> >

> >

> >

> >

> > Best Regards,

> >

> >  Fanghao Sha

> >

> >

> >

> >

> >

> >

> >

> >

> > ___

> > Pacemaker mailing list: Pacemaker@oss.clusterlabs.org

> > http://oss.clusterlabs.org/mailman/listinfo/pacemaker

> >

> > Project Home: http://www.clusterlabs.org

> > Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf

> > Bugs: http://bugs.clusterlabs.org

> >

> 

> ___

> Pacemaker mailing list: Pacemaker@oss.clusterlabs.org

> http://oss.clusterlabs.org/mailman/listinfo/pacemaker

> 

> Project Home: http://www.clusterlabs.org

> Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf

> Bugs: http://bugs.clusterlabs.org

 

-- 

: Lars Ellenberg

: LINBIT | Your Way to High Availability

: DRBD/HA support and consulting http://www.linbit.com

 

DRBD® and LINBIT® are registered trademarks of LINBIT, Austria.

 

___

Pacemaker mailing list: Pacemaker@oss.clusterlabs.org

http://oss.clusterlabs.org/mailman/listinfo/pacemaker

 

Project Home: http://www.clusterlabs.org

Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf

Bugs: http://bugs.clusterlabs.org



messages
Description: Binary data
___
Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
http://oss.clusterlabs.org/mailman/listinfo/pacemaker

Project Home: http://www.clusterlabs.org
Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
Bugs: http://bugs.clusterlabs.org

[Pacemaker] [SOLVED] RE: Slave does not start after failover: Mysql circular replication and master-slave resources

2011-12-17 Thread Attila Megyeri
Hi all,

For anyone interested.
I finally made the mysql replication work. For some strange reason there were 
no [mysql] log entries at all neither in corosync.log nor in the syslog. After 
a couple of corosync restarts (?!) [mysql] RA debug/error entries started to 
show up.
The issue was that the slave could not apply the binary logs due to some 
duplicate errors. I am not sure how this could happen, but the solution was to 
ignore the duplicate errors on the slaves, by adding the following line to the 
my.conf:

slave-skip-errors = 1062

I hope this helps to some of you guys as well.

P.S. Did anyone else notice missing mysql debug/info/error entries in corosync 
log as well?

Cheers,
Attila


-Original Message-
From: Attila Megyeri [mailto:amegy...@minerva-soft.com] 
Sent: 2011. december 16. 12:39
To: The Pacemaker cluster resource manager
Subject: Re: [Pacemaker] Slave does not start after failover: Mysql circular 
replication and master-slave resources

Hi Andreas,

The slave lag cannot be high, as the slave was restarted within 1-2 mins and 
there are no active users on the system yet.
I did not find anything at all in the logs.

I will doublecheck if the RA is the latest.

Thanks,

Attila


-Original Message-
From: Andreas Kurz [mailto:andr...@hastexo.com]
Sent: 2011. december 16. 1:50
To: pacemaker@oss.clusterlabs.org
Subject: Re: [Pacemaker] Slave does not start after failover: Mysql circular 
replication and master-slave resources

Hello Attila,

... see below ...

On 12/15/2011 02:42 PM, Attila Megyeri wrote:
> Hi All,
> 
>  
> 
> Some time ago I exchanged a couple of posts with you here regarding 
> Mysql active-active HA.
> 
> The best solution I found so  far was the Mysql multi-master 
> replication, also referred to as circular replication.
> 
>  
> 
> Basically I set up two nodes, both were capable of the master role, 
> and the changes were immediately propagated to the other node.
> 
>  
> 
> But still I wanted to have a M/S approach, to have a RW master and a 
> RO slave - mainly because I prefer to have a signle master VIP where 
> my apps can connect to.
> 
>  
> 
> (In the first approach I configured a two node clone, and the master 
> IP was always bound to one of the nodes)
> 
>  
> 
> I applied the following configuration:
> 
>  
> 
> node db1 \
> 
> attributes IP="10.100.1.31" \
> 
> attributes standby="off"
> db2-log-file-db-mysql="mysql-bin.21" db2-log-pos-db-mysql="40730"
> 
> node db2 \
> 
> attributes IP="10.100.1.32" \
> 
> attributes standby="off"
> 
> primitive db-ip-master ocf:heartbeat:IPaddr2 \
> 
> params lvs_support="true" ip="10.100.1.30" cidr_netmask="8"
> broadcast="10.255.255.255" \
> 
> op monitor interval="20s" timeout="20s" \
> 
> meta target-role="Started"
> 
> primitive db-mysql ocf:heartbeat:mysql \
> 
> params binary="/usr/bin/mysqld_safe" config="/etc/mysql/my.cnf"
> datadir="/var/lib/mysql" user="mysql" pid="/var/run/mysqld/mysqld.pid"
> socket="/var/run/mysqld/mysqld.sock" test_passwd="X"
> 
> test_table="replicatest.connectioncheck" test_user="slave_user"
> replication_user="slave_user" replication_passwd="X"
> additional_parameters="--skip-slave-start" \
> 
> op start interval="0" timeout="120s" \
> 
> op stop interval="0" timeout="120s" \
> 
> op monitor interval="30" timeout="30s" OCF_CHECK_LEVEL="1" \
> 
> op promote interval="0" timeout="120" \
> 
> op demote interval="0" timeout="120"
> 
> ms db-ms-mysql db-mysql \
> 
> meta notify="true" master-max="1" clone-max="2"
> target-role="Started"
> 
> colocation db-ip-with-master inf: db-ip-master db-ms-mysql:Master
> 
> property $id="cib-bootstrap-options" \
> 
> dc-version="1.1.5-01e86afaaa6d4a8c4836f68df80ababd6ca3902f" \
> 
> cluster-infrastructure="openais" \
> 
> expected-quorum-votes="2" \
> 
> stonith-enabled="false" \
> 
> no-quorum-policy="ignore"
> 
> rsc_defaults $id="rsc-options" \
> 
> resource-stickiness="0"
> 
>  
> 
>  
> 
> The setup works in the basic conditions:
> 
> * After the "first" startup, nodes start up as slaves, and
> shortly after, one of them is promoted to master.
> 
> * Updates to the master are replicated properly to the slave.
> 
> * Slave accepts updates, which is Wrong, but I can live with
> this - I will allow connect to the Master VIP only.
> 
> * If I stop the slave for some time, and re-start it, it will
> catch up with the master shortly and get into sync.
> 
>  
> 
> I have, however a serious issue:
> 
> * If I stop the current master, the slave is promoted, accepts
> RW queries, the Master IP is bound to it - ALL fine.
> 
> * BUT - when I want to bring the other node online, it simply
> shows: Stopped (not installed)
> 
>  
> 
> Online: [ db1 db2 ]
> 
>  
> 
> db-ip-master(ocf::heartbeat:IPaddr2):   Started db

Re: [Pacemaker] Linux Cluster Management Console 1.1.0 crm configure show problem

2011-12-17 Thread Rasto Levrinc
On Sat, Dec 17, 2011 at 5:21 AM, Brian Hand  wrote:
> Hello

> I am not sure if this is the right forum or not however I will give it a
> go.  If this isn't the right place, please point me in the right direction

it's one of the right places.

> However, at the moment I am struggling with the crm configure show
> functionality in the LCMC.  To reproduce I click on a node, say my c1
> node, and then click on the right hand side crm configure show.  I see
> in the black console area that the command is executed.   However, since
> the configuration is quite large it looks like the less command ( or
> some kind of pager ) is blocking the flow of all the configuration
> information.  This results in a timeout (you have to wait quite a bit)
> in the LCMC and it generates the java stack trace at the bottom of this
> email.  It is an ugly stack trace to be sure...

yes, you are right, it's the pager. Will be fixed.

I actually put this "crm configure show" button there for development
purposes and wanted to remove it, but since people use it, I just left it
there.

Now I started to think that it could be made editable with apply button
and maybe some other buttons and it would be to crm shell, what gvim
is to vim. :)

Rasto

-- 
Dipl.-Ing. Rastislav Levrinc
rasto.levr...@gmail.com
Linux Cluster Management Console
http://lcmc.sf.net/

___
Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
http://oss.clusterlabs.org/mailman/listinfo/pacemaker

Project Home: http://www.clusterlabs.org
Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
Bugs: http://bugs.clusterlabs.org


Re: [Pacemaker] Linux Cluster Management Console 1.1.0 crm configure show problem

2011-12-17 Thread Arnold Krille
On Saturday 17 December 2011 12:09:43 Rasto Levrinc wrote:
> I actually put this "crm configure show" button there for development
> purposes and wanted to remove it, but since people use it, I just left it
> there.
> Now I started to think that it could be made editable with apply button
> and maybe some other buttons and it would be to crm shell, what gvim
> is to vim. :)

Will the edit act accordingly upon vi(m)-commands? :-P

Arnold


signature.asc
Description: This is a digitally signed message part.
___
Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
http://oss.clusterlabs.org/mailman/listinfo/pacemaker

Project Home: http://www.clusterlabs.org
Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
Bugs: http://bugs.clusterlabs.org


Re: [Pacemaker] Linux Cluster Management Console 1.1.0 crm configure show problem

2011-12-17 Thread Brian Hand

Rasto

First thanks for the quick reply and confirming my suspicions.  It is 
extremely appreciated.


In the meantime before it is fixed.  Is there a way to get crm configure 
show to skip the pager altogether and simply dump the output?


I saw there was a crm options pager setting but it looks like if it 
isn't set it defaults to the OS PAGER variable.  In my setup the PAGER 
variable is not set and looks like less or more is still enforced.


If I can configure up the above this would be an excellent stop gap till 
a better solution is found.


Thanks again.
-B

On 12/17/2011 5:09 AM, Rasto Levrinc wrote:

On Sat, Dec 17, 2011 at 5:21 AM, Brian Hand  wrote:

Hello
I am not sure if this is the right forum or not however I will give it a
go.  If this isn't the right place, please point me in the right direction

it's one of the right places.


However, at the moment I am struggling with the crm configure show
functionality in the LCMC.  To reproduce I click on a node, say my c1
node, and then click on the right hand side crm configure show.  I see
in the black console area that the command is executed.   However, since
the configuration is quite large it looks like the less command ( or
some kind of pager ) is blocking the flow of all the configuration
information.  This results in a timeout (you have to wait quite a bit)
in the LCMC and it generates the java stack trace at the bottom of this
email.  It is an ugly stack trace to be sure...

yes, you are right, it's the pager. Will be fixed.

I actually put this "crm configure show" button there for development
purposes and wanted to remove it, but since people use it, I just left it
there.

Now I started to think that it could be made editable with apply button
and maybe some other buttons and it would be to crm shell, what gvim
is to vim. :)

Rasto



___
Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
http://oss.clusterlabs.org/mailman/listinfo/pacemaker

Project Home: http://www.clusterlabs.org
Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
Bugs: http://bugs.clusterlabs.org


Re: [Pacemaker] Linux Cluster Management Console 1.1.0 crm configure show problem

2011-12-17 Thread Rasto Levrinc
On Sat, Dec 17, 2011 at 8:58 PM, Brian Hand  wrote:

>
> I saw there was a crm options pager setting but it looks like if it isn't
> set it defaults to the OS PAGER variable.  In my setup the PAGER variable is
> not set and looks like less or more is still enforced.
>
> If I can configure up the above this would be an excellent stop gap till a
> better solution is found.

You can set the PAGER env variable to "cat", that should do it.

Rasto

-- 
Dipl.-Ing. Rastislav Levrinc
rasto.levr...@gmail.com
Linux Cluster Management Console
http://lcmc.sf.net/

___
Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
http://oss.clusterlabs.org/mailman/listinfo/pacemaker

Project Home: http://www.clusterlabs.org
Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
Bugs: http://bugs.clusterlabs.org


Re: [Pacemaker] Linux Cluster Management Console 1.1.0 crm configure show problem

2011-12-17 Thread Rasto Levrinc
On Sat, Dec 17, 2011 at 8:22 PM, Arnold Krille  wrote:
> On Saturday 17 December 2011 12:09:43 Rasto Levrinc wrote:
>> I actually put this "crm configure show" button there for development
>> purposes and wanted to remove it, but since people use it, I just left it
>> there.
>> Now I started to think that it could be made editable with apply button
>> and maybe some other buttons and it would be to crm shell, what gvim
>> is to vim. :)
>
> Will the edit act accordingly upon vi(m)-commands? :-P

No, just the JTextArea editor, unless I reimplement the vi(m) in Java. :)

-- 
Dipl.-Ing. Rastislav Levrinc
rasto.levr...@gmail.com
Linux Cluster Management Console
http://lcmc.sf.net/

___
Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
http://oss.clusterlabs.org/mailman/listinfo/pacemaker

Project Home: http://www.clusterlabs.org
Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
Bugs: http://bugs.clusterlabs.org


Re: [Pacemaker] Linux Cluster Management Console 1.1.0 crm configure show problem

2011-12-17 Thread Brian Hand

/facepalm

Why didn't I think of that!

Thanks again.

-B

On 12/17/2011 2:11 PM, Rasto Levrinc wrote:

On Sat, Dec 17, 2011 at 8:58 PM, Brian Hand  wrote:


I saw there was a crm options pager setting but it looks like if it isn't
set it defaults to the OS PAGER variable.  In my setup the PAGER variable is
not set and looks like less or more is still enforced.

If I can configure up the above this would be an excellent stop gap till a
better solution is found.

You can set the PAGER env variable to "cat", that should do it.

Rasto



___
Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
http://oss.clusterlabs.org/mailman/listinfo/pacemaker

Project Home: http://www.clusterlabs.org
Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
Bugs: http://bugs.clusterlabs.org