Adding EXIM MTA support for ISPConfig 3

Discussion in 'Tips/Tricks/Mods' started by -= AD =-, Apr 1, 2011.

  1. -= AD =-

    -= AD =- New Member

    Hi,

    Tested on OS: CentOS 5, Ubuntu-server 10.04 (LTS)
    Tested with ISPConfig version: 3.0.3.3

    attached is exim.conf file for exim MTA which provides full exim support for ISPConfig 3.

    Here are some quick steps how to apply this assuming you already have ISPConfig 3 + postfix running.


    ========== CentOS 5 ==========
    1) Remove postfix (copy-paste into root shell):
    Code:
    yum remove postfix
    2) Add atrpms repo for more recent exim build than a default Centos repo has (copy-paste into root shell):
    Code:
    cat > /etc/yum.repos.d/atrpms.repo << ATREPO
    [atrpms]
    name=Red Hat Enterprise Linux \$releasever - \$basearch - ATrpms
    baseurl=http://dl.atrpms.net/el\$releasever-\$basearch/atrpms/stable
    failovermethod=priority
    enabled=0
    gpgcheck=1
    gpgkey=http://ATrpms.net/RPM-GPG-KEY.atrpms
    ATREPO
    
    3) Install exim with mysql support (copy-paste into root shell):
    Code:
    yum --enablerepo=atrpms install exim exim-mysql
    4) Update dovecot.conf to create auth socket exim can access (copy-paste into root shell):
    Code:
    cp /etc/dovecot.conf /etc/dovecot.conf_backup
    sed -e "s#/var/spool/postfix/private/auth#/var/spool/dovecot/auth#" -e "s#user = postfix#user = exim#" -e "s#group = postfix#group = exim#" -i /etc/dovecot.conf
    mkdir /var/spool/dovecot ; chown exim:exim /var/spool/dovecot
    /etc/init.d/dovecot restart
    5) Upload attached exim.conf.gz file to your server, unpack it with "gzip -d" command, copy unpacked file into /etc/exim/exim.conf

    6) Edit /etc/exim/exim.conf and update it with your Mysql DB credentials. Just run this command in your root shell in order to see your current ispconfig mysql login info:
    Code:
    grep ^connect /etc/dovecot-sql.conf
    7) Restart exim (copy-paste into root shell):
    Code:
    /etc/init.d/exim restart
    ========== Ubuntu-server 10.04 LTS ==========
    1) Remove postfix (copy-paste into root shell):
    Code:
    apt-get remove postfix
    2) Install exim4 with mysql support (copy-paste into root shell) :
    Code:
    apt-get install exim4-daemon-heavy
    3) Update dovecot.conf to create auth socket exim can access (copy-paste into root shell):
    Code:
    cp /etc/dovecot/dovecot.conf /etc/dovecot/dovecot.conf_backup
    sed -e "s#/var/spool/postfix/private/auth#/var/spool/dovecot/auth#" -e "s#user = postfix#user = Debian-exim#" -e "s#group = postfix#group = Debian-exim#" -i /etc/dovecot/dovecot.conf
    mkdir /var/spool/dovecot
    chown Debian-exim: /var/spool/dovecot
    /etc/init.d/dovecot restart
    4) Upload attached exim.conf.gz file to your server, unpack it with "gzip -d" command, copy unpacked file into /etc/exim4/exim4.conf

    5) Edit /etc/exim4/exim4.conf and update it with your Mysql DB credentials. Just run this command in your root shell in order to see your current ispconfig mysql login info:
    Code:
    grep ^connect /etc/dovecot/dovecot-sql.conf
    6) Create Exim SSL certificate and key (copy-paste into root shell and follow instructions):
    Code:
    /usr/share/doc/exim4-base/examples/exim-gencert
    7) Update exim4.conf with new TLS cert and key files since attached exim.conf has TLS options actual for CentOS (copy-paste into root shell):
    Code:
    sed -e "s#/etc/pki/tls/certs/exim.pem#/etc/exim4/exim.crt#" -e "s#/etc/pki/tls/private/exim.pem#/etc/exim4/exim.key#" -i /etc/exim4/exim4.conf
    8) Restart exim (copy-paste into root shell):
    Code:
    /etc/init.d/exim4 restart
    ================================

    Any bug reports are welcome :)
     

    Attached Files:

    Last edited: May 17, 2011
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    Thanks for the Exim Config. I will add the config to SVN.

    Not sure if we will be able to add official Exim support as this means that there has to be a active maintainer who implements and tests exim support for all supported Linux distributions (Debian, Ubuntu, Fedora, Centos and Dovecot) for every new ISPConfig release.
     
  3. -= AD =-

    -= AD =- New Member

    I see.

    There should be no differences in Exim config for different Linux distributions, the only possible difference I can think of is exim.conf location. Will check this exim.conf on Ubuntu+ISPConfig3 and post results here.
     
  4. -= AD =-

    -= AD =- New Member

    Tested it under Ubuntu - works fine. Some ubuntu-related notes:

    1. Exim config file is "/etc/exim4/exim4.conf"

    2. You should install "exim4-daemon-heavy" package which includes mysql support
     
  5. -= AD =-

    -= AD =- New Member

    I've tested this exim.conf with ispconfig 3.0.3.3 and updated instructions in the initial post (added ubuntu how-to).
     
  6. -= AD =-

    -= AD =- New Member

    exim.conf.gz attachment has been updated
    Added support for "cc" field in "mail_user" table (new router "cc_router").
     
  7. hauke

    hauke New Member

    Running well? (Exim 4, ispconfig3, centos6.4)

    Latest Exim 4 running well with this config, latest ispconfig 3 and centos 6.4?
    I'm Happy about every hint. thx :)
     
  8. MaxT

    MaxT Member

    Hi,
    I rescue this thread to ask if there is any problem installing Exim and managing the email accounts with ISCPconfig.
    No issues?
     
  9. florian030

    florian030 ISPConfig Developer ISPConfig Developer

    Exim is not support. But can you can change the code to get support from exim - see #2
     
  10. MaxT

    MaxT Member

    my doubt is, if we can manage mailboxes and mail-accounts from ISPConfig with Exim installed.

    thx!
     
  11. florian030

    florian030 ISPConfig Developer ISPConfig Developer

    I did not use exim but you can try the config posted above in 2011.
     
  12. MaxT

    MaxT Member

    that solution is quite old.. Thanks anyway. I will learn Postfix, less problematic :D
     

Share This Page