Example: A Connect:Direct process file that calls MFT commands
An example Connect:Direct® process file that calls the Managed File Transfer ftetag command and the ftecxfer command.
In this example, the following actions occur:
- A Connect:Direct COPY statement transfers the file from C:\test\from\sent.txt on the system where the secondary node runs to C:\test\tmp\midpoint.txt on the system where the primary node runs.
- The Connect:Direct process calls the ftetag command to create audit information in MFT.
- The Connect:Direct process calls the ftecxfer command.
- The ftecxfer command transfers the file from C:\test\tmp\midpoint.txt on the system where the primary node runs and the agent CD_BRIDGE runs to /test/to/arrived.txt on the system where the agent LINUX_AGENT is located.
/*BEGIN_REQUESTER_COMMENTS $PNODE$="cd_win01" $PNODE_OS$="Windows" $SNODE$="CD_WIN01" $SNODE_OS$="Windows" $OPTIONS$="WDOS" END_REQUESTER_COMMENTS*/ TESTPRO PROCESS SNODE=CD_WIN01 COPY FROM ( FILE=C:\test\from\sent.txt SNODE ) TO ( FILE=C:\test\tmp\midpoint.txt PNODE DISP=RPL ) COMPRESS Extended RUN TASK PNODE SYSOPTS="pgm(C:\wmqfte\bin\ftetag) args(C:\test\tmp\midpoint.txt)" RUN TASK PNODE SYSOPTS="pgm(C:\wmqfte\bin\ftecxfer) args(-qmgrname QM_CDBA -connname fish.example.com(1441) -channelname SYSTEM.DEF.SVRCONN -sa CD_BRIDGE -da LINUX_AGENT -sm QM_CDBA -dm QM_LINUX -de overwrite -df /test/to/arrived.txt C:\test\tmp\midpoint.txt" PEND