Add SMTP Windows Server 2016
Most may not realize that there is actually a free SMTP server builtin to Windows Server all the way back to Windows 2003 and is IIS 6 technology (I know, try to suppress your nausea). ย The SMTP server is aย featureย that can be added to modern Windows Server versions via the Server Manager. ย Out of curiosity and due to working on a project recently utilizing the SMTP server on a Windows 2012 box, I wanted to see if the SMTP server was still an option in Windows Server 2016 TP4 and the answer is yes.
Installing the SMTP server
This is a feature found in the Add Roles and Features Wizard and is simply listed asย SMTP Server.
By default, the feature wizard will add the Management tools for IIS 6 since this is an IIS 6 technology.
A reboot will not be prompted for adding this feature.
Using the SMTP Server
The SMTP Server is administered through the IIS 6 Management Console. ย An easy way to get there is to go to a run or command prompt and typeย inetmgr6.exe. ย You will see the IIS 6 SMTP Virtual Server manager as show below. ย If you right click on SMTP Virtual Server, you get a configuration box where you can configure most everything affecting mailflow.
One of the more important areas of the configuration is underย Delivery andย Advanced where you will see theย Advanced Deliveryย options. ย Here is where you configure your mail domain.
Testing mailflow
Using powershell we can test mailflow from our SMTP server using theย send-mailmessage commandlet. ย By default however, the server is not set to allowย any open relaysย out of the box.
If you run the send-mailmessage commandlet from the server itself, you need to add the server’s assigned IP address to the allowed to relay list before you test. ย Below is the default configuration.
After you have added the appropriate IP address, you can open up a powershell prompt and use the following to test SMTP relay
send-mailmessage -from "<[email protected]>" -to "John Doe <[email protected]>" -subject "Test" -body "Testing" -smtpserver 192.168.57.86
Final Thoughts
The SMTP relay included in Windows Server from 2008 forward is a no frills SMTP relay that doesn’t include many options, however, if you are looking for SMTP functionality for an application or for testing, it can come in very handy. ย It is good to see this feature is still hanging around in Windows Server 2016.
This is bu****** it is NOT on windows 2016 standard and or core and or enterprise server.
@fransbrouwer:disqus I see it as one of the available features on my server running 2016 Datacenter Edition. It could be exclusive to the Datacenter Edition only?
it seems it must be present on standard and datacenter edition
https://technet.microsoft.com/en-us/windows-server-docs/get-started/2016-edition-comparison
But lacks on core