When trying to create a backup of zimbra open source edition 8.0.1+ I ran into issues with data.mdb 'exploding'.
While my /opt/zimbra directory is only about 8GB my backup is around 80GB.
both rsync and copy fail to work properly.
backupldaprsynczimbra
When trying to create a backup of zimbra open source edition 8.0.1+ I ran into issues with data.mdb 'exploding'.
While my /opt/zimbra directory is only about 8GB my backup is around 80GB.
both rsync and copy fail to work properly.
Best Answer
The data.mdb file is actually a thin provisioned 86GB (by default) file.
Rsync and sometimes cp commands will 'explode' the file to it's full size when copying to a backup directory.
This obviously doesn't help if you want to create an offsite backup or if you are limited in resources.
This behavior seems new in 8.0.1
The proper way to prevent this is to split your backup into 3 parts. Below my example backup script (to be executed as root).
Frist Stop zimbra and kill whatever is left.
Next backup the /opt/zimbra directory EXCLUDING the /opt/zimbra/data/ldap directory.
Next convert the ldap files into ldif files with the build in zmslapcat command.
You can choose to first start the server again as this command can be ran while zimbra is running. but just to be sure we get a backup of a frozen environment we'll leave it stopped for now.
This script was tested on zimbra 8.0.1 under ubuntu server 14.04.
It should work on most distributions and versions above 8.0.1