Running an e-Mail server on Windows Home Server
I hear the question all the time. “Why doesn’t Windows Home Server have an e-Mail Server included?”
The answer is simple: Because it ain’t easy to do.
Well, let me clarify that. It’s EASY to install and run e-Mail Server software on Windows Home Server. It’s not so easy to get it to work with your ISP, connection, firewall and clients.
Most ISPs use Dynamic IP addresses for customer internet access. This means your address could keep changing. That makes running a mail server tricky, imagine if your street address kept changing and your friends were constantly trying to find you. You can use the FREE DynDNS service to update your address any time it may change.
If you have a business account with the static IP option, this won’t be a problem for you.
You need a domain name to send mail to (That’s the part after the @ in an e-Mail address. @mydomain.com). There’s a way around this by registering your own domain or using a DynDNS domain name. We’ll go into that later.
Most ISPs block port 25 & port 80 (e-Mail Server to Server port, Web Server port). You can get around this by using port relaying, or DynDNS MailHop Relay service (Pay Service).
Your ISP may or may not allow you to send mail from your personal domain name through their server. Yep, another job for the DynDNS Outgoing Mail Relay. (Pay Service)
Your router/modem/firewall. You need to get into your device and figure out how to allow mail to get in and out of your internet connection and get to your Windows Home Server.
Software. How do I get e-Mail Server software onto my Windows Home Server? You might think that the software would be the first problem to solve, but it’s really the easy part. You need to solve all the others first.
Let’s take each problem one at a time.
Problems 1&2: Dynamic IP address, Domain Name
Your ISP uses dynamic IP addresses and yours keeps changing and you need a domain name. The easiest way to get around these is to use the DynDNS service.
DynDNS.org has 88 domain names for you to choose from. I tend to use dnsalias.org (. net, .com) just because I use them mostly in professional situations and it wouldn’t be good to use something like doesntexist.com (Yes, that’s a real name you can use on DynDNS).
Open www.dyndns.com and scroll down to “Free Domain Name”.
Note: It was pointed out to me by Mike Garcen from MissingRemote.com that Microsoft gives you a free dynamic DNS name "MyName.homeserver.com". That should actually work fine for running your mail server.
If you log into your Windows Home Server control panel and go to Settings then Remote access, then Turn On remote access, a wizard will start that will walk you through configuring it. If your router supports uPNP, it will even configure the router for Web and RDP access. It WILL NOT configure it for email though.
If you've read my other security posts, I'm NOT a fan of uPNP and I think you should make the router/firewall changes manually.
Choose a domain from the drop down, then type in a name that you want to use as your domain name. Here I chose dnsalias.com and typed in "mywhsserver" as my domain name. So my full domain name will be mywhsserver.dnsalias.com.
Click Add to go to the next page.
You can see here that your new domain name is added to the cart. There is no cost for this so the total should be $0.
I happened to pick a name that wasn’t already taken. If you try one that is taken, you will get a warning and sent back to choose another name. If you don’t have a DynDNS account, you can create one here. I already have an account, I’ll just log in.
Click on next to confirm your free purchase, and then click on next again to activate the service. You will be brought to a screen that lists your hosts. You can have up to 5 with the free service.
Click on the domain name you just created and that will bring you to the configuration page.
At the bottom of the page, click on “Mail Server” and “Web Server” and save changes.
If you’re wondering about an MX record and e-Mail. The FREE DynDNS service relies on the SMTP standard, which says you don’t technically NEED an MX record. Any mail sent to the domain will default to the A record if no MX record is found. I’m not particularly happy with that, but it should work.
Now you need to update your IP address with the DynDNS service. You can download the update client at http://www.dyndns.com/support/clients/ and then install the client on any computer on your network since they all go out to the internet with the same IP address. But it would be better to install it on a computer that is on all the time, in case the address changes while that PC is off.
Or, you can check to see if your Modem/Router/Firewall has a built in DynDNS update client. Most devices in the last 5 years now support DynDNS. This would be the way to go if your device supports it.
Problem 3: My ISP blocks ports 25 & 80
This is where it starts getting very tricky. To get around this, you’ll have to spend some money.
First you will need to register a real domain name. You can do this on a service like GoDaddy.com, I have several domains registered. Most domain registrars will charge you around $10/yr for domain registration.
Next, you need to set up your DNS. If you have a static IP address this is easy, you can use the DNS servers of your Domain Registrar. If you have a dynamic address, you will now need to use the DynDNS Custom DNS service. ($29.95/yr)
Once you have your DNS (Static or Dynamic) sorted. You need to sign up for DynDNS MailHop Relay ($49.95/yr). What MailHop Relay does is intercept any mail being sent to your domain on port 25 and resend it to another port (24, 25, 587, 2525, 10025, 52525 are supported). Your ISP may block some of these ports, but chances are, at least one of them is open.
Problem 4: My ISP won’t let me send mail from my domain through their server.
This isn’t as common as blocking port 25, but a lot of ISPs still do it for anti-spam reasons.
You could try sending your e-Mail direct from your server to the remote server, but most servers will reject mail coming from a Dynamic IP. Again, if you have a static IP, this MAY work for you.
If you can’t send through your ISPs server, and the remote servers reject mail direct from your server, you’re going to need some sort of outgoing mail relay. There are a number of relay services out there. But since we’ve been using DynDNS, let’s stick with it. MailHop Outgoing Relay $19.95/yr
Problem 5: Modem/Router/Firewall
You will need to get into your device and figure out how to port forward to your server. There are FAR too many devices for me to try to explain all of them, but basically, it goes like this.
In your firewall settings there will be some sort of heading, tab, button that says something like Port Forwarding, Applications, Games, or some variation of that. It will usually have 3 settings: Source port, Destination IP, Destination Port. I have also seen them with only 2 settings: Source Port, Destination IP.
Source Port – This confuses some people, this is the port that the Remote Computer is trying to contact, ie: port 25 to deliver mail.
Destination IP – This is the address of the Server INSIDE your firewall. It should be a private IP address like 192.168.1.10. Use the address of your e-Mail server if you are trying to receive mail.
Destination Port – This is the Port on the INSIDE server (Mail Server) that the router will forward TO. This is handy if you are using a MailHop Relay to a different port. The router will change the port that it received the request on to whatever port you set here.
So if you are using MailHop relay to change the port from 25 to 2525 for instance, the router can intercept 2525 and re-forward it back to 25 so you don’t have to change the e-mail server port.
Now that we have all these other problem’s sorted out. It’s time to get to Problem 6: e-Mail Server Software
I have had great luck using DeskNow! Mail and Collaboration Server. www.desknow.com
DeskNow comes in 2 flavors that we’ll cover here: Lite and Professional. The lite version is FREE and has many features included: Unlimited Domains and users, Pop, SMTP, WebMail . . .
The Professional version has many other features that may or may not be of interest. The professional version starts at $150 for a 5 user license, so it’s still VERY reasonable.
The ASP version is for e-Mail service providers that want to host e-Mail as a business.
The install is VERY simple. First you want to RDP into your Windows Home Server desktop. When you get to the desktop, you can either download DeskNow! From there or you can download it from another PC and save it to the Windows Home Server public folder or some other folder that you can access. (It’s currently about 56MB)
Double click on the exe you downloaded to start the install.
The first few screens are the standard windows install screens. You can choose all the defaults until you get to the “Configuration Wizard”.
Note: One exception to the defaults. When you get to the screen that asks for the DeskNowData folder, the default is "C:\Desknowdata", that won't work on a Windows Home Server. You will need to create a shared folder on the Home Server. I named mine "Desknow" and only gave myself access to it. Desknow uses admin credentials and it doesn't need specific permissions. You can turn on folder duplication if you want to make your e-mail safer from drive failure.
When you get to the DesknowData Folder screeen, use the UNC path of \\MyServerName\desknow\Desknowdata, DeskNow! understands UNC paths and this will work fine.
The next screen is asking what ports you want to run the webmail server on. Since Windows Home Server is already running on 80 and 443, I change them to 8080 and 4443.
The next screen is asking what ports you want to run the Instant Message server on. These are fine to leave as default. Or you can shut IM off if you won’t be using it.
The next screen is asking how you want to use DeskNow.
1) As a standalone server for all Incoming and Outgoing mail.
2) As a POP server that will go out to another server and grab all your mail from there and download it into DeskNow!
3) As a collaboration server only. Internal mail, IM, file sharing and calendar ONLY.
Choose how you are going to use DeskNow! And click Next.
The next screen is asking what IP addresses are allowed to use this server for mail relay. Unless you plan on using this server from outside your house to relay mail, you should just enter your internal address range. Mine is 192.168.1.X (Leave off the last digit)
This screen wants the domain name you configured to receive mail, either in DNS or DynDNS. I had created mywhsserver.dnsalias.com, so, that’s what I’ll enter here.
The next screen is localization; enter your time zone and language.
The next screen wants you to set the Admin password for your first domain (The first domain will be the MASTER domain. If you add other domains later, you will have to log into THIS domain to make changes to server settings.)
Click Save & Exit.
That’s it! You’re done! DeskNow! Is installed and up and running. When DeskNow! Restarts, it will bring up a QuickStart guide. But all you really need to do is add a user or 2 and you should be up and running!
You get to the mail server from the Windows Home Server desktop by opening a web browser and browsing to http://localhost:8080 (If you changed the default port to 8080, you need to add it at the end of the address to tell IE to connect on port 8080, you also have to add it from other clients. The address from another client to my server would be http://mywhsserver.dnsalias.com:8080)
If you try to get in right away, you may get a message saying that this is the first time DeskNow! was started and the default configuration is being created.
That’s the end of this post. DeskNow! Has MANY settings and it’s all documented on their website.