Setting up CTDB on OCFS2 and VMs ...

Rowland Penny repenny241155 at gmail.com
Thu Jan 1 14:36:38 MST 2015


On 01/01/15 21:01, Ralph Böhme wrote:
> On Thu, Jan 01, 2015 at 06:51:21PM +0000, Rowland Penny wrote:
>> 5. Configure corosync
>>
>> nano /etc/corosync/corosync.conf
>>
>> Make sure that bindnetaddr is defined and points to your private
>> interface. I set it to 192.168.1.0
>>
>> # Copy the file to the other node.
>> scp /etc/corosync/corosync.conf root at 192.168.0.7:/etc/corosync/
>>
>> # ON BOTH NODES
>> service pacemaker stop  # Stop these in case they were running
>> service corosync stop # Same here
>>
>> nano /etc/default/corosync
>> Change:
>> START=no
>>
>> To:
>>
>> START=yes
>>
>> # now start the cluster
>> service corosync start
>>
>> # Also start it on the other node(s).
>>
>> # Now check the status:
>> root at cluster1:~# crm_mon -1
>> ============
>> Last updated: Mon Dec 15 10:46:20 2014
>> Last change: Mon Dec 15 10:44:18 2014 via crmd on cluster1
>> Stack: openais
>> Current DC: cluster1 - partition with quorum
>> Version: 1.1.7-ee0730e13d124c3d58f00016c3376a1de5323cff
>> 2 Nodes configured, 2 expected votes
>> 0 Resources configured.
>> ============
>>
>> Online: [ cluster1 cluster2 ]
>>
>> If you do not see all the other nodes online, then you have to debug
>> the problem.
>>
>> 6. Configure the Oracle cluster
>>
>> dpkg-reconfigure ocfs2-tools
>> Configuring ocfs2-tools
>> # Would you like to start an OCFS2 cluster (O2CB) at boot time?
>> #
>> # <Yes>
>> #
>> # Name of the cluster to start at boot time:
>> #
>> # ctdbdemo
>>
>> # Create the ocfs2 cluster conf file
>> o2cb_ctl -C -n ctdbdemo -t cluster
>> o2cb_ctl -C -n cluster1 -t node -a number=1 -a
>> ip_address=192.168.1.10 -a ip_port=7777 -a cluster=ctdbdemo
>> o2cb_ctl -C -n cluster2 -t node -a number=2 -a
>> ip_address=192.168.1.11 -a ip_port=7777 -a cluster=ctdbdemo
>>
>> # ON BOTH NODES
>> service corosync stop
>>
>> # Copy files to the other node.
>> scp /etc/default/o2cb  root at 192.168.0.7:/etc/default/
>> scp /etc/ocfs2/cluster.conf  root at 192.168.0.7:/etc/ocfs2/
>>
>> service o2cb start
>> service corosync start
> looks like you're not configuring the DLM service. I thing I posted
> these two links before, here they are again, just in case:
> <http://blog.clusterlabs.org/blog/2012/pacemaker-and-cluster-filesystems/>

OK, the first link is dated 2012 and under option 3, says that 'OCFS2 is 
the only component that hasn’t been updated to support this', I would 
hope by now that ocfs2 has been updated.

> <http://www.hastexo.com/resources/hints-and-kinks/ocfs2-pacemaker-debianubuntu>

That is ok, until I add:

primitive p_o2cb ocf:pacemaker:o2cb \
   op start interval="0" timeout="90" \
   op stop interval="0" timeout="100" \
   op monitor interval="10"

Then when you restart ctdb, both nodes become unhealthy.

Rowland

>
> -Ralph



More information about the samba-technical mailing list