Kolab 3.3 Single-Domain Setup on CentOS 7


After a lot of reading and some trial-and-error, I’ve figured out a way to reproducible install Kolab 3.3 on CentOS 7 with multi-domain support. Most information can be found in the official documentation, however some parts are not that easy to understand for a Kolab noob.

I won’t go into too much details here, so it will be mostly a step-by-step thing without a lot of explanation. You really should not use this document as your only source of information. At least read through the official documentation as well. Also you should feel confident with Linux admin stuff – otherwise Kolab might not be the best choice as it is not an of-the-shelf solution.

In this document we will use the following hosts and domains. Replace them with your own.

  • Hostname: mail.skolar.de
  • Management domain: skolar.de
  • Primary hosted domain: kodira.de
  • Alias for primary hosted domain: tourschall.com
  • We could go on with a secondary hosted domain, but works exactly like the primary hosted domain, so we won’t go there…

Let’s start with a fresh minimal CentOS 7 install where you are root.

First we disable SE-Linux and the firewall. You should re-enable that later, but for now we don’t won’t both to get into our way:

# Check status of SE-Linux
sestatus
# Temporarily disable it
setenforce 0
# Stop firewall
systemctl stop firewalld
# Disable firewall (dont't start on next boot)
systemctl disable firewalld

To permanently disable SE-Linux edit /etc/selinux/config (I recommend you do this now)

Set a valid host name (needs to be resolvable via DNS)

echo "mail.skolar.de" > /etc/hostname

Add Kolab repositories and GPG keys

rpm -Uhv http://ftp.uma.es/mirror/epel/beta/7/x86_64/epel-release-7-1.noarch.rpm
cd /etc/yum.repos.d/
wget http://obs.kolabsys.com/repositories/Kolab:/3.3/CentOS_7/Kolab:3.3.repo
wget http://obs.kolabsys.com/repositories/Kolab:/3.3:/Updates/CentOS_7/Kolab:3.3:Updates.repo
gpg --search devel@lists.kolab.org
# Do it again, for me it always just worked the second time
gpg --search devel@lists.kolab.org
gpg --export --armor devel@lists.kolab.org > devel.asc
rpm --import devel.asc
rm devel.asc

Install Kolab (including dependencies)

yum install kolab

The next command will start the various services like postfix and apache and should also start MariaDB (which is a replacement for MySQL). Due to bug #3877 it won’t, so we have to start MariaDB manually.

systemctl enable mariadb
systemctl start mariadb

Now start the Kolab setup process. It will ask you many password, most of them you can just leave as they are, but pay attention to the password for “Directory Manager”. Either remember the one setup generated or type in your own. You’ll need that password later on quite often.

setup-kolab

Besides the passwords the right answers for me have been:

Domain -> skolar.de
What MySQL server are we setting up? -> 2: New MySql server
Timezone -> Europe/Berlin

Now might be a good time to reboot and see if all the services are starting up successfully. If you do, please make sure SE-Linux is turned off permanently.

Great, you should now be able to login to the web admin. The URL and the credentials are as follows:

http://<yourserver>/kolab-webadmin
User: cn=Directory Manager
Password: The password used in setup-kolab

You should be able to create a new Kolab user and log into webmail using that new user. But because of bug #3565 you’re incoming mail is not properly scanned. Do the following to resolve that issue:

vi /etc/amavisd/amavisd.conf
# Change that line
\&ask_daemon, ["CONTSCAN {}\n", "/var/spool/amavisd/clamd.sock"],
# To look like this
\&ask_daemon, ["CONTSCAN {}\n", "/var/run/clamd.amavisd/clamd.sock"],
# Save, close and restart amavisd
systemctl restart amavisd

This should be all for a single-domain install. You should be able to send and receive mail using the web frontend or dedicated IMAP clients.

That’s all for part 1. Have a look at part 2 where we’re extending this setup to support multiple domains.