- master: add these lines to the imapd.conf:
sync_log: yes
sync_log_channels: backup
backup_sync_host: my.backupserver.local
backup_sync_port: csync
backup_sync_try_imap: no
backup_sync_authname: cyrus
backup_sync_password: somepassword
backup_sync_repeat_interval: 1
-
master: restart cyrus-imapd
-
replica: setup imapd.conf with this content:
admins: cyrus
configdirectory: /var/lib/imap
proc_path: /run/cyrus/proc
sasl_pwcheck_method: auxprop
sasl_mech_list: PLAIN LOGIN CRAM-MD5 DIGEST-MD5
backup_db: twoskip
backup_db_path: /var/lib/imap/backups.db
backup_staging_path: /var/tmp/imap/
backup_retention_days: 30
backuppartition-default: /var/spool/imap/
backup_compact_minsize: 512
backup_compact_maxsize: 10240
backup_compact_work_threshold: 1
restore_authname: cyrus
restore_password: somepassword
- replica: setup cyrus.conf with this content:
START {
recover cmd="ctl_cyrusdb -r"
}
SERVICES {
backupd cmd="backupd" listen="csync" prefork=0
}
EVENTS {
checkpoint cmd="ctl_cyrusdb -c" period=30
compact cmd="ctl_backups compact -A" at=0400
}
- replica: setup admin user
echo "somepassword" | saslpasswd2 -c -p cyrus
chown cyrus:mail /etc/sasldb2
-
replica: start cyrus-imapd
-
master: do an initial sync
sync_client -n backup -l -v -u user1
sync_client -n backup -l -v -u user2
...
- master: add this to the cyrus.conf:
START {
backup cmd="sync_client -r -n backup -l -v"
}
SERVICES {
syncserver cmd="sync_server" listen="csync"
}
- master: restart cyrus-imapd