Jump to content

Newsnation BSP ImplementationS

From TetraWiki

Auto-generated from the uploaded PDF Newsnation_BSP_ImplementationS.pdf. This is an extracted-text rendering for searchability; see the original PDF for exact formatting, diagrams, tables, and images.


Newsnation ZIMBRA MIGRATION


   1.​ They have two servers with a DRBD cluster setup (OLD SETUP ZIMBRA
       OPENSOURCE)

      192.168.1.2 node1.newsnation.in
      192.168.1.3 node2.newsnation.in

      I have stopped the DRBD services on node 2, then formatted node 2 and
      installed Rocky Linux 8


    2.​ Install zimbra NE 10.1.16
Link -
https://zimbra.github.io/documentation/zimbra-10/single-server-install.html#Installing
_Zimbra_Collaboration_Software


   3.​ Create business COS and assign as default COS, then activate license

zmprov cc Business zimbraFeatureMAPIConnectorEnabled FALSE
zimbraFeatureMobileSyncEnabled FALSE zimbraArchiveEnabled FALSE
zimbraFeatureConversationsEnabled FALSE
zimbraFeatureTaggingEnabled FALSE zimbraAttachmentsIndexingEnabled
FALSE zimbraFeatureViewInHtmlEnabled FALSE
zimbraFeatureGroupCalendarEnabled FALSE zimbraFreebusyExchangeURL
FALSE zimbraFeatureSharingEnabled FALSE zimbraFeatureTasksEnabled
FALSE zimbraFeatureBriefcasesEnabled FALSE
zimbraFeatureSMIMEEnabled FALSE zimbraFeatureVoiceEnabled FALSE
zimbraFeatureManageZimlets FALSE zimbraFeatureCalendarEnabled
FALSE zimbraFeatureGalEnabled TRUE

Zmlicense -a <license key>


   4.​ Create users via backend using zmprov ca user@exmaple.com passwd

   5.​ Set the password to the same as on the old server using the command below


User list = /tmp/user_passwords2

Password list = /tmp/user_passwords3


while read i; do hash=$(zmprov -l ga "$i" userPassword | grep "^userPassword:" |
sed 's/userPassword: //'); echo "ma $i userPassword '$hash'" >>
/tmp/user_passwords3; done < /tmp/user_passwords2


   6.​ Migrate data via IMAPSYNC

for i in `cat /root/imap/user1`
do
imapsync --syncinternaldates --subscribe --nosyncacls --host1 192.168.1.2 --user1 $i
--authuser1 tetra_test@newsnation.in --password1 supp0rt@123 --host2
192.168.1.3 --user2 $i --authuser2 admin@newsnation.in --password2 supp0rt@123
-authmech1 PLAIN -authmech2 PLAIN --tmpdir /user-cache/ --addheader
done


   7.​ Live node2 and then format Node 1 (Install Rocky Linux 8)

   8.​ Configure zimbra packages via (./install.sh -s)

   9.​ Move zimbra dir via mv /opt/zimbra /zimbra-old/zimbra

  10.​Install DRBD and sync both server disk
DRBD configuration below

live - node2.newsnation.in - DRBD configured -- need to change node4 to node1 and
confugure drbd in node1

[root@node2 ~]# lsblk
NAME           MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
sda           8:0 0 465.7G 0 disk
├─sda1            8:1 0 2G 0 part /boot
└─sda2            8:2 0 463.7G 0 part
  ├─rl-root    253:0 0 455.7G 0 lvm /
  └─rl-swap      253:1 0 8G 0 lvm [SWAP]
sdb           8:16 0 4.6T 0 disk

├─sdb1             8:17 0 1M 0 part
├─sdb2             8:18 0 2G 0 part
└─sdb3             8:19 0 4.6T 0 part
  └─vg_node2-lv_drbd 253:2 0 4.6T 0 lvm
   └─drbd0        147:0 0 4.6T 0 disk /opt
sdd             8:48 0 1.8T 0 disk
└─sdd1             8:49 0 1.8T 0 part
[root@node2 ~]# df -h
Filesystem       Size Used Avail Use% Mounted on
devtmpfs         7.7G 0 7.7G 0% /dev
tmpfs          7.7G 0 7.7G 0% /dev/shm
tmpfs          7.7G 750M 7.0G 10% /run
tmpfs          7.7G 0 7.7G 0% /sys/fs/cgroup
/dev/mapper/rl-root 456G 8.7G 447G 2% /
/dev/sda1        2.0G 223M 1.8G 11% /boot
tmpfs          1.6G 0 1.6G 0% /run/user/0
/dev/drbd0       4.6T 2.6T 1.8T 60% /opt
/dev/sdc1        1.8T 1.4T 355G 80% /backup
tmpfs          1.6G 0 1.6G 0% /run/user/992
[root@node2 ~]#

[root@node2 ~]# cat /etc/drbd.d/main.res
resource main {

protocol C;

startup { wfc-timeout 0; degr-wfc-timeout 120; }

disk { on-io-error detach; }

on node2.newsnation.in {

device /dev/drbd0;

disk /dev/vg_node2/lv_drbd;

meta-disk internal;

address 10.0.0.4:7788;

}

on node4.newsnation.in {

device /dev/drbd0;

disk /dev/vg_node1/lv_drbd;

meta-disk internal;

address 10.0.0.10:7788;

}
[root@node2 ~]#

secondary - node1.newsnation .in


[root@node1 ~]# parted /dev/sdb --script mklabel gpt
[root@node1 ~]# parted /dev/sdb --script mkpart primary 0% 100%
[root@node1 ~]# lsblk
NAME        MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
sda        8:0 0 465.7G 0 disk
├─sda1        8:1 0 2G 0 part /boot
└─sda2        8:2 0 463.7G 0 part
  ├─rl-root 253:0 0 455.7G 0 lvm /
  └─rl-swap 253:1 0 8G 0 lvm [SWAP]
sdb        8:16 0 4.6T 0 disk
└─sdb1        8:17 0 4.6T 0 part
[root@node1 ~]#


[root@node1 ~]# parted /dev/sdb --script mklabel gpt
[root@node1 ~]# parted /dev/sdb --script mkpart primary 0% 100%
[root@node1 ~]# lsblk
NAME        MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
sda        8:0 0 465.7G 0 disk
├─sda1        8:1 0 2G 0 part /boot
└─sda2        8:2 0 463.7G 0 part
  ├─rl-root 253:0 0 455.7G 0 lvm /
  └─rl-swap 253:1 0 8G 0 lvm [SWAP]
sdb        8:16 0 4.6T 0 disk
└─sdb1        8:17 0 4.6T 0 part
[root@node1 ~]# pvcreate /dev/sdb1
  Physical volume "/dev/sdb1" successfully created.
[root@node1 ~]#
[root@node1 ~]# vgcreate vg_node1 /dev/sdb1

  Volume group "vg_node1" successfully created
[root@node1 ~]# lvcreate -n lv_drbd -l 100%FREE vg_node1
WARNING: xfs signature detected on /dev/vg_node1/lv_drbd at offset 0. Wipe it? [y/n]: y
  Wiping xfs signature on /dev/vg_node1/lv_drbd.
  Logical volume "lv_drbd" created.
[root@node1 ~]# lvs
  LV    VG       Attr    LSize Pool Origin Data% Meta% Move Log Cpy%Sync Convert
  root rl     -wi-ao---- <455.73g
  swap rl       -wi-ao---- 8.00g
  lv_drbd vg_node1 -wi-a----- <4.55t
[root@node1 ~]# vgs
  VG      #PV #LV #SN Attr VSize VFree
  rl     1 2 0 wz--n- <463.73g 0
  vg_node1 1 1 0 wz--n- <4.55t 0
[root@node1 ~]# pvs
  PV       VG      Fmt Attr PSize PFree
  /dev/sda2 rl      lvm2 a-- <463.73g 0
  /dev/sdb1 vg_node1 lvm2 a-- <4.55t 0
[root@node1 ~]#


we cannot make anything in node2 because it is live server as of now

[root@node2 ~]# drbdadm status
main role:Primary
  disk:UpToDate open:yes
  node4.newsnation.in connection:Connecting

[root@node2 ~]# cat /proc/drbd
version: 9.3.1 (api:2/proto:118-124)
GIT-hash: 9eba01aed618878de06ea17f17deddf96ac54d42 build by mockbuild@,
2026-03-14 14:11:47
Transports (api:21): tcp (9.3.1)
[root@node2 ~]#

------------------------------------------

1. Update config on node2
Edit:
vi /etc/drbd.d/main.res
Replace this block:
on node4.newsnation.in {device /dev/drbd0;disk /dev/vg_node1/lv_drbd;meta-disk
internal;address 10.0.0.10:7788;}
with:
on node1.newsnation.in {device /dev/drbd0;disk /dev/vg_node1/lv_drbd;meta-disk
internal;address <NODE1-IP>:7788;}
Use actual node1 replication IP.
DO NOT change anything else.

2. Copy same config to node1
On node1:
vi /etc/drbd.d/main.res
Paste identical content.

3. Verify hostname resolution
On BOTH nodes:
ping node1.newsnation.inping node2.newsnation.in

4. Create metadata ONLY on node1
IMPORTANT:
ONLY on node1:
drbdadm create-md main
Do NOT run this on node2.

5. Bring DRBD up on node1
On node1:
drbdadm up main
Check:
drbdadm status
Likely shows waiting for connection.

6. Reload config safely on node2
THIS is the important production-safe command.
On node2:
drbdadm adjust main
This reloads configuration dynamically without stopping DRBD.
No unmount required.

7. Connect if needed
Usually automatic.
If not:
drbdadm connect main

8. Verify replication started
On node2:
drbdadm status
Expected:
main role:Primary disk:UpToDate node1.newsnation.in role:Secondary
replication:SyncSource
On node1:
role:Secondaryreplication:SyncTarget

9. Monitor sync
watch cat /proc/drbd
or:
watch drbdadm status

IMPORTANT
DO NOT:


run mkfs


mount /dev/drbd0 on node1


run create-md on node2


run drbdadm down main on node2


Recommended check before adjust
After editing config on BOTH nodes, run:
drbdadm dump all
If no syntax errors → proceed.

Expected final healthy state
On node2:
role:Primarydisk:UpToDatepeer-disk:UpToDate
On node1:
role:Secondarydisk:UpToDatepeer-disk:UpToDate


Zurt Installation

https://wiki.zimbra.com/images/f/f2/ZURT_GUIDE_-_1.0.7.pdf