Use Managed File Transfer for z/OS
Use this topic to help we use Managed File Transfer on the IBM MQ for z/OS system.
Overview
Managed File Transfer for z/OS (MFT) uses the standard z/OS installation procedure. The easiest way of running MFT commands is to use JCL and the JZOS Java Launcher.
See JZOS Batch Launcher and Toolkit for further details.
If your JCL fails to process correctly, see Common MFT problems with JZOS.
Example JCL
//JOHNDOEA JOB 1,MSGCLASS=H // JCLLIB ORDER=(SCEN.MFT.JCL) (1) // INCLUDE MEMBER=BFGJCL8 (2) // DD * (2A) . ${BFG_PROD}/bin/fteBatch createAgent (3) export IBM_JAVA_OPTIONS="${BFG_JAVA_OPTIONS} ${BFG_LANG}" (4) export JZOS_MAIN_ARGS="${BFG_MAIN_ARGS}" (4) //MAINARGS DD * -agentName MYAGENT (5) -f -agentQMgr MQPD -p MQPD /*where:
- (1) Is the location of included JCL statements
- (2) Include the specified JCL member from the location in 1)
- (2A) This extends the //STDENV - see below
- (3) This is the command to be executed, without the leading fte prefix
- (4) These lines are required, they set up information for JZOS
- (5) The parameters to the command
- The BFGJCL8 member (we can select your own name) invokes JZOS. This member has the STEPLIB and other JCL needed to run MFT.
Other JCL we need to include
We should include JCL for the IBM MQ for z/OS libraries, and if we are using the Db2 logger, the Db2 libraries.
For example://WMQFTE EXEC PGM=JVMLDM86,REGION=0M PARM='+T' (1) //STEPLIB DD DSN=SYS1.SIEALNKE,DISP=SHR (2) //* MQ libraries // DD DSN=MQM.V920.SCSQAUTH,DISP=SHR MQ Bindings // DD DSN=MQM.V920.SCSQANLE,DISP=SHR MQ Bindings // DD DSN=MQM.V920.SCSQLOAD,DISP=SHR MQ Bindings //* DB2 libraries // DD DISP=SHR,DSN=SYS2.DB2.V12.SDSNEXIT.DBCP // DD DISP=SHR,DSN=SYS2.DB2.V12.SDSNLOAD // DD DISP=SHR,DSN=SYS2.DB2.V12.SDSNLOD2 //SYSOUT DD SYSOUT=H //SYSPRINT DD SYSOUT=H //STDOUT DD SYSOUT=H //STDERR DD SYSOUT=H //STDENV DD DSN=SCEN.MFT.JCL(BFGZENV8),DISP=SHR (3)where:
- (1) Is the name of the JZOS program. Look in SYS1.SIEALNKE for the version on the system. Add ,PARM='+T' to give additional diagnostics.
- (2) This is the data set with the JZOS program.
- (3) This is the member name of a shell script. It defines parameters needed by MFT. See Shell script to define MFT.
It can be any data set and member. It needs to be last in the file because the JCL job extends this. See 2A in Example JCL.
Shell script to define MFT
In the Other JCL we need to include example, the member BFGZENV8 is used. This is based on the JZOS profile.
We need to know:- The location where Java is installed
- The location of the IBM MQ for z/OS Java libraries and the MFT libraries.
- A user ID needs to be in a specific group to be considered as an IBM MQ for z/OS administrator. You need the name of this group
- If we are not using English for the messages, we need to know which language to specify.
Example file
# This is a shell script that configures # any environment variables for the Java JVM. # Variables must be exported to be seen by the launcher. # Use PARM='+T' and set -x to debug environment script problems set -x # . /etc/profile # # Java configuration (including MQ Java interface) # export _BPXK_AUTOCVT="ON" export JAVA_HOME="/java/java71_bit64_sr3_fp30/J7.1_64/" export PATH="/bin:${JAVA_HOME}/bin/classic/" LIBPATH="/lib:/usr/lib:${JAVA_HOME}/bin" LIBPATH="$LIBPATH:${JAVA_HOME}/bin/classic" LIBPATH=$LIBPATH:"/mqm/V9R2M0/java/lib/" export LIBPATH export BFG_JAVA_HOME="${JAVA_HOME}" export BFG_WTO="YES" export BFG_GROUP_NAME=MQADM export BFG_PROD="/mqm/V9R2M0/mqft" export BFG_CONFIG="/u/johndoe/fteconfig" # export BFG_LANG=" -Duser.language=de " export BFG_LANG=" " ____________________where:
- export _BPXK_AUTOCVT="ON"
- Is required for Unicode conversion
- export JAVA_HOME="/java/java71_bit64/J7.1_64/"
- Is the location of the Java directory. Specify the name of the path for Java. This directory contains bin and other directories.
- export PATH="/bin:${JAVA_HOME}/bin/classic/"
- Sets up the path statement for Java executable statements
- LIBPATH="/lib:/usr/lib:${JAVA_HOME}/bin"
- Sets up the library path for the Java executable statements
- LIBPATH="$LIBPATH:${JAVA_HOME}/bin/classic"
- Adds more Java libraries to the LIBPATH statement.
- LIBPATH=$LIBPATH:"/mqm/V9R2M0/java/lib/"
- Adds IBM MQ for z/OS libraries in the library path. Specify the name of the IBM MQ for z/OS libraries in USS.
- export LIBPATH
- Makes the LIBPATH available to JZOS
- export BFG_JAVA_HOME="${JAVA_HOME}"
- Sets the BFG_JAVA_HOME to the value of JAVA_HOME specified above
- export BFG_WTO="YES"
- Set BFG_WTO to YES causes messages to be displayed on the joblog using WTO
- export BFG_GROUP_NAME=MQADM
- User IDs, which are a member of the specified group, are considered IBM MQ for z/OS administrators
- export BFG_PROD="/mqm/V9R2M0/mqft"
- Is the path where the MFT code is located
- export BFG_DATA="/u/johndoe/fteconfig"
- Is where the MFT configuration information is stored
- # export BFG_LANG=" -Duser.language=de "
- Is a commented out statement to define the language as German
- export BFG_LANG=" "
- Specifies the language as the default, English.
The contents of the MFT product in /lib/messages/BFGNVMessages_*.properties lists the languages available. The default is to leave the value blank, which means that English is used.
Parent topic: Configure Managed File Transfer
Related tasks
Related information