The TRANSFERCODETYPE statement specifies an ASCII, binary, auto-detect, or EBCDIC transfer, FTP communication type (SSL or regular), and compression level in an FTP job.
Supported Job Type
This statement is required for the FTP job type.
Syntax
This statement has the following format:
TRANSFERCODETYPE [A|B|E|U]
[SSL(YES|NO)]
[COMPRESS(0|1|2|3|4|5|6|7|8|9)]
Indicates an ASCII transfer.
i5/OS:
Indicates a binary transfer.
Indicates an EBCDIC transfer.
Note: E applies to CA WA Agent for i5/OS only. If an EBCDIC file to be transferred already exists on the target computer, the file is written using the encoding of the existing file. If the file does not exist, the file is written using the EBCDIC CCSID (Coded Character Set Identifier) defined on the agent. The default is 37.
Indicates an auto-detect transfer.
Note: You can specify auto detect for uploads only.
i5/OS: If the source file to be uploaded is EBCDIC, but the target does not support EBCDIC transfers, the job fails.
Specifies whether to transfer the data with Secure Sockets Layer (SSL) communication or regular communication.
Transfers the data using SSL FTP.
Transfers the data using regular FTP.
Note: If the SSL operand is not specified, the data is transferred using the communication type set in the ftp.client.ssl parameter on the agent FTP client. This parameter is automatically set to false by default (regular communication is used).
Specifies the data compression level.
Limits: 0-9 (0 is no data compression and 9 is the highest data compression)
Default: 0
Note: If the COMPRESS operand is not specified, the data is compressed using the level set in the ftp.data.compression parameter on the agent FTP client. This parameter is automatically set to 0 by default (no data compression).
Notes:
The agent administrator can enable or disable SSL on the agent FTP client using the ftp.client.ssl parameter in the agent parameter file (agentparm.txt) as follows:
Example: Download a Binary File on UNIX
The FTP job in this example uses a binary transfer.
AGENT UNIXAGENT USER test SERVERADDR hpunix SERVERPORT 5222 TRANSFERDIRECTION D TRANSFERCODETYPE B REMOTEFILENAME /u1/test/ftpdata/WAmgr LOCALFILENAME /export/home/test/ftpdata/transf.bin
Example: Download a Binary File on Windows
The FTP job in this example uses a binary transfer.
AGENT WINAGENT USER test SERVERADDR hpunix SERVERPORT 5222 TRANSFERDIRECTION D TRANSFERCODETYPE B REMOTEFILENAME /u1/qatest/ftpdata/WAmgr LOCALFILENAME c:\qatest\ftpdata\transf.bin
Example: Upload an ASCII-encoded File in the Root File System from an i5/OS System to a UNIX System
This example uploads an ASCII file named textfile in the root file system from an i5/OS system and copies it to a UNIX system:
AGENT I5AGENT USER test SERVERADDR hpunix SERVERPORT 5222 TRANSFERDIRECTION UPLOAD TRANSFERCODETYPE A LOCALFILENAME /home/ftp/textfile REMOTEFILENAME /u1/test/ftpdata/textfile
Example: Upload a File from a Local Computer to a Remote Windows Server Using SSL FTP
In this example, the agent runs on a local computer as an FTP client and has SSL FTP configured but not enabled. The remote Windows server has SSL FTP configured and enabled.

The following FTP job uploads the filename.txt file from the agent FTP client to the c:\uploaded_files directory on a remote Windows server. The SSL operand in the TRANSFERCODETYPE statement is set to YES to transfer the file securely. Although the agent FTP client does not have SSL FTP enabled, the file will be uploaded using SSL FTP because the configuration requirements are met (the agent FTP client has SSL FTP configured and the FTP server has SSL FTP enabled).
AGENT WINAGENT USER user1 SERVERADDR winserver SERVERPORT 21 TRANSFERDIRECTION U TRANSFERCODETYPE U SSL(YES) REMOTEFILENAME c:\uploaded_files\filename.txt LOCALFILENAME d:\files_to_upload\filename.txt
Example: Download a File from a Remote UNIX Server that Does Not Support SSL FTP to a Local Computer That Supports SSL FTP
In this example, the agent runs on a local computer as an FTP client and has SSL FTP enabled (all FTP jobs on the agent computer run using SSL FTP by default). The remote UNIX server does not support SSL FTP.

The following FTP job downloads the filename.txt file from the remote UNIX server to the c:\downloaded_files directory on the local computer. Because the FTP server does not support SSL FTP, the SSL operand in the TRANSFERCODETYPE statement is set to NO so the job does not fail.
AGENT WINAGENT USER user1 SERVERADDR hpunix SERVERPORT 5222 TRANSFERDIRECTION D TRANSFERCODETYPE A SSL(NO) REMOTEFILENAME /files_to_download/filename.txt LOCALFILENAME c:\downloaded_files\filename.txt
Example: Download a QSYS EBCDIC-Encoded File
This example downloads an EBCDIC-encoded file named DATAFILE in the QSYS file system from an i5/OS system to another i5/OS system. The file names are specified in the path format.
AGENT I5AGENT USER test SERVERADDR i5agent SERVERPORT 5222 TRANSFERDIRECTION DOWNLOAD TRANSFERCODETYPE E LOCALFILENAME /QSYS.LIB/FTPLIB.LIB/DOWNLOAD.FILE/DATA.MBR REMOTEFILENAME /QSYS.LIB/DATALIB.LIB/DATAFILE.FILE/DATA.MBR
Example: Compress a File
In this example, the local computer has an agent running as an FTP client. The remote computer has an agent running as an FTP server. Both computers operate on a low bandwidth network.
The following FTP job downloads a large file named largefile.txt from the remote server to the FTP client. The computers are on a low bandwidth network, so the data is compressed at compression level 3.
AGENT WINAGENT USER user1 SERVERADDR aixunix SERVERPORT 5222 TRANSFERDIRECTION D TRANSFERCODETYPE A COMPRESS(3) REMOTEFILENAME /files_to_download/largefile.txt LOCALFILENAME c:\downloaded_files\largefile.txt
|
Copyright © 2013 CA Technologies.
All rights reserved.
|
|