Configuring IBM i to send emails

Table of contents


All the configuration details given below can only be taken as examples, since the TCP/IP configurations are set differently in many companies due to internal company specifications.

General notes

Start the configuration with the OS/400 command CFGTCP

TCP/IP interfaces

via selection 1 (Work with TCP/IP interfaces) your Ethernet or Token Ring line must be specified with the TCP/IP address and the subnet mask of your IBM i

Example

0001 - Interface example

TCP/IP routes

Here you specify which TCP/IP address is used to communicate with the Internet. Enter *DFTROUTE as the routing destination, subnet mask *NONE and the TCP/IP address of your router as the next hop if there is no internal e-mail server.

Note: This will make your IBM i accessible during connections on the Internet.

0002 - Routing example

TCP/IP host entries

Use this display (selection 10 from the configuration screen) to set the local mail function if you want to send in-house e-mails. In our example the emails to MESSE.DE are distributed locally

0003 - Host table entries

TCP/IP domain information

Please make sure that the information you enterunder selection 12 Domain information leads to a resolvable address, i.e. that it corresponds to the host table names entered under selection 10.

0004 - Domain Information

Configure TCP/IP applications

Set the SMTP and POP services of your IBM i here (selection 20 from the configuration menu).

Configure SMTP

You only need the SMTP configuration if you want to use the IBM i as SMTP server. directmail also offers you the option to use a different SMTP server than the IBM i.

Use selection 12 to branch to the configuration of the SMTP properties. Use selection 3 from the following menu to change the SMTP attributes. Note: Selection 3 requires QSECOFR rights!

0005 - SMTP attributes

Enter *YES for "Start server automatically" and possibly the mail router on the second page (e.g. for T-Online it is "mailto.btx.dtag.de").

0006 - SMTP attributes 2nd page

POP server attributes

You only need the POP configuration if you want to use the IBM i as POP server. directmail also offers you the option of using a POP server other than the IBM i.

Selecting 16 takes you to the configuration of the POP server attributes.

0007 - POP server attributes

Again, enter *YES for "Start server automatically".

Set the size of a message block to the maximum value of 2048. A smaller value results in e-mails leaving your system being split into several blocks and sent if necessary. In most cases the receiving system has difficulties to receive them properly.

With the following command you can make sure that OS/400 does not split the e-mails at all.

CRTDTAARA DTAARA(QUSRSYS/QTMSNOSPLT) TYPE(*CHAR) LEN(32)

Exit and restart TCP/IP host

Stop the SMTP and POP host functions using the ENDTCPSVR SERVER(SMTP POP) command,* wait a few minutes for the servers to finish, and restart them using the STRTCPSVR SERVER(*SMTP *POP) command.

Automatic start of the TCP/IP servers

directmail needs running SMTP and POP3 servers to send emails. This best option is to start the TCP/IP and the servers from the QSTRUP, this way you are sure that every time you restart the system the servers are active.

IBM i system value for send/receive time

To reflect the correct Central European Time when sending and receiving, taking into account the time difference from GMT time, you must set the system value QUTCOFFSET correctly. During daylight saving time the value must be set to +02:00, during winter time to +01:00. This value can be set via the directmail configuration.

0008 - QUTCOFFSET during summer time