… or: How do I get my own mail and communication server in just 30 minutes? This question came to me when my daughter got her smartphone and now asked for an email address. So I needed something easy to set up (I’m not a Linux crack) and usable via web and smartphone.
Kopano is an email & calendaring solution. As a user, I work with a WebApp that shows me my emails, appointments, contacts, tasks and so on. I can even integrate cloud storage to share my photos more quickly, for example. When I’m on the road, I always have my emails, appointments and contacts with me on my smartphone. And because I set it up together with my daughter, I can also see who she’s texting with or put an appointment in her calendar, which her smartphone then reminds her of.
Kopano WebApp – The basic setup
Kopano is not that difficult to set up. Since, as I said, I’m not an absolute Linux crack, I simply used the distribution from Univention. The basic version is free of charge and can be downloaded here after a short and painless registration as a ISO image for burning onto a DVD or for direct start-up in a virtual server.
Following the recommendation of a colleague, I then rented a small VPS server from netcup. For a small price, you get quite a lot of performance here. Above all, you can upload your own ISO image in the admin interface to install the operating system – with the Univention image, you can already add up 1&1 (sorry for the pun ;-)).
The registration at netcup took 5 minutes. A few minutes after receiving the order confirmation, an employee called and matched my mobile number and address. The virtual server was then ready for use 20 minutes later. The upload of the Univention image via the netcup FTP server took less than 2 minutes. And the installation could already begin. I was able to follow and control this via a virtual VNC console. The Univention system asks for a few data. Among other things, the system name and the domain should be entered correctly. Only 10 minutes later I was sitting in front of my own Univention server, could close the VNC console and access it via web interface instead.
Set up Kopano – Univention App Center with Kopano apps
Now all I needed was the communication component. To set this up, I called up the App Center from the portal of my Univention server. As you are used to from your smartphone, you can select the apps you want to work with from about 50 with a mouse click. These apps are then not only installed, but are also pre-configured and integrated into the interface for user administration.
There are four Kopano apps, three of which can be used non-commercially: Kopano Core contains all the necessary basic components such as the database or modules for sending and receiving e-mails. The Kopano WebApp is the interface shown in the screenshot above, which I now work with every day. The Z-Push app for Kopano lets me connect our smartphones. I also installed Fetchmail, which allows me to retrieve emails from other providers we use, such as G-Mail, via POP3 or IMAP.
With two to three clicks per app, these are installed and running. And off we go!
Univention: Creating users
The Univention portal has a conspicuous button called “User”. If you click on it, you can create and manage them ;-). As little surprised as I was by this, I found the first question, whether I would like to create a “Kopano Account”, to be great. When I answered in the affirmative, only a few standard entries separated me from my first executable user.
The great thing is that everything that is installed in terms of apps really comes together here. I can enter as many email aliases as I want in the advanced settings. As soon as I clicked on “Save”, an email could be sent to this address via SMTP. Here I could also use the menu item “Mail retrieval from external servers” via POP3 to catch the mails that were still accumulating on my G-Mail account.
On my smartphone, I simply created a new “Microsoft Exchange Account”. On Android, you do this under “Settings” -> “Accounts” -> “Add” -> “Exchange”. There I entered my e-mail address and, because the auto-discovery feature had not yet been set up, the name of my Univention server, my user name and my password. Voilà – my emails, contacts and appointments landed on my smartphone.
Finally, a little fine-tuning
To ensure that emails reach me quickly enough, I don’t want to retrieve them via POP3 or IMAP every X minutes. That’s why I entered the Univention server as the “MX record” for my mail domain with my provider. It took about 48 hours for the last DNS server to understand this change. Since then, “Push Mail” really does what the name promises.
To avoid ending up on the blacklists of SPAM hunters, I then set up a secure e-mail relay via my provider. With this, my server registers with the provider and sends all e-mails via this provider. This was the only setting for which I really had to access a console. In the Univention portal, I started the SSH service under “System” -> “System Services” and then connected as “Administrator” via SSH. There, the command “ucr” sets variables that the portal does not display:
ucr set mail/relayauth=yes
ucr set mail/relayhost=
then I created the file /etc/postfix/smtp_auth with the editor of my choice:
<provider’s SMTP server> :
… and activated it for my own mail server:
postmap hash:/etc/postfix/smtp_auth
service postfix restart
You can test the whole thing by, for example, using tail -f /var/log/mail.log to observe the log file of Postfix while sending an e-mail. If a line with the content ‘[…] postfix/smtp […] to=, relay= […] status=sent […]’ appears there, then everything has worked.