Cloud Email Service Solution

hMmailserver + Roundcube +XRCLOUD ECS

hMailServer is a free, open-source, e-mail server for Microsoft Windows. It's used by Internet service providers, companies, governments, schools and enthusiasts in all parts of the world.
It supports the common e-mail protocols (IMAP, SMTP, and POP3) and can easily be integrated with many existing webmail systems. It has flexible score-based spam protection and can attach to your virus scanner to scan all incoming and outgoing emails.
Roundcube webmail is a browser-based multilingual IMAP client with an application-like user interface. It provides full functionality you expect from an email client, including MIME support, address book, folder manipulation, message searching, and spell checking.

We can very easy to get the cloud server online, so we can deploy our private email server on the ECS that is a very cost-efficient way for individuals or enterprises. Now we share how to deploy your private cloud email services on XRCLOUD ECS with hMailserver and RoundCube webmail. now.

1. The architecture of the cloud email system is very simple: Front-End of the webmail, email system, database system, of course, we can deploy these components on one cloud server. we will introduce how to deploy cloud email service on one ECS.

Figure1.Diagram of cloud email system architecture

2. Get ECS from XRCLOUD.COM: You can sign up and get one ECS from XRCLOUD.COM free. After you register, you can click the free trial button, and then you can choose a Windows 2012 std image for the ECS instance. After the XRC platform launched the instance then you can connect the ECS from the web-VNC or you can connect from your local windows OS remote desktop client. (likes Figure 2)

3. Download the hmailserver software from the official website: . Usually, we download the latest version likes 5.6.8-build 2501.

Figure2. Get the free ECS from XRCLOUD.COM

4. Install the hMailserver and configure it:

Figure3.hMailserver setup

If you are deploying a large business cloud email system, you can deploy the database separately, in this test we choose the SQL Compact database, we can use the software CompacViewer to open the database file.

After setup the database, we need to set up the password for the hMailserver system, for secure, we should use a strong password.

Then we finished the installation, now we need to launch the administrator control panel to configure the software likes: email domain, user accounts, the protocols, the ports, etc.

Figure4. Database setup
Figure5. Set up the password
Figure6. Launch the administrator panel

5. Configure the hMailserver:
we can buy a domain from or another similar website for our email system, then set up the email domain. In this test, we use the email address:[email protected], so the email domain is, input the, and save the configuration.

Figure7.Set up the email domain

After completing the domain configuration, we can create user accounts.

Figure8.Create user accounts

6. Configure DKIM:
DomainKeys Identified Mail (DKIM) is an email authentication method designed to detect forged sender addresses in emails (email spoofing), a technique often used in phishing and email spam. If the DKIM doesn't configure for the email server, the email will be recognized as a spam email and blocked by the other filters.
How to use the DKIM for the hMailserver, we need two keys: a public key for the DNS resolution and the private key which the email server used to sign each email.we can use free software OpenSSL to generate the keys.

You can download the OpenSSL from the link:,and extract the package to the volume C.Then open the CMD client and go to the OpenSSL software exist directory BIN, now we can generate the public key and the private key.

First, we get the private key, Input the: openssl.exe genrsa -out rsa.private 1024 to the command prompt.

Figure9. Generate the private key

Then we can use the private key to generate the public key.we input command: openssl.exe rsa -in rsa.private -out rsa.public -pubout -outform PEM

Figure10. Generate the public key

Now we can see two new files:rsa.private and rsa.public in the BIN directory.

Figure11. Two key files

We can copy these two files to the BIN directory where hMailserver is located so that we can use it easily, open the rsa.public with notepad, and copy the content then paste it to your email domain DNS control panel, copy text sandwiched between two dashed lines, don't modify anything, dont copy the dashed-lines, Enter to you email domain console panel, and add a txt record for the DKIM, and paste the ras.public key value to the record value.

Figure12 Copy the public key

The host name is webmail._domainkey, the words before the underline must be the same as the selector value on the hMailserver`s DKIM signing.

Figure13 Add a TXT record for DKIM

Add the txt record for SPF and DMARC on your domain console panel.

Figure14: Add a TXT record for DMARC

Add a TXT type record for DNS,the Host name is: _dmarc, value is : v=DMARC1;p=none

Add a TXT type record for DNS, the Host name is:@, the value is:v=spf1 a ip4: (you should use your email sever`s IP address)

Figure15 Add a TXT record for SPF

That's all the configuration for the DKIM public party, then, we should configure the DKIM signature on the email server.

Figure16 Configure the DKIM Signing

Choosing the DKIM Signing tab, check the Enable option, and choose the ras.private file from the hmailserver BIN directory, the selector value is webmail.

If you have any questions, please contact us at [email protected] or submit a support case.

No comments

Related recommendation

No related articles!


Cloud Email Service Solution