Example for Adapting Sendmail.cf

The following example illustrates the procedure for the adaptation of configuration file Sendmail.cf to an HP UX system.

Note that the file is set up in a different way according to the network structure. Your file will perhaps look different if you are working on an HP UX system.


1.    Load, on the SAP Internet Mail Gateway server, the file Sendmail.cf in a text editor, for example Vi or Emacs.

2.a) Call the section in which the mailers are defined by searching for a line which begins with Mlocal, Mtcp or Mether:

2.b) Copy the line which begins with Mlocal and replace:

Replace with




P=<Path and name of file Mlsomail>


F=DFMPlLms, L=990

The letter l and not the number 1  comes after DFMP. l is an indicator that the structure of the message determines and specifies that the program Mlsomail is present locally on the machine. The host name is therefore ignored when the rules are entered.

A=rmail -d $u

A=mlsomail config_file $u

Config_file is the complete path to the configuration profile. You do not have to specify the complete path to file Mlsomail in A=...

After you have carried out the changes, the section of the mailer definition could be as follows:

Under Windows NT with Metainfo Sendmail, no path specifications are possible for the mailer definition. Therefore, the mailer program Mlsomail must be located in the same directory as the mailing program sendmail. The backslashes in the path details for the configuration file must be masked. This is done through doubling: \\. In this case, a mailer definition could appear as follows:

Msap, P=mlsomail.exe, F=DPFlLs, L=990, s= 10, R=20, A=mlsomail.exe d:\\Sendmail\\SIMG\\mailgw.ini $u

3.a) Call section Ruleset 0 in which the rules for the distribution of incoming Internet messages to the mailer are described.

Sendmail rules have the following structure:

Address part  <tab>  mailer part  <tab>  optional comment

Note the following conventions when entering sendmail rules:

A rule always begins in the first column; continuation lines are started with a blank character or a tabulator.

The parts of a sendmail rule must always be separated by tabulators.

3.b) Make a new rule which specifies that Internet messages addressed to users of SAP system C11 are transferred to the SAP mailer:

The general rule is that each address which ends with either @C11.company.com or @C11 is distributed to the SAP mailer. You can use $1@company.com to specify that the address user@company.com is forwarded as user argument $u to the mailer.

4.a) Call the section which contains the “trusted user” (user name with prefix T):

4.b) Add the user, under which the program Mlunxsnd runs. In our example this is the SAP User C11adm:

Step 4 does not apply to Windows NT. Because a different user and authorization concept is used there, a “trusted user” is not required.

The following steps are also necessary for Windows NT with Metainfo sendmail:

a) Call Ruleset 96:

b) Add an additional line at the start so that a DNS lookup of the SAP system name is prevented:

5.a) Save your changes.

In order for your changes to take effect, you must cancel and restart the sendmail daemon.


The configuration file Sendmail.cf is adapted for your network structure. Internet messages addressed to SAP users are forwarded to the SAP mailer of the SAP Internet Mail Gateway.