Table Of Contents
Configuring User-Level Services
Configuring Simple Mail Transfer Protocol (SMTP) Facilities
Customizing Your Mail Environment
User/Server SMTP Segment (SMTP)
User and Server SMTP Operands Syntax
User and Spooler Operands Syntax
Mail Customization (SMTP)
The SMTP statement defines the Simple Mail Transfer capability of Cisco IOS for S/390. It works in conjunction with a mainframe mail agent and provides the interface for mail to and from the network.
This chapter provides guidelines to help you customize your SMTP service. It includes the following sections:
•Configuring User-Level Services
Describes how to configure the SMTP from the user-level services.
•Configuring Simple Mail Transfer Protocol (SMTP) Facilities
Describes how to configure the SMTP facilities.
•User/Server SMTP Segment (SMTP)
Describes how to define your electronic mail service parameters using SMTP.
Describes how to use the SMTP.
Configuring User-Level Services
The SERVICE statements define the user-level services provided by Cisco IOS for S/390 and the well-known port numbers. The most common ones are Telnet, VTAMAPPL, FTP, LPR, and USMTP/SSMTP. For a complete description of the SERVICE statement, read Protocol Service Segment (SERVICE).
SERVICE NAME (service)
MODULE (STELNET | FTPS | SSMTP | USPOOL | STECHO |
SCHARGEN | UDPSERV | SPOOL#4 | VTAMAPPL | USMTP)
To configure the SMTP services, you will need to set the following:
SERVICE NAME (SMTP)
to provide SMTP mail server
SERVICE NAME (SPOOL#4)
to provide the mail spooler
SERVICE NAME (USMTP)
to provide the SMTP mail sender
SMTP Example
Server SMTP (Port 25)
SERVICE NAME(SMTP)MODULE(SSMTP)PORT(25)TCPConfiguring Simple Mail Transfer Protocol (SMTP) Facilities
This section describes how to configure the Simple Mail Transfer Protocol (SMTP) facilities within Cisco IOS for S/390. First, you may need to change the following parameter on the SMTP statement. The high-level qualifier for the PATH parameter must not be the same high-level qualifier that was used for the Cisco IOS for S/390 data sets.
Mail Service Statements
There are three SERVICE statements in the APPCFGxx file for mail services. These parameters are used by the mail spooler, client SMTP, and server SMTP. Client SMTP only runs if there is a SERVICE statement for USMTP. Server SMTP only runs if there is a SERVICE statement for SSMTP.
The mail spooler retrieves mail deposited on the JES spool by a user mail agent and queues it for client SMTP on the Cisco IOS for S/390 mail spool. If a user mail agent has not been installed on the system, it is not necessary to continuously run the Cisco IOS for S/390 mail spooler. To prevent the mail spooler from being started, delete the SERVICE statement for SPOOL#4 in the APPCFGxx member.
The SNDMSG program uses these configuration operands:
SPACEUNITVOLUMEPATHThese APPCFGxx statements define Cisco IOS for S/390 mail services (SMTP):
SERVICE NAME(SMTP) MODULE(SSMTP) PORT(25)SERVICE NAME(USMTP) MODULE(USMTP) PORT(25)SERVICE NAME(SPOOL) MODULE(SPOOL#4) PORT(25)* SIMPLE MAIL TRANSFER PROTOCOL PARAMETERSSMTP CYCLE(3 10 1)MXRETURN(Y LOCAL)RTNWTR(UNDWTR)WKSMXDIVERT(X 9999999)INBXFLD(1)ROUTE(X LOCAL)SXWTR(INBWTR)PRINTALLLRECL(132)OUTLIM(250000)TRACECHARSET(CHAR)REMOTE(1)SPACE(1 5)PATH(T01TCP.V2.EMAIL)PORT(25)UNIT(DISK)VOLUME(MVSTO5)TRANTBL(ENGLISH)FLIST(0)Customizing Your Mail Environment
Use these steps to tailor SMTP with site-specific information:
Step 1 In this example for minimal site configuration, the SMTP statement defines a configuration that does not require a mail agent.
Many Cisco IOS for S/390 sites are able to send and receive mail if a site has minimally configured these SMTP parameters:
SMTP DIVERT(X 9999999)
LRECL(132)
NOMX
PATH(T01TCP.EMAIL)
RETURN(Y LOCAL)
ROUTE(X LOCAL)
UNIT(SYSALLDA)
VOLUME(SYSTSO)
Configure the DIVERT, LRECL, MX, PATH, RETURN, ROUTE, VOLUME, and UNIT parameters on the SMTP statement to match site-specific needs. All other SMTP parameters either default to correct values or are used by installations that require additional flexibility in routing mail.
Step 2 For SMTP mailbox names configure the SMTPUSR entries in the SMTPUSR member in the SAMP data set to site requirements. Replace the names, TSO IDs, and signatures in the SMTPUSR entries with those of the SMTP users at your installation.
SMTP 'JQD','DOE','JOHN Q. DOE'
The first entry to this SMTPUSR macro (JQD) is the TSO user ID for the user. The next entry (DOE) is the name of the mailbox for this user. The last entry (JOHN DOE) is the signature to be used on mail sent by this user.
The outbound mail handler checks all SMTPUSR entries to see if the user on the `x-from' header matches a TSO user ID in the SMTPUSR table. If a match is found, the mailbox name replaces the TSO user ID on the MAIL FROM: command for the outgoing message.
The inbound mail handler checks all SMTPUSR entries to see if the user on the RCPT TO command matches a mailbox name in the SMTPUSR table. If a match is found, the TSO user ID replaces the mailbox name in the inbound mail message `X-to' header.
An entry for the postmaster should be defined at all sites. In this example, TSO user ID JQD receives messages sent to POSTMASTER.
SMTPUSR 'JQD','POSTMASTER'
The SMTPUSR table should contain a minimum of one TSO user ID that also serves as a postmaster. If you do not want to send out TSO user IDs and mailbox names on messages, you can set up the SMTPUSR table with user JQD as the postmaster:
SMTPUSR 'JQD','JQD','JQD'
SMTPUSR 'JQD','POSTMASTER'
SMTPUSR ,
Execute the usermod UMODSMTP in the CNTL data set to assemble and link SMTPUSR.
An exit routine follows the mailbox names in SMTPUSR. This routine gets control when the search of the mailbox name table fails. It sets a return code to accept or reject the argument name. See the SMTPUSR SAMP member for more details.
Step 3 SMTP requires that a data set naming convention be established for outgoing mail. Use the PATH parameter on the SMTP statement to specify the high-level qualifier(s) for your installation's outgoing SMTP mail data set names.
Mail data sets are created on the unit and volume specified on the SMTP statement's UNIT and VOLUME parameter. Mail data sets are deleted once they are successfully transferred. The @MAILDB@ data set is created when USMTP is started for the first time. It is not deleted on termination of SMTP.
In this example, the SMTP statement defines a configuration that does not require a mail agent. The parameters specify:
•A default volume of SYSTSO
•A high-level qualifier of T01TCP.EMAIL
•A return SYSOUT class of Y for unknown mail
•Diverts all incoming deliverable mail to the local printer using SYSOUT class X
SMTP DIVERT(A 0)
LRECL(132)
PATH(T01TCP.EMAIL)
RETURN(Y LOCAL)
ROUTE(X LOCAL)
SPACE(1 5)
UNIT(DISK)
VOLUME(SYSTSO)
Step 4 For incoming mail destination, SMTP requires SYSOUT classes and destination IDs for each installation. The class and destination IDs determine where to queue incoming and undeliverable mail. You can optionally specify an external writer program ID for incoming and undeliverable outbound mail JES SYSOUT data sets.
All these parameters are described on the SMTP statement in APPCFGxx in User/Server SMTP Segment (SMTP):
The ROUTE parameter specifies the JES output class and destination to route incoming mail.
The RETURN parameter specifies the JES output class and destination ID to be used to return outgoing mail that cannot be delivered.
The DIVERT parameter specifies the JES output class and the maximum number of characters not to be exceeded before the incoming mail is diverted to a local printer. A value of zero causes all incoming mail to be diverted to the printer, which is appropriate when there is no mail handling facility to receive incoming mail.
The SXWTR parameter can be used to place an external writer program ID on inbound mail JES SYSOUT mail data sets.
Step 5 An alternative method for sending outgoing mail is through the JES2 spool. To use the JES2-to-SMTP interface, select a remote job entry terminal number and make the appropriate definition in your JES2 parameters. A sample of these parameters is in the JES2PARM member of the SAMP data set. You may need to tailor these parameters to your installation. Note that some of the JES2 parameters must agree with SMTP parameters in the APPCFGxx SMTP statement, so if you change a JES2 parameter, be sure to change the corresponding SMTP parameter. This step is optional.
SPOOL#4 and USMTP share parameters specified on the SMTP statement in the file APPCFGxx. These are the parameters that an installation must update on an SMTP statement in file APPCFGxx for SPOOL#4:
SMTP PATH (mail_path_name)
REMOTE(remote#)
UNIT(unit)
VOLUME(volser)
The PATH parameter is the 1 to 17 character high level qualifier for mail data sets. The UNIT and VOLUME parameters define a valid unit/volser combination for mail data set allocation at your installation. The REMOTE parameter can either be the remote name or the destination name for the remote. Remote RMT20 defined to JES2 with a destination name of R20A allows any of these on the REMOTE parameter:
REMOTE(R20)
REMOTE(R20A)
REMOTE(RMT20)
If a password is needed for the remote, place it in the PASSWORD parameter.
Define the SPOOL service in APPCFGxx with a SERVICE statement:
SERVICE NAME (SPOOL#4) MODULE (SPOOL#4) PORT (25)
SPOOL#4 uses the subsystem interface to retrieve mail from the JES2 spool and create mail data sets on the DASD volume specified on the VOLUME statement.
Make the changes below only if your user mail agent sends outgoing mail to Cisco IOS for S/390 through the JES2 spool (see member JES2PARM in the SAMP library).
DEST(R20A) DEST=R20
/* */
RMT(20) DEVTYPE=LUTYPE1,
CONS=YES,
NUMPU=1,
BUFSIZE=256
/* */
R(20).PR(1) LRECL=255,
UCS=TN,
CKPTPAGE=999,
CLASS=F
/* */
R(20).PU(1) LRECL=255,
SEP=NO
/* */
R(20).RD(1) CLASS=A
*
OUTCLASS(E) BLNKTRNC=YES,CONDPURG=NO,
MSGHOLD=NO,OUTPUT=PRINT,TRKCELL=YES
OUTCLASS(F) BLNKTRNC=YES,CONDPURG=NO,
MSGHOLD=NO,OUTPUT=PRINT,TRKCELL=YES
User/Server SMTP Segment (SMTP)
Use the SMTP statement to define the following electronic mail service parameters:
User SMTP Operands Syntax
SMTP RTNWTR (name)
[CYCLE (minute retry limit)]
[FLIST (number)]
[MX | NOMX]
[RETURN (class destination)]
[UMAPTEMP (number number...)]
[WKSMX | NOWKSMX]
Server SMTP Operands Syntax
[DIVERT (class number)]
[INBXFLD (1 | 2)]
[PRINTALL | NOPRINTALL]
[ROUTE (class destination)]
[RTNGAT (gat_name)]
[SXGAT (gat_name)]
[SXWTR (name)]
User and Server SMTP Operands Syntax
[LRECL (number)]
[OUTLIM (number)]
[POSTM | NOPOSTM]
[TRACE | NOTRACE]
[TRANTBL (tranname)]
Spooler SMTP Operands Syntax
[JES3CWTR (class writer_name)]
[PASSWORD (password)]
[REMOTE (number)]
[SPACE (primary secondary)]
User and Spooler Operands Syntax
[PATH (name)]
[PORT (number)]
[UNIT (unitname)]
[VOLUME (name)]
Syntax Description
RTNWTR (name)
Specifies the external writer program ID for all undeliverable outbound mail messages.
Default: None
CYCLE (minutes retry limit)
Specifies in sublist notation the client USMTP service cycle (in minutes), retry delay (in minutes), and retry limit (in hours). Service cycle must not exceed retry delay, which must not exceed retry limit.
Default: (3 10 96)
DIVERT (class number)
Specifies the JES output class and maximum number of characters that, when exceeded, cause incoming mail to be diverted to a local printer. Specifying zero for the number of characters causes all mail to be diverted to the printer. Range for number is 0 to 9999999.
Default: (A 0)
FLIST (number)
Specifies the number of entries to reserve for a table of IP hosts that had temporary failures during the outbound mailer (USMTP) send cycle. Once an outbound mail attempt fails with a non-permanent error to a host during a send cycle, all subsequent mail requests during the cycle to the host will not be attempted.
The FLIST feature prevents a bad mail host from backing up the outbound mail queue with a number of temporary errors.
Default: 0 Range: 0 - 9999
INBXFLD (1 | 2)
SSMTP folds the X-FROM and X-TO headers for inbound mail that are longer than the record size for the file. This parameter instructs SSMTP which column to continue on the next line when folding X-headers.
Default: 2
JES3CWTR (class writer_name)
Allows JES3 users to use SPOOL#4. JES2 users continue to code the REMOTE parameter, but JES3 users must code JES3CWTR.
class specifies the JES3 HELD class. This can be only one character.
writer_name specifies the JES3 external writer name. This ia a maximum of 8 characters and a minimum of 1 character.
See JES3CWTR Usage for more information on JES3CWTR.
Default: None
LRECL (number)
Specifies the logical record length of the mail file to create.
Default: 80
MX | NOMX
If MX is specified, USMTP makes a DIRSRV call for a mail route on outbound mail. The X-TO headers issue a GET ROUTE BYNAME DIRSRV call. The DIRSRV GET ROUTE BYNAME call returns MX records to route outbound mail.
If NOMX is specified, USMTP attempts to deliver mail only to the host on the X-TO header. This parameter should generally be set to MX to recognize mail routing.
Default: NOMX
OUTLIM (number)
Specifies the maximum number of lines a mail data set can contain on the JES spool. It is used as the OUTLIM parameter to JES.
Default: 250000
PASSWORD (password)
Specifies the password for the JES remote terminal.
Default: None
PATH (pathname)
Specifies the path name (in other words, data set name prefix used for mail spool data set names (1 to 44 characters)). This qualifier should be different from the qualifier used for the other Cisco IOS for S/390 data sets or SMTP will attempt to send these data sets.
Default: TCPICS.EMAIL
PORT (number)
Specifies the port number for mail to use. For operation with UNIX mail, the port number must be 25.
Default: 25
POSTM | NOPOSTM
Specifies if a copy of any returned mail is to be sent to the postmaster.
Default: POSTM
PRINTALL | NOPRINTALL
Specifies whether to print trace results produced by the TRACE parameter.
Default: NOPRINTALL
REMOTE (number)
Specifies parameters for the destination ID from which the mail spooler receives outbound mail. The ID number operand is the JES remote terminal ID number.
Default: None
RETURN (class destination)
Specifies the JES output class and destination ID used to return outbound mail that cannot be delivered.
Default: (Y LOCAL)
ROUTE (class destination)
Specifies the JES output class and destination ID used to route inbound mail.
Default: (X LOCAL)
RTNGAT (gat_name)
Specifies the GAT for allocation of the SYSOUT DSN for undeliverable mail. The name must point to an applicable GAT statement. For more information about the GAT Statement, read Chapter 11, .
Default: None
SPACE (primary secondary)
Specifies primary and secondary space allocation for outbound mail in units of tracks (0-65535). Unused space is released.
Default: (5 15)
SXGAT (gat_name)
Specifies the GAT name for allocation of the SYSOUT DSN for inbound mail. The name must point to an applicable GAT statement. For more information about the GAT Statement, read Chapter 11, .
Default: None
SXWTR (name)
Specifies the external writer program ID files for all inbound mail messages.
Default: None
TRACE | NOTRACE
Specifies whether to produce tracing information for debugging mail problems.
Default: NOTRACE
TRANTBL (tranname)
Specifies the translate table load module to be used.
tranname can be one of the following:
•ENGLISH
•FRENCH
•GERMAN
•GSWISS
•ITALIAN
For more information about special translate tables, read Chapter Chapter 19, .
Default: Translate table specified by TRANTBL parameter on GLOBAL statement in APPCFGxx configuration member.
UNIT (unitname)
Specifies a unit name for mail data sets
Default: SYSALLDA
UMAPTEMP (number, number...)
Specifies an error code that is returned by a mailer as a permanent error and instructs the Cisco IOS for S/390 mailer to accept it at a temporary error. These permanent errors can be returned when attempting to deliver a message to a group of users. By specifying that this error be treated as a temporary error, the destination is automatically retried until the send retry limit is reached. Return codes recognized as permanent errors instruct the outbound mailer USMTP to not attempt redelivery.
Read UMAPTEMP Usage for more information about how to use the UMAPTEMP parameter.
Default: None
VOLUME (name)
Specifies a permanently resident volume name containing the outbound mail spool (1 to 6 characters).
Default: None
WKSMX | NOWKSMX
Specifies whether to issue a DIRSRV request for well-known services before connecting to a host, to verify that it supports the mail protocol. Since this step is generally not needed, the default is NOWKSMX.
Default: NOWKSMX
Note Read the Cisco IOS for S/390 User's Guide for information on SNDMSG.
SMTP Usage Notes
JES3CWTR Usage
For JES2, a typical SYSOUT DD will be similar to the following:
//OUTPUT DD SYSOUT=A,DEST=(R22A)For JES3, a typical SYSOUT DD will be similar to the following:
//*OUTPUT DD SYSOUT=(X,SNSWTR)where SNSWTR specifies the external writer name.
UMAPTEMP Usage
UMAPTEMP gives the site the ability to interpret a permanent error that occurs during outbound mail delivery as a temporary and to attempt redelivery of the message for the affected user during the next schedule cycle.
Note This feature should not be used for errors that are transient in nature.
The UMAPTEMP parameter works in conjunction with the FLIST parameter when the number specified for FLIST is greater than zero. To use the UMAPTEMP parameter, code a positive number in the FLIST parameter.
Table 12-1 gives the possible return codes for an attempted delivery for a set of users.
Table 12-1 Use of UMAPTEMP with mail return codes
Table 12-2 contains the return code from the attempted delivery, the message text about the attempted delivery, and a more detailed explanation:
Using SMTP
In order to use the SMTP facility, uncomment the three SERVICE statements mentioned earlier
SMTP CYCLE(3 10 1)DIVERT(X 9999999)LRECL(132)NOMXPATH(T01TCP.V2.EMAIL)ROUTE(X LOCAL)RETURN(Y LOCAL)UNIT(SYSALLDA)TRANTBL(ENGLISH)Usage Notes for SMTP
Parameter Usage
These parameters are used by the mail spooler, client SMTP, and server SMTP.
Mail Spooler
The mail spooler retrieves mail deposited on the JES spool by a user mail agent and queues it for client SMTP on the Cisco IOS for S/390 mail spool. If a user mail agent has not been installed on the system, it is not necessary to continuously run the Cisco IOS for S/390 mail spooler. To prevent the mail spooler from being started, delete the SERVICE statement for SPOOL#4 in the APPCFGxx member.
USMTP
Client SMTP only runs if there is a SERVICE statement for USMTP.
SSMTP
Server SMTP only runs if there is a SERVICE statement for SSMTP.
SNDMSG
The SNDMSG program uses these configuration operands:
SPACEUNITVOLUMEPATHSMTP Examples
This example shows the usage of the SMTP statement:
SMTP CYCLE(3 30 48)DIVERT(A 0)MXPATH(TCPICS.MAIL)REMOTE(5)RETURN(Y LOCAL)ROUTE(X LOCAL)SPACE(1 5)VOLUME(MVSTSO)OUTLIM(35000)LRECL(125)UNIT(3380)
Note If you will be using the mail facility (SMTP), you can uncomment the SERVICE statements for USMTP, SSMTP and SPOOL#4.
SERVICE NAME(TELNET) MODULE(STELNET) PORT(23) IDLE(480)SERVICE NAME(VTAMAPPL) MODULE(VTAMAPPL) PORT(23) NOCPASSWORDSERVICE NAME(TELNET) MODULE(STELNET) PORT(1023) AUTO(TSO) IDLE(480)SERVICE NAME(FTP) MODULE(FTPS) PORT(21) IDLE(300)SERVICE NAME(LPR) MODULE(USPOOL) PORT(515)SERVICE NAME(LPR) MODULE(USPOOL) PORT(516)SERVICE NAME(UDPE) MODULE(UDPSERV) PORT(7) UDPSERVICE NAME(UDPC) MODULE(UDPSERV) PORT(9) UDP* SERVICE NAME(USMTP) MODULE(USMTP) PORT(25)* SERVICE NAME(SSMTP) MODULE(SSMTP) PORT(25)* SERVICE NAME(SPOOL#4) MODULE(SPOOL#4) PORT(25)