Tips Zimbra: Migrating Zimbra With HashBackup

This tutorial will show you how to migrating your zimbra servers into new server with HashBackup. This tutorial have been tested with Zimbra 8.7.1.

HashBackup is the unique tool, for me. This is amazing tools. Your data will be compressed and encrypted and it’s secure because prevent anyone to open your data. Beside it, i want to make HashBackup as a Migration Tools for Zimbra. I think it is possible to migrating zimbra with HashBackup. Because it will backup your data without changing the permission and owner. If you migrating zimbra with rsync, you must run zmfixperms  command to fix the permission. So let’s check this out.


ZCS Server 1
IP Address :
Hostname :
OS : Ubuntu 14.04
ZCS Server 2
IP Address :
Hostname :
OS : Ubuntu 14.04


ZCS Server 1 is the primary zimbra server. Zimbra have been installed in this server and running well and ZCS Server 2 is the fresh server, just OS, Zimbra not installed. This tutorial have been tested with Single Server. Maybe it can reference by Multi Server.

I will show you step by step configuration, let start from ZCS Server 1 and then to ZCS Server 2.

ZCS Server 1 Configuration

  • Install HashBackup on your server, you can download latest version at here. I’m using 1709 version. Run this below command :
cd /srv
wget -c
tar -zxvf hb-1709-linux-64bit.tar.gz
cp hb-1709/hb /usr/local/bin
hb init -c /zimbra
  • Stop Zimbra service. If your zimbra is production server, ensure it didn’t excecute on office hour. You can execute on after office hour.
su - zimbra
zmcontrol stop
  • Backup your data with HashBackup and rsync into new server
hb backup -c /zimbra /opt/zimbra
hb backup -c /zimbra /opt/zimbra
rsync -avhHP --progress /zimbra root@

Run hb backup command twice, because it will backup incremental file or your remains data.

ZCS Server 2 Configuration

Now, let’s move to ZCS Server 2. In this server you have to install zimbra as usual and before installing, ensure your hostnamehosts, DNS Server configuration file are same with ZCS Server 1. In /etc/hosts only IP Address is different like this :       localhost  mail
  • Install HashBackup in ZCS Server 2, you can follow the tutorial at ZCS Server 1. But, don’t run the last command (hb init -c /zimbra) :
cd /srv
wget -c
tar -zxvf hb-1709-linux-64bit.tar.gz
cp hb-1709/hb /usr/local/bin
  • Now, If your configuration have been correct. Install Zimbra as usual with “software only” installation. Run this command in zimbra binary software ./ -s . (Ensure your Zimbra Binary for installation same with ZCS Server 1. If ZCS Server 1 use Zimbra 8.7 you must install Zimbra 8.7 in ZCS Server 2.
  • After installation has done, kill all zimbra process. And rename Zimbra Folder.
pkill -9 zimbra
mv /opt/zimbra /opt/backup-zimbra
  • Finally, if rysnc process have been done on ZCS Server 1. Now you can restore it, run the following command :
cd /opt
hb get -c /zimbra /opt/zimbra
  • Wait for restore process, and tadaaa. Start Zimbra Service
su - zimbra
zmcontrol start

After Migrating

After Migrating zimbra, you must check one by one configuration, there are some different configuration between old server with the new server. Like Trusted Network or etc. If you want to change trusted network you can run this following command as zimbra user: zmprov ms `zmhostname` zimbraMtaMyNetworks " your-zcs-ip/32" . Or you can change it via zimbra admin. Search it on google :-D.

Error Messages

Below is the error message i have found, this error could happen in your unlucky/bad days :-D. Maybe, this workaround can help you a little. If you found another error message, you can ask at the below comment posts.

Logswatch Is Not Running

Run this command as root user:

su - zimbra -c "zmloggerctl restart"
service rsyslog restart

Zimbra Admin Service Not Running But Console Running

Run this following command as zimbra user :

zmloggerctl stop
zmloggerctl start
zmlogswatchctl restart
/opt/zimbra/libexec/zmstatuslog > /dev/null 2>&1

Restart rsyslog service and restart zimbra service, run this following command as root user :

service rsyslog restart
su - zimbra -c 'zmcontrol restart'

Okay, if you find problem, don’t hesitate to comment. Hope this Helpful, Assalamualaikum 🙂

4 thoughts on “Tips Zimbra: Migrating Zimbra With HashBackup

  1. Hi
    After install CentOS 7.3 and Zimbra 8.71 as New server by run ./ -s, when start Zimbra, the system ask sudo Password.
    How to resolve this issue ?

    Thank you

Leave a Reply