Client Documentation
3.3. File transfer¶
This section describe the configuration options availalbe for defining the rules for performing file transfers.
3.3.1. Generic¶
The options are available to all transfer types.
3.3.1.1. remotedir¶
Optional: | No |
---|---|
Default value: | None |
Values: |
|
From version: | 1.5.1 |
To version: | None |
Description: | Remote folder use as base folder to and from where files are transferred. This need to be an absolute path, using the path convention used by the remote server. |
3.3.1.2. filemask¶
Optional: | Yes |
---|---|
Default value: | None |
Values: |
|
From version: | 1.5.1 |
To version: | None |
Description: | Restrict files by mask. For example ‘*.pdf’ for all PDF files. For recursive transfer, the filemask is only applied to file names and is not applied to folder names. Unix globbing expressions are accepted:
You can also use regular expressions, by configuration the global.conf file to global.force_regex = ‘y’. In this case you can match a file starting with either A or B, and ending with either ‘.doc’ or ‘.txt’ using:
The following characters are converted in the expression as per below:
Only limited regular expression support is available. Supported:
Currently not supported:
|
3.3.1.3. recursive¶
Optional: | Yes |
---|---|
Default value: | ‘n’ |
Values: |
|
From version: | 1.5.1 |
To version: | None |
Description: | Transfer files from all folders located inside the local or remote base folder. Empty folders are ignored. |
3.3.2. PUT options¶
The following options are only available for put transfer types.
By default for put transfer each local file is sent as a separate transfer, with postprocess commands called for each file from the transfer.
3.3.2.1. targettimestamp¶
Optional: | Yes |
---|---|
Default value: | ‘y’ |
Values: |
|
From version: | 1.5.1 |
To version: | None |
Description: | Add timestamps to file name to ensure uniqueness. |
3.3.2.2. createmd5sum¶
Optional: | Yes |
---|---|
Default value: | ‘n’ |
Values: |
|
From version: | 1.5.1 |
To version: | None |
Description: | Create the local md5sum file. |
3.3.2.3. sendmd5sum¶
Optional: | Yes |
---|---|
Default value: | ‘n’ |
Values: |
|
From version: | 1.5.1 |
To version: | None |
Description: | Send an md5sum file with the main file. |
3.3.2.4. forcelowercase¶
Optional: | Yes |
---|---|
Default value: | ‘n’ |
Values: |
|
From version: | 1.5.1 |
To version: | None |
Description: | Set it to ‘y’ to force use of lower-case filenames on case-sensitive platforms (Example: MS Windows). |
3.3.2.5. putbatch¶
Optional: | Yes |
---|---|
Default value: | ‘n’ |
Values: |
|
From version: | 1.5.52 |
Description: | When enabled it will send all local files as a single transfer. preprocess is called before transferring the first file and postprocess after transferring the last file. Otherwise each file is done in a separate transfer with preprocess and postprocess commands called for each file from the transfer. Note This is only available for transfers of type sftp. |
3.3.3. GET options¶
The following options are only available for get type transfers.
All remote files are received in a single transfer, with preprocess commands called before receiving the first file and postprocess called after receiving the last file.
3.3.3.1. remotefile¶
Optional: | No |
---|---|
Default value: | None |
Values: |
|
From version: | 1.5.1 |
To version: | None |
Description: | Set this value to ‘*’ to enable the usage of filemask option. For more details about specifying what files should be retrieved, please check filemask option. |
3.3.3.2. suppressnomatcherror¶
Optional: | Yes |
---|---|
Default value: | ‘n’ |
Values: |
|
From version: | 1.5.1 |
To version: | None |
Description: | Useful when used in combination with deleteaftertransfer = ‘y’ option. When set to ‘y’ will prevent the client from interpreting an empty file list on the server (see filemask) as an error. |
3.3.3.3. deleteaftertransfer¶
Optional: | Yes |
---|---|
Default value: | ‘n’ |
Values: |
|
From version: | 1.5.1 |
To version: | None |
Description: | After a transfer, the original file is deleted. Note This option deletes only the files and not the folders containing the files. Empty folders are left unremoved. |
3.3.3.4. onlynewfiles¶
Optional: | Yes |
---|---|
Default value: | ‘0’ |
Values: |
|
From version: | 1.5.60 |
To version: | None |
Description: | Ignore transferring files which were previously transferred as part of this transfer configuration in the last N configured seconds. Only the file name is used to check if the file was previously transferred. If a file with the same name but with different content is found, it will not be transferred. The configured number of seconds defines the time interval after which files already transferred are removed from the transfer memory. Set it to 0 to always transfer files located in the remote location and not use the transfer memory. Note This option is only available for configurations for which transfers are done based on filemask and remotefile = * Warning The list of transferred files is persisted as several empty files on the local filesystem. These files are located in the SFTPPlus client temporary directory and are named memory_TRANSFER_ID. |
3.3.3.5. maxfileage¶
Optional: | Yes |
---|---|
Default value: | ‘0’ |
Values: |
|
From version: | 1.5.64 |
To version: | None |
Description: | Skip downloading remote files that have a last modification date/time older than the configured amount (in seconds). Set it to 0 to always transfer files regardless of their age. Note This option is only available for configurations for which transfers are done based on filemask and remotefile = * Warning The comparison is done using the local date and time from the machine running the client. Warning Care should be used when enabling the setting as the date/time format is non standardized for FTP/FTPS protocols. It supports values in one of the following formats:
Please get in touch if the remote server uses a different format. |
3.3.3.6. timestamp¶
Optional: | Yes |
---|---|
Default value: | ‘y’ |
Values: |
|
From version: | 1.5.1 |
To version: | None |
Description: | Add timestamp to local file when retrieved. |
3.3.3.7. getmd5sum¶
Optional: | Yes |
---|---|
Default value: | ‘n’ |
Values: |
|
From version: | 1.5.1 |
To version: | None |
Description: | Try to get md5sum file from remote system. |