New hmailserver setup

Use this forum if you have installed hMailServer and want to ask a question related to a production release of hMailServer. Before posting, please read the troubleshooting guide. A large part of all reported issues are already described in detail here.
Post Reply
karishma
New user
New user
Posts: 23
Joined: 2016-09-26 05:52

New hmailserver setup

Post by karishma » 2016-09-26 06:00

Hi all,
I've been reading about hmailserver and I am really impressed with the fact that it is open source and easy to setup.
We are looking to migrate from our current mail server to this, bearing in mind our office has limited IT personnel.

1) How is the maintenance of the hmail server in the long run, eg upgrades, spam control, OS upgrade?
2) Could i install the current version of the hmailserver and let it run seamlessly for the next 3-5 yrs?
3) What is the minimum requirement windows server to install the hMailServer 5.6.5 - Build 2367?
4) What are the add-ons that would be required for spam control/managment and webmail?

Thanks in advance, looking forward to testing hmailserver on my VM.

User avatar
mattg
Moderator
Moderator
Posts: 18982
Joined: 2007-06-14 05:12
Location: 'The Outback' Australia

Re: New hmailserver setup

Post by mattg » 2016-09-26 07:37

1. (after you have done a backup) Upgrades take seconds, way less than a minute, just install over the top of existing hMailserver.
2. yes, although the beta version is already better because the OpenSSL has been upgraded due to a patch that OpenSSL released. Always best to keep updated where possible.
3. No server OS required. hMailserver works on Windows7, 8.X, 10 and also on Windows Server versions since Server 2008 (and possible some earlier versions of windows too)
4. Webmail you need to install if you want it. Many of us use Roundcube, or Squirrelmail or NasMAIL, but these all require PHP to be running and a webserver. Some other web mail use ASP rather than PHP, but it depends on what else you have or can get. I use IIS + PHP as my web server, and I run those + hMailserver on my Windows 10 Pro machine.
Spam control is always a battle.
There is some good guides here to install SpamAssassin >> viewtopic.php?f=21&t=28133
You may also want some AntiVirus scanning
You can use hamailserver with any add ons if you like, I did for many years, just using hMailserver's built in spam controls (including greylisting), or you can pay for commercial spam reduction, or you can spend hours fiddling with settings like I tend to do.

There is a management GUI that is installed, 'easy as' to use, or if you have PHP installed then there is an included PHPWebAdmin that can give pretty good control to many users (at level)
Just 'cause I link to a page and say little else doesn't mean I am not being nice.
https://www.hmailserver.com/documentation

karishma
New user
New user
Posts: 23
Joined: 2016-09-26 05:52

Re: New hmailserver setup

Post by karishma » 2016-09-26 10:58

Hi mattg,

THanks for the reply, referring back to (3) & (4), may know what is the hardware spec required? And the PHP version? Can i setup WAMP instead of IIS?

User avatar
mattg
Moderator
Moderator
Posts: 18982
Joined: 2007-06-14 05:12
Location: 'The Outback' Australia

Re: New hmailserver setup

Post by mattg » 2016-09-26 11:25

https://www.hmailserver.com/documentati ... quirements

PHP required for phpwebadmin is low. Mine is PHP 5.4
yes, you can use WAMP if you like
(I don't like WAMP as they never seem to have the latest releases. I roll my own.)

PHP on IIS is really easy >> https://php.iis.net/ using the webinstaller
Just 'cause I link to a page and say little else doesn't mean I am not being nice.
https://www.hmailserver.com/documentation

User avatar
Dravion
Senior user
Senior user
Posts: 986
Joined: 2015-09-26 11:50
Location: Germany
Contact:

Re: New hmailserver setup

Post by Dravion » 2016-09-26 12:45

Hi Karishma and welcome.

As Matt allready mentioned, hMailServer is designed for ease of use. You can install it on
almost any Windows Computer (Windows Vista is now the Minimum without Servicepacks).

From my point of view its allways a good idea
to install hMailServer on a VPS or Windows Server
at some Hosting Company like GoDaddy with its own static ip and Domainname (as you may allready know, Emailservers depending massively on correct DNS-Settings and the easiest way to get all the DNS settings you need is rent a Windows vServer or Dedicated vServer).
Its allways a good Idea to buy a SSL-Certificate
at your Hosting company for your Domain to enable TLS encryption in hMailServer or get a free Startcom or Letsencrypt SSL certificate.

But you can of cause install hMailServer InHouse
at your Company on a central server and letting hMailServer fetch all incomning Emails from popular outside SMTP Servers like Postfix or
Exim.As you can see, there are many options.
My x64-Bit builds of hMailserver

hMailServer-5.6.8-B2431-x64.msi with LibreSSL 2.8.1
hMailServer-5.6.8-B2431-x64.exe with OpenSSL 1.0.2p

Downloads:
https://github.com/Dravion/hmailserver/releases

karishma
New user
New user
Posts: 23
Joined: 2016-09-26 05:52

Re: New hmailserver setup

Post by karishma » 2016-09-27 02:38

THanks mattg and Dravion!

Currently we are hosting our email with a provider, and due to support reasons, we are planning to host our own. I looked at Axigen, but the cost is really on the high side. But I just want to be transparent here, what are the features in hmailserver that makes it as attractive as a paid Axigen? As you can tell, although a System Admin, I am very much a noob on this email server, so I hope you guys can help me understand this.

1) We are currently hosting our DNS on Cloudflare, and plan to run this email server on a Windows 2012 VM in the cloud <--- does this sound ok?

2) Is it necessary to have SSL?

3) SMTP/Postfix/Exim, are these required?

Thanks in advance!

User avatar
mattg
Moderator
Moderator
Posts: 18982
Joined: 2007-06-14 05:12
Location: 'The Outback' Australia

Re: New hmailserver setup

Post by mattg » 2016-09-27 04:22

1. yes, absolutely fine
2. no, but useful. You can get free certificates, or create a self signed one, or use a purchased one - they aren't very expensive
3. PostrFIX/ EXIM are LINUX alternatives to hmailserver if you have a linux machine rather than a windows server
SMTP is a mail protocol used to send mail between servers or between mail clients and servers

hMailserver will do exactly what you want, and fairly easily

other alternatives are to get hosted Exchange or use google to host your domains. Both of these cost per user.
hMialserver will give you unlimited accounts, aliases and distribution lists plus public IMAP folders
hMailserver doesn't give you shared calendars or shared contacts
Just 'cause I link to a page and say little else doesn't mean I am not being nice.
https://www.hmailserver.com/documentation

karishma
New user
New user
Posts: 23
Joined: 2016-09-26 05:52

Re: New hmailserver setup

Post by karishma » 2016-09-27 07:44

Thanks mattg!

This means, when i create the server to host hmailserver, i need to make sure it is the same hostname as my desired mailhost, eg: mail.xxx.com.my? And the IP number would be the IP that I would point my mail.xxx.com.my in my DNS A list?
I also intend to use roundcube for the webmail, i suppose mounted disk on the server would be ok for storage solution?

User avatar
mattg
Moderator
Moderator
Posts: 18982
Joined: 2007-06-14 05:12
Location: 'The Outback' Australia

Re: New hmailserver setup

Post by mattg » 2016-09-27 10:08

karishma wrote:This means, when i create the server to host hmailserver, i need to make sure it is the same hostname as my desired mailhost, eg: mail.xxx.com.my?
Set a FQDN like 'mail.xxx.com.my' in a SMTP setting called 'local hos name' inside the hMailserver GUI. You don't need a special machine name for the computer.
The FQDN that you use should match the RDNS entry for your IP address though (that your ISP should set for you)
karishma wrote:And the IP number would be the IP that I would point my mail.xxx.com.my in my DNS A list?
Yes
Get a static IP from your ISP first though
karishma wrote:I also intend to use roundcube for the webmail, i suppose mounted disk on the server would be ok for storage solution?
Yes
Just 'cause I link to a page and say little else doesn't mean I am not being nice.
https://www.hmailserver.com/documentation

karishma
New user
New user
Posts: 23
Joined: 2016-09-26 05:52

Re: New hmailserver setup

Post by karishma » 2016-09-28 09:52

Ok so I tried the installation & setup today, but test connection for the email account did not work.
Here's what i did:
1) Created a VM, windows 7, with static IP, opened port, i am not clear which ports are to be opened for incoming/outgoing, is this right?

Image

2) Installed the hmailserver, and setup domain (our registered domain) & account

Image

3) Opened my outlook & try to connect but i get error:

Image

3.1) First I tried setting incoming/outgoing mail server to the IP number, it failed

3.2) THen i tried setting incoming/outgoing mail server to SMTP server name, as per setting below:
Image

In the case that I used IP number for incoming/outgoing mail server, i made no changes to my DNS A record, but when I used the mail.xxx.com.my as the incoming SMTP server name, i updated the A record for mail.xxx.com.my to point to my IP number.

4) Advanced settings on outlook:
Image

The demo videos i watched did not show any SMTP or FQDN settings, so I am not sure what am I doing wrong. Can you guys help me?
Thanks In Advance!

User avatar
Dravion
Senior user
Senior user
Posts: 986
Joined: 2015-09-26 11:50
Location: Germany
Contact:

Re: New hmailserver setup

Post by Dravion » 2016-09-28 13:25

First of all:
An MX etry needs an A record in the firstplace.

Second:
DNS maybe needs upto 72 hours before all
changes you made are officiay syncronized.

check your DNS entries with
nslookup -type=mx youdomain.com
My x64-Bit builds of hMailserver

hMailServer-5.6.8-B2431-x64.msi with LibreSSL 2.8.1
hMailServer-5.6.8-B2431-x64.exe with OpenSSL 1.0.2p

Downloads:
https://github.com/Dravion/hmailserver/releases

User avatar
mattg
Moderator
Moderator
Posts: 18982
Joined: 2007-06-14 05:12
Location: 'The Outback' Australia

Re: New hmailserver setup

Post by mattg » 2016-09-29 00:34

Also

1. run the hmailserver diagnostics and post the results here
2. enable all hmailserver logging, and show hmailserver logs of the connection attempts (no logging means no connection).

You need ports forwarded from router to VM and you need someway for the internet to find you, probably a DNS record with MX entries as Dravion suggested. There are other ways in LAN but not for WAN or internet access
Just 'cause I link to a page and say little else doesn't mean I am not being nice.
https://www.hmailserver.com/documentation

karishma
New user
New user
Posts: 23
Joined: 2016-09-26 05:52

Re: New hmailserver setup

Post by karishma » 2016-09-29 06:26

The Diagnostic log:
Test: Collect server details
hMailServer version: hMailServer 5.6.5-B2367
Database type: MSSQL Compact

Test: Test IPv6
IPv6 support is available in operating system.

Test: Test outbound port
SMTP relayer is in use.
Trying to connect to host 127.0.0.1...
Trying to connect to TCP/IP address 127.0.0.1 on port 25.
Received: 220 mail.truecloud.com.my ESMTP.
Connected successfully.

Test: Test backup directory
ERROR: Backup directory has not been specified.

Test: Test MX records
Trying to resolve MX records for truecloud.com.my...
Host name found: mail.truecloud.com.my
Host name found: bkpmail.localdns.com

Test: Test local connect
Connecting to TCP/IP address in MX records for local

domain domain truecloud.com.my...
Trying to connect to host mail.truecloud.com.my...
Trying to connect to TCP/IP address 13.76.240.148 on port

25.
ERROR: It was not possible to connect.
Trying to connect to host bkpmail.localdns.com...
Trying to connect to TCP/IP address 119.110.108.27 on port

25.
ERROR: It was not possible to connect.
ERROR: Was not able to open connection.

Test: Test message file locations
Relative message paths are stored in the database for all

messages.

Test: Test IP range configuration
No problems were found in the IP range configuration.

karishma
New user
New user
Posts: 23
Joined: 2016-09-26 05:52

Re: New hmailserver setup

Post by karishma » 2016-09-29 06:52

Logs:
"TCPIP" 3340 "2016-09-29 04:30:51.298" "DNS - MX Result: 1 IP addresses were found."
"DEBUG" 1928 "2016-09-29 04:30:55.626" "Creating session 8"
"TCPIP" 1928 "2016-09-29 04:30:55.626" "TCP - 127.0.0.1 connected to 127.0.0.1:25."
"DEBUG" 1928 "2016-09-29 04:30:55.627" "TCP connection started for session 7"
"SMTPD" 1928 7 "2016-09-29 04:30:55.627" "127.0.0.1" "SENT: 220 mail.truecloud.com.my ESMTP"
"DEBUG" 1928 "2016-09-29 04:30:55.628" "The read operation failed. Bytes transferred: 0 Remote IP: 127.0.0.1, Session: 7, Code: 2, Message: End of file"
"DEBUG" 1920 "2016-09-29 04:30:55.628" "Ending session 7"
"DEBUG" 1928 "2016-09-29 04:31:50.608" "Creating session 9"
"TCPIP" 1928 "2016-09-29 04:31:50.608" "TCP - 127.0.0.1 connected to 127.0.0.1:25."
"DEBUG" 1928 "2016-09-29 04:31:50.609" "TCP connection started for session 8"
"SMTPD" 1928 8 "2016-09-29 04:31:50.609" "127.0.0.1" "SENT: 220 mail.truecloud.com.my ESMTP"
"DEBUG" 1928 "2016-09-29 04:31:50.610" "The read operation failed. Bytes transferred: 0 Remote IP: 127.0.0.1, Session: 8, Code: 2, Message: End of file"
"DEBUG" 1924 "2016-09-29 04:31:50.610" "Ending session 8"
"DEBUG" 1928 "2016-09-29 04:34:03.293" "Creating session 10"
"TCPIP" 1928 "2016-09-29 04:34:03.293" "TCP - 127.0.0.1 connected to 127.0.0.1:25."
"DEBUG" 1928 "2016-09-29 04:34:03.294" "TCP connection started for session 9"
"SMTPD" 1928 9 "2016-09-29 04:34:03.294" "127.0.0.1" "SENT: 220 mail.truecloud.com.my ESMTP"
"DEBUG" 1928 "2016-09-29 04:34:03.295" "The read operation failed. Bytes transferred: 0 Remote IP: 127.0.0.1, Session: 9, Code: 2, Message: End of file"
"DEBUG" 1920 "2016-09-29 04:34:03.295" "Ending session 9"
"DEBUG" 1928 "2016-09-29 04:35:10.795" "Creating session 11"
"TCPIP" 1928 "2016-09-29 04:35:10.795" "TCP - 127.0.0.1 connected to 127.0.0.1:25."
"DEBUG" 1928 "2016-09-29 04:35:10.795" "TCP connection started for session 10"
"SMTPD" 1928 10 "2016-09-29 04:35:10.795" "127.0.0.1" "SENT: 220 mail.hmailserver.com ESMTP"
"DEBUG" 1928 "2016-09-29 04:35:10.795" "The read operation failed. Bytes transferred: 0 Remote IP: 127.0.0.1, Session: 10, Code: 2, Message: End of file"
"DEBUG" 1924 "2016-09-29 04:35:10.795" "Ending session 10"
"DEBUG" 1928 "2016-09-29 04:42:06.761" "Creating session 12"
"TCPIP" 1928 "2016-09-29 04:42:06.761" "TCP - 127.0.0.1 connected to 127.0.0.1:25."
"DEBUG" 1928 "2016-09-29 04:42:06.761" "TCP connection started for session 11"
"SMTPD" 1928 11 "2016-09-29 04:42:06.761" "127.0.0.1" "SENT: 220 mail.hmailserver.com ESMTP"
"DEBUG" 1928 "2016-09-29 04:42:06.761" "The read operation failed. Bytes transferred: 0 Remote IP: 127.0.0.1, Session: 11, Code: 2, Message: End of file"
"DEBUG" 1920 "2016-09-29 04:42:06.761" "Ending session 11"
"DEBUG" 1928 "2016-09-29 04:42:56.495" "Creating session 13"
"TCPIP" 1928 "2016-09-29 04:42:56.495" "TCP - 127.0.0.1 connected to 127.0.0.1:25."
"DEBUG" 1928 "2016-09-29 04:42:56.495" "TCP connection started for session 12"
"SMTPD" 1928 12 "2016-09-29 04:42:56.495" "127.0.0.1" "SENT: 220 mail.hmailserver.com ESMTP"
"DEBUG" 1928 "2016-09-29 04:42:56.495" "The read operation failed. Bytes transferred: 0 Remote IP: 127.0.0.1, Session: 12, Code: 2, Message: End of file"
"DEBUG" 1924 "2016-09-29 04:42:56.495" "Ending session 12"
"DEBUG" 1928 "2016-09-29 04:45:11.963" "Creating session 14"
"TCPIP" 1928 "2016-09-29 04:45:11.963" "TCP - 127.0.0.1 connected to 127.0.0.1:25."
"DEBUG" 1928 "2016-09-29 04:45:11.963" "TCP connection started for session 13"
"SMTPD" 1928 13 "2016-09-29 04:45:11.963" "127.0.0.1" "SENT: 220 mail.hmailserver.com ESMTP"
"DEBUG" 1928 "2016-09-29 04:45:11.963" "The read operation failed. Bytes transferred: 0 Remote IP: 127.0.0.1, Session: 13, Code: 2, Message: End of file"
"DEBUG" 1928 "2016-09-29 04:45:11.963" "Ending session 13"
"DEBUG" 1928 "2016-09-29 04:50:52.790" "Creating session 15"
"TCPIP" 1928 "2016-09-29 04:50:52.790" "TCP - 127.0.0.1 connected to 127.0.0.1:25."
"DEBUG" 1928 "2016-09-29 04:50:52.790" "TCP connection started for session 14"
"SMTPD" 1928 14 "2016-09-29 04:50:52.790" "127.0.0.1" "SENT: 220 mail.hmailserver.com ESMTP"
"DEBUG" 1928 "2016-09-29 04:50:52.790" "The read operation failed. Bytes transferred: 0 Remote IP: 127.0.0.1, Session: 14, Code: 2, Message: End of file"

karishma
New user
New user
Posts: 23
Joined: 2016-09-26 05:52

Re: New hmailserver setup

Post by karishma » 2016-09-29 06:54

nslookup:
Image

karishma
New user
New user
Posts: 23
Joined: 2016-09-26 05:52

Re: New hmailserver setup

Post by karishma » 2016-09-30 09:08

Hi guys,

Please ignore my earlier email, i was able to tweak my hmailserver settings and the diagnostics gives me positive results now.
Test: Collect server details
hMailServer version: hMailServer 5.6.5-B2367
Database type: MSSQL Compact

Test: Test IPv6
IPv6 support is available in operating system.

Test: Test outbound port
SMTP relayer not in use. Attempting mail.hmailserver.com:25...
Trying to connect to host mail.hmailserver.com...
Trying to connect to TCP/IP address 5.189.183.138 on port 25.
Received: 220 mail.hmailserver.com ESMTP.
Connected successfully.

Test: Test backup directory
ERROR: Backup directory has not been specified.

Test: Test MX records
Trying to resolve MX records for truecloud.com.my...
Host name found: mail.truecloud.com.my

Test: Test local connect
Connecting to TCP/IP address in MX records for local domain domain truecloud.com.my...
Trying to connect to host mail.truecloud.com.my...
Trying to connect to TCP/IP address 13.76.240.148 on port 25.
Received: 220 mail.hmailserver.com ESMTP.
Connected successfully.

Test: Test message file locations
Relative message paths are stored in the database for all messages.

Test: Test IP range configuration
There is a total of 3 auto-ban IP ranges.
One of my colleague is able to connect to the email from his network, however if i try the same, i get error:

Image

this is so weird, any idea?

User avatar
Dravion
Senior user
Senior user
Posts: 986
Joined: 2015-09-26 11:50
Location: Germany
Contact:

Re: New hmailserver setup

Post by Dravion » 2016-09-30 18:33

Check your hMailServer Autoban settings and temprarly disable it and the try login again with Outlook.
My x64-Bit builds of hMailserver

hMailServer-5.6.8-B2431-x64.msi with LibreSSL 2.8.1
hMailServer-5.6.8-B2431-x64.exe with OpenSSL 1.0.2p

Downloads:
https://github.com/Dravion/hmailserver/releases

karishma
New user
New user
Posts: 23
Joined: 2016-09-26 05:52

Re: New hmailserver setup

Post by karishma » 2016-10-06 10:34

THanks Dravion, it works now.

I plan to bring my hmailserver live to our users, say about total 20 users for 2 domains.
What is the minimum hardware spec required to support this load, as in how many cores & RAM, Based on your experience?

User avatar
jimimaseye
Moderator
Moderator
Posts: 7460
Joined: 2011-09-08 17:48

Re: New hmailserver setup

Post by jimimaseye » 2016-10-06 12:02

Dravion wrote:Check your hMailServer Autoban settings and temprarly disable it
karishma wrote:THanks Dravion, it works now.
Dont forget to re-enable the autoban feature - just delete the individual bans that are in place for those clients (that were created due to previous incorrect signin attempts).
HMS 5.6.6 B2383 on Win Server 2008 R2 Foundation, + 5.6.7-B2415 on test.
SpamassassinForWindows 3.4.0 spamd service
AV: Clamwin + Clamd service + sanesecurity defs : https://www.hmailserver.com/forum/viewtopic.php?f=21&t=26829

karishma
New user
New user
Posts: 23
Joined: 2016-09-26 05:52

Re: New hmailserver setup

Post by karishma » 2016-10-07 08:56

I still havent got a concrete answer on the suitable windows 7 spec to support my 2 domains, hope someone can help
I plan to bring my hmailserver live to our users, say about total 20 users for 2 domains.
What is the minimum hardware spec required to support this load, as in how many cores & RAM, Based on your experience?

User avatar
mattg
Moderator
Moderator
Posts: 18982
Joined: 2007-06-14 05:12
Location: 'The Outback' Australia

Re: New hmailserver setup

Post by mattg » 2016-10-07 09:16

If your machine runs windows 7, it will handle that VERY SMALL load

There are reports of hMailserver (with appropriate hardware) hosting hundreds of thousands of accounts, across tens of thousands of domains with a million daily messages.
One domain and 20 accounts won't even be noticable (unless you are a spammer and send hundreds of thousands of emails each day)
Just 'cause I link to a page and say little else doesn't mean I am not being nice.
https://www.hmailserver.com/documentation

Post Reply