Configuring the End-of-Line Marker

The mainframe FTP appends an end-of-line marker to each record. FTP clients on distributed platforms do not do this as they have no concept of a record.

An instruction to append this end-of-line marker can be sent to MFFTP when issuing a PUT command.

By default, no marker is added. You can set it either at the job step level using the ENVVAR DD statement or at server level using the following control variable:

MFFTP_SENDEOL=xxxx

Where xxxx equals one of the following:

NONE
Adds nothing
CRLF
Adds a carriage return and a line feed (x’0D0A’)
CR
Adds a carriage return (x'0D')
LF
Adds a line feed (x’0A’)

You can also use the LOCSITE command to set the end-of-line marker. In this case, the variable name is either SBSENDEOL or MBSENDEOL, and the supported values are NONE, CRLF, CR, or LF. For example:

LOCSITE SBSENDEOL=CRLF

The LOCSITE command overwrites any other control settings and may be varied during a session. This allows you to transfer one file with a CRLF and the next one - without it.

If you use an SBSENDEOL or an MBSENDEOL followed by a space, the variable can be placed in the SYSFTPD file.

Note: If SENDEOL is specified, the original physical file is not transferred. Instead, a copy of the file is made with the name ftp.jxxxxxxx.snnn.eol.zzzz (where xxxxxxx is the JES job number, nnn is the step number and zzzz is a sequence starting at 1 for this invocation of MFFTP). This file contains the appropriate end-of-line characters and is the file that is transferred.

By default, when MFFTP terminates, this file is deleted. To keep the file, you need to set MFFTP_KEEP to Y. If SENDEOL is set to NONE and a GET is performed for a variable record file, the results are unlikely to be as expected, as the program has no way of determining the end of each record in the fetched file.