In most cases, from Java based (like Portal) or ABAP based (ERP, CRM,...) systems, sending email is easy by just setting the SMTP server IP address. But if you're using a hosted email service like us (we're using Google Apps), SMTP server doesn't allow to send emails directly. It requires you to set specific SMTP port, TLS and SSL as well as authentication. So, for example, for sending emails from ERP systems, you just have SMTP Server address and Port area for settings via SCOT transaction.
To solve the problem, you can use IIS SMTP Server as an intermediate SMTP server between your SMTP server and local SAP System.
ERP, Portal >> -- send direct mail -- >> IIS 6/7 >> -- send with Authentication-- >> SMTP Server >> recipient.
1) Create an email account on your real mail provider. Eg. gmail account
2) Install the IIS SMTP Server. Installation method depends on the Windows Server version.
3) Configure the IIS Server to forward messages using that account as follow:
3.1) GoTo IIS SMTP Virtual server -> Properties -> Access Tab
3.2) Click Relay Button and chage the settings as follow:
You can specify only the servers that you want to be able to send email here by selecting Only the list below and adding your servers IP addresses.
3.3) Click Delivery Tab
3.4) Click Delivery > Outbound Security button:
Select Basic Authentication and specify your Gmail account and password. Check the TLS encryption if required (for gmail, it is required)
3.5) Click Delivery > Outbound connections button:
Set TCP port to 587 for Gmail or whatever it is in your case. 3.6) Click Delivery > Advanced button: