Enabling ActiveSync on Plesk on Linux
Source: | DataSource |
---|---|
Language: | English |
Topic: | Linux |
SubTopic: | Plesk |
Last Edit By: | DochyJP |
LastEdit: | 2022-04-29 |
Document type: | Documentation |
Status: | Active |
Access: | free |
Download this page as PDF
I have activated ActiveSync on my Ubuntu server and it works pretty well. Now I want to share my experience and maybe get some new suggestions.
Thanks to everyone who helped to achieve it, I learned a lot from many posts.
- Choose a domain and an email address for administration. It should be a domain with SSL (there are even free SSL providers); this is not necessary but better.
- Edit in the file /etc/psa-webmail/horde/horde/conf.php these lines:
$conf['auth']['admins'] = array('your-admin-email-address'); $conf['activesync']['enabled'] = true; $conf['activesync']['version'] = '14.1';
- In Plesk Panel go to your main domain Subscription > Websites & Domains > Web Server Settings. Activate Process PHP by nginx and put following code into both: Additional directives for HTTP and Additional directives for HTTPS:
# Enable ActiveSync <Directory /usr/share/psa-horde> Order allow,deny Allow from all </Directory> RewriteEngine On RewriteRule ^/Microsoft-Server-ActiveSync /usr/share/psa-horde/rpc.php [L,QSA] Alias /autodiscover/autodiscover.xml /usr/share/psa-horde/rpc.php Alias /Autodiscover/Autodiscover.xml /usr/share/psa-horde/rpc.php Alias /AutoDiscover/AutoDiscover.xml /usr/share/psa-horde/rpc.php # End Enable ActiveSync
- Now in Plesk go to Websites & Domains > PHP Settings and set max_execution_time to custom value 3000 (it should be more than the value of $conf['activesync']['ping']['heartbeatmax'] in your horde.conf)
If you do this, Plesk automatically sets proxy_read_timeout 3000; in your nginx.conf, which is important.
- Go to Tools & Settings > Mail Server Settings and set Maximum number of connections for a user per IP address to a higher value, e.g. 40.
I had to raise this value to prevent an error in mail.err: courier-imapd: Maximum connection limit reached for ::1 (Horde makes many local connections to IMAP and it stops to authenticate when the limit is met, your mail client can't login and asks for a password.)
If you use Courier you can alternatively edit the file /etc/courier-imap/imapd:
MAXPERIP=40
- Reload Apache and Courier IMAP services (Plesk Panel > Tools & Settings > Services Management)
- Optional, but needed for some clients (e.g. Windows 8.1 Mail app): Go to your Webmail and log in with your admin account. Go to Settings (the gear icon) > Administration > Permissions. Add following tree:
All Permissions > Horde > ActiveSync > Provisioning
In Provisioning, set Allow for All Authenticated Users
That's it!
Try to connect with a client (i.e. Outlook 2013). Use these values:
username: full email address (eg. contact@mydomain.com)
server: your chosen main domain ( e.g. server.com)
domain: the domain of your email address (e.g. mydomain.com) <-- This is necessary for some clients (e.g. Windows 8.1 Mail app).
There are more steps needed to make Autodiscover work, but it is not so important for me.
For more info, here is the official Horde Wiki.