Configuring Email in SAP

As of SAP Web Application Server 6.10, the SAP system's kernel supports SMTP (Simple Mail Transfer Protocol) directly, meaning that e-mails can be exchanged between the SAP system and any SMTP-compliant mail server without the need for any additional external components. In the outbound direction, the SAP system passes the mails to a single mail server, whereas in the inbound direction mails can be received from any number of mail servers.

As of SAP Web Application Server 6.20, faxes and text messages (pager/SMS) can also be exchanged via SMTP. For this purpose, the faxes and messages are packed into e-mails. For sending, the mail server refers to the domain of their recipients' addresses and forwards the e-mails either to an internal fax/text message server (for example SMS=+919820654321@sms-server.company.com), or to an external provider (for example FAX=+18006756543@fax-provider.com). For receiving, the fax/text message server or provider sends e-mails to addresses with the SAP system's domain (for example FAX=+18009873456@crm-prod.company.com).
Plese ensure:

The mail servers involved must be SMTP-compliant.

If you want to use text messaging in the SAP system, names for the messaging services to be used, such as SMS, must be defined using transaction SA14.
Configuring Profile Parameters (tcode RZ10)

You must adapt the SAP Web Application Server’s profile if the SMTP functionality is to be used. The SAPconnect send job can only be scheduled for servers on which SMTP is active, so ideally you should activate SMTP on all of the SAP system’s application servers.

You must set the profile parameters below. The placeholder <*> stands for the sequence number (starting with zero) of parameters that occur several times.

* icm/plugin_<*> = PROT=SMTP,PLG=

This loads the SMTP plug-in. It is a dynamic library that implements the SMTP protocol. specifies the file name of the SMTP plug-in. The program is located in the execution directory of the SAP Web Application Server instance, has the name smtpplugin and the extension typical for your operating system (.so, .dll, and so on).

* icm/server_port_<*> = PROT=SMTP,PORT=

This opens a TCP/IP port for the reception of mails by the SMTP plug-in. specifies the number of the port that is to be used. This port must not be occupied by any other program on this host. If no mails (including status notifications) are to be received in this SAP system, you can set to 0.

You can use TIMEOUT to define an optional maximum time (in seconds) that is to be waited for a response from the mail server.

* is/SMTP/virt_host_<*> = :,,...;

This defines a virtual mail host for the reception of mails. If all inbound mails (including status notifications) are to be received and processed in a single client of the SAP system, this parameter is not required and is/SMTP/virt_host_0 = *:*; is taken as the default. If several clients are to receive, a virtual mail host must be created for every client. specifies the name of the host to which inbound mails are addressed. You can specify * here if the mails are to be distributed independently of the host addressed. specifies the number of a port to which inbound mails are addressed.

Under UNIX, the profile parameters could be:

rdisp/start_icman = true

icm/plugin_0 = PROT=HTTP,PLG=./httpplugin.so

icm/plugin_1 = PROT=HTTPS,PLG=./httpplugin.so

icm/plugin_2 = PROT=SMTP,PLG=./smtpplugin.so

icm/server_port_0 = PROT=HTTP,PORT=1080

icm/server_port_1 = PROT=HTTPS,PORT=1443

icm/server_port_2 = PROT=SMTP,PORT=25000,TIMEOUT=180

icm/server_port_3 = PROT=SMTP,PORT=25001,TIMEOUT=180

is/SMTP/virt_host_0 = *:25000;

is/SMTP/virt_host_1 = *:25001;
Create a User (tcode SU01)

* System user

You must create a system user to process the inbound mails in every SAP system client in which mails (or status notifications) are to be received. You use transaction SU01 to create a user of the type System and assign the profile S_A.SCON to it.

* User addresses

Every single user who is to receive e-mails in an SAP system needs an Internet mail address. This is also used as the sender address. You enter the Internet mail address of a user in transaction SU01 on the Address tab page under E-Mail.
Assign Client (tcode SICF)

Each SAP system client in which inbound mails (or status notifications) are to be received and processed must have an SMTP server. In transaction SICF, there should be one SMTP server (called SAPconnect) supplied in every SAP system. You use this one for the first client then create an additional SMTP server for each additional client. You make the following settings on the SMTP servers:

* Host data

You enter the sequence number of a parameter is/SMTP/virt_host_<*> from the profile. If you only have one client and therefore did not enter a parameter of this kind, you enter 0.

* Service data

You enter the client to which the mails received via this virtual mail host are to be forwarded, as well as the logon data of the system user created for inbound mails.

* Handler list

You enter CL_SMTP_EXT_SAPCONNECT as item 1.

As of SAP Web AS 6.20, each SMTP server has to be activated (Service/Virt. Host Activate) after being created or changed.

Configuring SAPConnect (tcode SCOT)

You must make the SAPconnect settings in each client that is to be used to send communications.

* Default domain

Under Settings => Default Domain, you define the domain of this SAP system client. This is used for the following purposes:

+ The SMTP plug-in logs on to the mail server using the domain as ID.
+ The message ID of outbound e-mails is compiled with this domain.
+ If an SAP user who has no Internet mail address maintained sends an e-mail, a sender address composed of the SAP user name and this domain is generated.

* Node

There is always one SMTP node in each client. This node is created by the SAP system and cannot be deleted. To configure the node for sending Internet mail, you:

1. Ensure you are in the Node view.
2. Double-click on the node name.
3. Select Node in use.
4. Specify the mail server to which outbound mails are to be passed in Mail Host and Mail Port.
5. Choose Set adjacent to Internet.
6. Specify the address areas of recipient addresses that are to be reached via this node. This is usually * if all e-mails are to be sent using SMTP.
7. Enter output formats for SAP documents. The following settings are recommended here:

SAPscript/Smart Forms


PDF

ABAP List


HTM

Business Object/Link


HTM

RAW Text


TXT

8. Confirm.

If you want to configure the node for sending faxes as well, you:

1. Choose Set adjacent to Fax.
2. Specify the address areas of recipient addresses that are to be reached via this node. This is usually * if all faxes are to be sent using SMTP.
3. Enter output formats for SAP documents. The following settings are recommended here:

SAPscript/Smart Forms


PDF

ABAP List


PDF

Business Object/Link


TXT

RAW Text


TXT

4. Enter the domain of the fax server or fax provider under Conversion into Internet Address. The system generates the local part of the Internet address automatically. The address then has the format FAX=+RecipientNumber@Domain.
5. Confirm.

If you want to configure the node for sending text messages (pager/SMS) as well, you:

1. Choose Set adjacent to Pager (SMS).
2. Specify the address areas of recipient addresses that are to be reached via this node. This is usually * if all text messages (pager/SMS) are to be sent using SMTP.
3. Enter the domain of the text message (pager/SMS) server or provider under Conversion into Internet Address. The system generates the local part of the Internet address automatically. The address then has the format SMS=+RecipientNumber@Domain.
4. Confirm.

* Send job

E-mails sent from an SAP application are merely put into a queue. A periodic background process, known as the SAPconnect send job, takes the e-mails from this queue and sends them via the Internet. To schedule this job from SAPconnect administration, you:

1. Choose View => Jobs.
2. If there is not already a job scheduled, choose Job => Create.
3. Enter a job name and confirm.
4. Select the variant SAP&CONNECTALL by placing the cursor on it.
5. Choose Schedule Job.
6. Choose Schedule Periodically.
7. Enter an appropriate time period, such as 10 minutes.
8. Choose Create.

* Inbound

If you want inbound e-mails to a specific address or with a specific content to automatically start a program that processes these e-mails, you can configure this under Settings => Inbound Processing.

If you want inbound e-mails to a specific address or from a specific sender to be automatically redirected to another recipient or distribution list, you can configure this under Settings => Inbound Distribution.

No comments:

topics