Jump to content
Main menu
Main menu
move to sidebar
hide
Navigation
Main page
Recent changes
Random page
Help about MediaWiki
TetraWiki
Search
Search
Appearance
Create account
Log in
Personal tools
Create account
Log in
Pages for logged out editors
learn more
Contributions
Talk
Editing
GSTN - ZIMBRA MAILBOX CLUSTER
Page
Discussion
English
Read
Edit
View history
Tools
Tools
move to sidebar
hide
Actions
Read
Edit
View history
General
What links here
Related changes
Special pages
Page information
Appearance
move to sidebar
hide
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
[[category:GSTN]] = Zimbra Mailbox Clustering = = Pacemaker: Install = <div style="color:#000000;">Install and Configure Linux High-Availability Cluster tool "Pacemaker".</div> <div style="text-align:center;">mailbox.gstn.org.in</div> <div style="text-align:center;color:#000000;">'''172.18.101.20'''</div> <span style="color:#000000;">|</span> <div style="color:#000000;">+----------------------+ | +----------------------+</div> <span style="color:#000000;">| [ Node01 ] |</span><span style="color:#000000;">172.18.101.18 </span><span style="color:#000000;">|</span><span style="color:#000000;">172.18.101.19 </span><span style="color:#000000;">| [ Node02 ] |</span> <span style="color:#000000;">| </span><span style="color:#000000;">'''gd9109.gstn.org.in'''</span><span style="color:#000000;"> </span><span style="color:#000000;">+----------+----------+ </span><span style="color:#000000;">'''gd9109.gstn.org.in'''</span><span style="color:#000000;"> |</span> <span style="color:#000000;">| | | |</span> <div style="color:#000000;">+----------------------+ +----------------------+</div> == Install Pacemaker like follows on all Nodes. == [root@gd9109 ~]# yum -y install pacemaker pcs [root@gd9109 ~]# systemctl start pcsd [root@gd9109 ~]# systemctl enable pcsd == Set password for cluster admin user == [root@gd9109 ~]# passwd hacluster Changing password for user hacluster. New password: Retype new password: passwd: all authentication tokens updated successfully. == Configure like follows on a Node. == === Establish authorization === [root@gd9109 ~]# pcs cluster auth gd9109.gstn.org.in gd9110.gstn.org.in Username: hacluster Password: gd9109.gstn.org.in: Authorized gd9110.gstn.org.in: Authorized === Configure cluster === [root@gd9109 ~]# pcs cluster setup --name Mailbox-Cluster gd9109.gstn.org.in gd9110.gstn.org.in Shutting down pacemaker/corosync services... Redirecting to /bin/systemctl stop pacemaker.service Redirecting to /bin/systemctl stop corosync.service Killing any remaining services... Removing all cluster configuration files... gd9109.gstn.org.in: Succeeded gd9110.gstn.org.in: Succeeded [[Image:ZIMBRAMAIL1.png |top]] === Start services for cluster === [root@gd9109 ~]# pcs cluster start --all gd9109.gstn.org.in: Starting Cluster... gd9110.gstn.org.in: Starting Cluster... === Enable cluster === [root@gd9109 ~]# pcs cluster enable --all gd9109.gstn.org.in: Cluster Enabled gd9110.gstn.org.in: Cluster Enabled === Show status === [root@gd9109 ~]# pcs status corosync Membership information <nowiki>----------------------</nowiki> Nodeid Votes Name 1 1 gd9109 (local) 2 1 gd9110 [[Image:ZIMBRAMAIL2.png |top]] == Show settings == [root@gd9109 ~]# pcs property list Cluster Properties: cluster-infrastructure: corosync cluster-name: Mailbox-Cluster dc-version: 1.1.13-10.el7-44eb2dd have-watchdog: false last-lrm-refresh: 1471967184 stonith-action: reboot symmetric-cluster: on = Pacemaker: Add Resource = == Set virtual IP address == === IPv4 Resource: === [root@gd9109 ~]# pcs resource create ClusterIP ocf:heartbeat:IPaddr2 ip=172.18.101.20 cidr_netmask=24 op monitor interval=30s === IPv6 Resource: === [root@gd9109 ~]# pcs resource create ClusterIPv6 ocf:heartbeat:IPaddr2 ip=2404:a800:1000:d:7800::14 cidr_netmask=69 op monitor interval=30s == [[Image:ZIMBRAMAIL3.png |top]] == == Install required packages on all Nodes. == [root@gd9109 ~]# yum -y install fence-agents-all lvm2-cluster gfs2-utils == Add required resources. It's OK to set on a node. == [root@gd9109 ~]# pcs resource create dlm ocf:pacemaker:controld op monitor interval=30s on-fail=fence clone interleave=true ordered=true [root@gd9109 ~]# pcs resource create clvmd ocf:heartbeat:clvm op monitor interval=30s on-fail=fence clone interleave=true ordered=true [root@gd9109 ~]# pcs constraint order start dlm-clone then clvmd-clone [root@gd9109 ~]# pcs constraint colocation add clvmd-clone with dlm-clone = Pacemaker: CLVM + GFS2 = == Create volumes on shared storage and format with GFS2. It's OK to set on a node. On this example, it is set on sdb and create partitions on it and set LVM type with fdisk. == [root@gd9109 ~]# pvcreate /dev/vdb1 [root@gd9109 ~]# vgcreate -cy vg_cluster /dev/vdb1 [root@gd9109 ~]# lvcreate -l100%FREE -n lv_cluster vg_cluster [root@gd9109 ~]# mkfs.gfs2 -p lock_dlm -t ha_cluster:gfs2 -j 2 /dev/vg_cluster/lv_cluster == Add shared storage to cluster resource. It's OK to set on a node. == [root@gd9109 ~]# pcs resource create fs_gfs2 Filesystem device="/dev/vg_cluster/lv_cluster" directory="/opt/zimbra" fstype="gfs2" options="noatime,nodiratime" op monitor interval=10s on-fail=fence clone interleave=true [root@gd9109 ~]# pcs constraint order start clvmd-clone then fs_gfs2-clone [root@gd9109 ~]# pcs constraint colocation add fs_gfs2-clone with clvmd-clone [root@gd9109 ~]# pcs constraint show Location Constraints: Ordering Constraints: start dlm-clone then start clvmd-clone (kind:Mandatory) start clvmd-clone then start fs_gfs2-clone (kind:Mandatory) start fs_gfs2-clone then start fs_bkp (kind:Mandatory) start fs_gfs2-clone then start Zimbra_Service (kind:Mandatory) Colocation Constraints: clvmd-clone with dlm-clone (score:INFINITY) fs_gfs2-clone with clvmd-clone (score:INFINITY) = Create Fence through rhev manager: = [root@gd9109 ~]# pcs stonith create rhevfence fence_rhevm stonith-timeout=120 pcmk_host_map="GD9109.gstn.org.in:GD9109 GD9110.gstn.org.in:GD9110" ipaddr=172.18.102.22 ssl=1 login=cluster_admin passwd=XXXXXXX [[Image:ZIMBRAMAIL4.png |top]]
Summary:
Please note that all contributions to TetraWiki may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
TetraWiki:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)