Transferring files and data sets between z/OS and distributed systems

You can transfer files and supported data set types between z/OS® and distributed file systems by using WebSphere® MQ Managed File Transfer. Review the following behavior carefully, which is dependent on the type of system you are transferring from and to.

z/OS support

WebSphere MQ Managed File Transfer Version 7.5 is not available for z/OS. However, this topic contains information about z/OS to allow you to transfer data sets, for example, to and from a version of WebSphere MQ File Transfer Edition running on a z/OS system.

WebSphere MQ Managed File Transfer supports generation data groups (GDGs) for source and destination data sets on z/OS. Absolute and relative GDG names are supported. When you write to a new generation, the base GDG must exist.

When you transfer a file or data set to tape, any existing data set that is already on the tape is replaced. The attributes for the new data set are set from attributes passed in the transfer definition. If no attributes are specified, attributes are set to the same as those attributes for the source data set or are set to the default values when the source is a file. The attributes of an existing tape data set are ignored.

Transferring from a file to a data set - binary transfers

The format of the destination data set determines the destination record length. Ensure the data set exists on the destination system or specify the destination data set with the correct attributes so that the data set is created properly. If you do not specify attributes, the system specifies the following default: a physical sequential data set with an undefined record format and the maximum block size (BLKSIZE) for the device (as returned by the DEVTYPE macro). For example, for DASD the size is 6144 and for tape the size is 32760. If you want to transfer a file on a distributed system to a z/OS data set in binary mode, note the following behavior:

Physical sequential (PS) destination data sets:
  • The source file on the distributed system is read sequentially to fill each record or block.
  • On variable format data sets, each record is filled to capacity.
Partitioned data set (PDS) destination data sets:
  • Each source file is copied to a PDS member with the same or equivalent name. If the file name is longer than the maximum allowed length of a member name, the file name is converted to a valid member name. For more information about member names, see Object naming conventions. If the source file is a directory, each file in that directory becomes a member of the PDS.
  • If a PDS member exists, the member is overwritten if you have specified overwrite existing destination files for the transfer. If you do not specify overwrite, the transfer fails.
  • The source file on the distributed system's is read sequentially to fill each record or block for the member.
  • On variable format PDS members, each record is filled to capacity.

Transferring from a file to a data set - text transfers

The format of the destination data set determines the destination record length. Ensure the data set exists on the destination system or specify the destination data set with the correct attributes so the data set is created properly. If you want to transfer from a file on a distributed system to a z/OS data set as text, note the following behavior:
Physical sequential (PS) destination data sets:
  • Each line of text becomes a record (or a block for undefined record format (RECFM=U) data sets). End-of-line characters are not present in data set records (for non-ASA data sets only).
  • When ASA format control characters are used in the destination data set, end-of-line characters are effectively converted to equivalent ASA format control code.
  • When a line is longer than a record, the line is split at the record boundary and flows onto the next record.
PDS destination data sets:
  • Each source file is copied to a PDS member with the same or equivalent name. If the file name is longer than the maximum allowed length of a member name, the file name is converted to a valid member name. For more information about member names, see Object naming conventions. If the source file is a directory, each file in that directory becomes a member of the PDS.
  • If a PDS member exists, the member is overwritten if you have specified overwrite existing destination files for the transfer. If you do not specify overwrite, the transfer fails.
  • Each line of text becomes a record (or a block for undefined record format (RECFM=U) data sets). End-of-line characters are not present in member records (for non-ASA data sets only).
  • When ASA format control characters are used in the destination data set, end-of-line characters are effectively converted to equivalent ASA format control code.
  • When a line is longer than a record, the line is split at the record boundary and flows onto the next record.

Transferring from a data set to a file - binary and text transfers

If you want to transfer from a data set to a file as binary or text, note the following behavior:

  • The content of each record is transferred in binary form to a file; no record, block format information, or ASA format control characters are transferred.
  • For text transfers only, each data set record becomes a line with text converted to the code page of the destination agent. That is, a carriage return-line feed (CRLF) is appended for a Windows destination system and carriage return (CR) is appended for a UNIX destination system.
  • Non-VSAM and PS source data sets. The records for the source data set are transferred to the destination file and concatenated together. If the destination file exists, the file is overwritten, depending on the destination file behavior option you have specified for the file transfer.
  • PDS source data sets. Each specified member, or all members if no member is specified, is extracted to the destination. If the destination specifies a directory, members are extracted to separate files. Otherwise each specified member is written to the destination file, resulting in effectively only one member being transferred. If the destination file exists for a member, the file is overwritten, depending on the destination file behavior option you have specified for the file transfer.