Adding an mail archive server to a single server ISPConfig setup.

Discussion in 'ISPConfig 3 Priority Support' started by pfaf, Nov 20, 2016.

  1. pfaf

    pfaf New Member HowtoForge Supporter

    Dear Till,

    we have an debian ispconfig single server setup (one mail server).

    We want to setup another mailserver acting as an archive server,
    with the same email accounts (mailboxes) and the same email domains on the same internal lan subnet,
    different server ip and server hostname.

    We are planning to use imapsync to transfer emails which are "expired"
    (i.e. after 6 months or so) from the first mail server to this archive mail server.

    Would you recommend to use a master-slave replication
    or a setup like the master-master scenario omiting the dsync and unison part?

    In case we had a master-slave scenario how could we force the second server
    to be a replica of the master-mail server for mailboxes, aliases, passwords, email domains, etc?

    If we cannot have a replica of the first server then, we are planning to use another mail domain
    for the archive server i.e. the master domain is and the archive domain is
    This means we have to recreate all mailboxes from the master server to the archive server
    and moreover we need to keep the passwords in sync, which is not very convenient.

    Would you think of another solution according to your experience?

    Thank you in advance for your support,

  2. florian030

    florian030 Well-Known Member HowtoForge Supporter

    You can install the archive-server as a slave-server in ispconfig and use the mirror-functions. This keeps the mail-data (password, user, ...) in sync.
    Have you tried doveadm move instead of imapsync?
  3. pfaf

    pfaf New Member HowtoForge Supporter

    Florian thank you for your answer.

    Please correct me if I am wrong:
    In a master-slave setup, I do not want to run a second ISPConfig web interface.
    So the database for ISPConfig (dbispconfig) is common for both servers, no need for an expert setup with dbispconfig1 and dbispconfig2 databases... I am not having glusterfs, nas or any replication for mails or filesystem files for web sites, etc.

    What I understand from your answer is that I only have to go to ISPConfig on the master server and set that the slave server is mirror of the master server. This means that all queries run in the slave server will run as if the server_id = '1' instead of server_id = '2' i.e. in file /etc/dovecot/dovecot-sql.conf , correct?

    Is this the way the option "Is mirror of server" is working?
  4. pfaf

    pfaf New Member HowtoForge Supporter

    OK, I figured it out, as far as for mail settings.

    Once we have enabled the "Is mirror of server" then all mail accounts that are updated and that where initially created on server1 (the master server) are also copied in to the database of server2.

    Only records that have to exist on server2 are copied.

    This is an interesting approach. Server2 (the slave server) may still have its own mail domains, and also authorize users as if it was server1 (the master server).

    Very nice!
  5. florian030

    florian030 Well-Known Member HowtoForge Supporter

    Use the resync-tool for mail to add all existing mail-settings to the slave

Share This Page