5 Oracle Managed File Transfer Custom WLST Commands

This chapter summarizes WLST (Oracle WebLogic Scripting Tool) commands that perform Oracle Managed File Transfer (MFT) operations.

This chapter includes the following sections:

For general information about WLST, see the WLST Command Reference for WebLogic Server.

For general information about MFT, see Using Oracle Managed File Transfer.

5.1 Overview of MFT WLST Command Categories

MFT WLST commands are divided into the following categories.


Table 5-1 MFT WLST Command Categories

Command Category Description

MFT Artifact Management Commands

Perform these operations on source, transfer, and target artifacts: enable, disable, deploy, undeploy, delete, export, check existence in the Metadata Store (MDS).

MFT Metadata Commands

Export, import, and reset MFT metadata.

MFT Key Management Commands

Generate, import, export, delete, list, and update SSL, SSH, and PGP keys in the MFT keystore.

MFT Deployment History Commands

View the deployment history of source, transfer, and target artifacts.

MFT Transfer Management Commands

Pause, resume, resubmit, or display information about transfer instances.

MFT Embedded Server Commands

Start, stop, and change ports of embedded FTP and sFTP servers.

MFT Callout Commands

Create, delete, list, and update custom callouts.

MFT Event Notification Commands

  • Create, delete, and list contacts

  • Add and remove contacts from event notifications

  • Enable and disable event notifications

MFT Archive and Restore Commands

Archive transfer instances or file system data based on criteria such as status and date ranges.

MFT Purge Commands

Purge transfer instances or file system data based on criteria such as status and date ranges.


5.2 MFT Artifact Management Commands

Use the MFT WLST Artifact Management commands, listed in Table 5-2, to perform operations on source, transfer, and target artifacts.


Table 5-2 MFT Artifact Management WLST Commands

Use this command... To... Use with WLST

bulkDeployArtifact

Deploys multiple source, transfer, or target artifacts.

Online or Offline

deleteArtifact or delAF

Delete a source, transfer, or target artifact.

Online or Offline

deleteArtifactDeployment or delDepAF

Delete an undeployed source, transfer, or target artifact.

Online or Offline

deployArtifact or depAF

Deploy a source, transfer, or target artifact.

Online or Offline

disableArtifact or disAF

Disable a deployed source, transfer, or target artifact.

Online or Offline

enableArtifact or enAF

Enable a deployed source, transfer, or target artifact.

Online or Offline

exportDeployedArtifact or expDepAF

Export a deployed source, transfer, or target artifact to a ZIP file.

Online or Offline

isArtifactInMDS or isAFinMDS

Check whether a source, transfer, or target artifact exists in the MDS (Metadata Store).

Online or Offline

undeployArtifact or undepAF

Undeploy a source, transfer, or target artifact.

Online or Offline


5.2.1 bulkDeployArtifact

Command Category: MFT Artifact Management Commands

Use with WLST: Online or Offline

5.2.1.1 Description

Bulk deploys multiple source, transfer, or target artifacts. In the event of an unsupported operation, the command returns a WLSTException.

5.2.1.2 Syntax

bulkDeployArtifact(artifact_type, artifact_names, comment)
Argument Definition
artifact_type

Artifact type: SOURCE, TRANSFER, or TARGET.

artifact_names

Comma-separated artifact names, or * for all.

comment

Text string describing the artifacts or the reason for deploying them.

5.2.1.3 Example

The following example deploys two SOURCE artifacts and provides a comment.

bulkDeployArtifact('SOURCE', 'order-file-src,chk-inv-src', 'retrieves new purchase orders, checks inventory')

The following example deploys all TRANSFER artifacts and provides a comment.

bulkDeployArtifact('TRANSFER', '*', 'deploying all transfers')

5.2.2 deleteArtifact

Command Category: MFT Artifact Management Commands

Use with WLST: Online or Offline

5.2.2.1 Description

Deletes a source, transfer, or target artifact. In the event of an unsupported operation, the command returns a WLSTException.

5.2.2.2 Syntax

deleteArtifact(artifact_type, artifact_name)
delAF(artifact_type, artifact_name)
Argument Definition
artifact_type

Artifact type: SOURCE, TRANSFER, or TARGET.

artifact_name

Artifact name.

5.2.2.3 Example

The following example deletes a SOURCE artifact called order-file-src.

deleteArtifact('SOURCE', 'order-file-src')

5.2.3 deleteArtifactDeployment

Command Category: MFT Artifact Management Commands

Use with WLST: Online or Offline

5.2.3.1 Description

Deletes an undeployed source, transfer, or target artifact. In the event of an unsupported operation, the command returns a WLSTException.

5.2.3.2 Syntax

deleteArtifactDeployment(artifact_type, artifact_name, label)
delDepAF(artifact_type, artifact_name, label)
Argument Definition
artifact_type

Artifact type: SOURCE, TRANSFER, or TARGET.

artifact_name

Artifact name.

label

Artifact label in the MDS (Metadata Store).

Use Show Deployment Details on the Deployment tab to view this label.

5.2.3.3 Example

The following example deletes a SOURCE artifact called order-file-src with the label soa_mft-2012-12-07 22:24:09.383.

deleteArtifactDeployment('SOURCE', 'order-file-src', 'soa_mft-2012-12-07 22:24:09.383')

5.2.4 deployArtifact

Command Category: MFT Artifact Management Commands

Use with WLST: Online or Offline

5.2.4.1 Description

Deploys a source, transfer, or target artifact. In the event of an unsupported operation, the command returns a WLSTException.

5.2.4.2 Syntax

deployArtifact(artifact_type, artifact_name, comment)
depAF(artifact_type, artifact_name, comment)
Argument Definition
artifact_type

Artifact type: SOURCE, TRANSFER, or TARGET.

artifact_name

Artifact name.

comment

Text string describing the artifact or the reason for deploying it.

5.2.4.3 Example

The following example deploys a SOURCE artifact called order-file-src and provides a comment about the artifact.

deployArtifact('SOURCE', 'order-file-src', 'retrieves new purchase orders')

5.2.5 disableArtifact

Command Category: MFT Artifact Management Commands

Use with WLST: Online or Offline

5.2.5.1 Description

Disables a deployed and previously enabled source, transfer, or target artifact. In the event of an unsupported operation, the command returns a WLSTException.

5.2.5.2 Syntax

disableArtifact(artifact_type, artifact_name, comment)
disAF(artifact_type, artifact_name, comment)
Argument Definition
artifact_type

Artifact type: SOURCE, TRANSFER, or TARGET.

artifact_name

Artifact name.

comment

Text string describing the artifact or the reason for disabling it.

5.2.5.3 Example

The following example disables a SOURCE artifact called order-file-src and provides a comment about the reason.

disableArtifact('SOURCE', 'order-file-src', 'order server being upgraded')

5.2.6 enableArtifact

Command Category: MFT Artifact Management Commands

Use with WLST: Online or Offline

5.2.6.1 Description

Enables a deployed and previously disabled source, transfer, or target artifact. In the event of an unsupported operation, the command returns a WLSTException.

5.2.6.2 Syntax

enableArtifact(artifact_type, artifact_name, comment)
enAF(artifact_type, artifact_name, comment)
Argument Definition
artifact_type

Artifact type: SOURCE, TRANSFER, or TARGET.

artifact_name

Artifact name.

comment

Text string describing the artifact or the reason for enabling it.

5.2.6.3 Example

The following example enables a SOURCE artifact called order-file-src and provides a comment about the reason.

enableArtifact('SOURCE', 'order-file-src', 'order server upgrade complete')

5.2.7 exportDeployedArtifact

Command Category: MFT Artifact Management Commands

Use with WLST: Online or Offline

5.2.7.1 Description

Exports a deployed source, transfer, or target artifact to a ZIP file. In the event of an unsupported operation, the command returns a WLSTException.

5.2.7.2 Syntax

exportDeployedArtifact(artifact_type, artifact_name, label, archive_file_path)
expDepAF(artifact_type, artifact_name, label, archive_file_path)
Argument Definition
artifact_type

Artifact type: SOURCE, TRANSFER, or TARGET.

artifact_name

Artifact name.

label

Artifact label in the MDS (Metadata Store).

Use Show Deployment Details on the Deployment tab to view this label.

archive_file_path

Full path to the ZIP file to which to export. If you are connecting to WLST remotely, the ZIP file is created on the remote server.

5.2.7.3 Example

The following example exports a SOURCE artifact called order-file-src with the label soa_mft-2012-12-07 22:24:09.383 to /export/order-file-src.zip.

exportDeployedArtifact('SOURCE', 'order-file-src', 'soa_mft-2012-12-07 22:24:09.383', '/export/order-file-src.zip')

5.2.8 isArtifactInMDS

Command Category: MFT Artifact Management Commands

Use with WLST: Online or Offline

5.2.8.1 Description

Checks whether a source, transfer, or target artifact exists in the MDS (Metadata Store) and returns TRUE or FALSE. In the event of an unsupported operation, the command returns a WLSTException.

5.2.8.2 Syntax

isArtifactInMDS(artifact_type, artifact_name)
isAFinMDS(artifact_type, artifact_name)
Argument Definition
artifact_type

Artifact type: SOURCE, TRANSFER, or TARGET.

artifact_name

Artifact name.

5.2.8.3 Example

The following example checks whether a SOURCE artifact called order-file-src exists in the MDS.

isArtifactInMDS('SOURCE', 'order-file-src')

5.2.9 undeployArtifact

Command Category: MFT Artifact Management Commands

Use with WLST: Online or Offline

5.2.9.1 Description

Undeploys a source, transfer, or target artifact without deleting it from the configuration. In the event of an unsupported operation, the command returns a WLSTException.

5.2.9.2 Syntax

undeployArtifact(artifact_type, artifact_name, comment)
undepAF(artifact_type, artifact_name, comment)
Argument Definition
artifact_type

Artifact type: SOURCE, TRANSFER, or TARGET.

artifact_name

Artifact name.

comment

Text string describing the artifact or the reason for undeploying it.

5.2.9.3 Example

The following example undeploys a SOURCE artifact called order-file-src and provides a comment about the reason.

undeployArtifact('SOURCE', 'order-file-src', 'upgrading artifact')

5.3 MFT Metadata Commands

Use the MFT WLST Metadata commands, listed in Table 5-3, to perform metadata operations.


Table 5-3 MFT Metadata WLST Commands

Use this command... To... Use with WLST

exportMetadata or expMD

Export the entire MFT configuration, excluding passwords, to a ZIP file.

Online or Offline

exportTransferMetadata or expXfrMD

Export a transfer artifact and related metadata to a ZIP file.

Online or Offline

importMetadata or impMD

Import a previously exported MFT configuration from a ZIP file.

Online or Offline

resetMetadata or resMD

Reset the MFT configuration, deleting all artifacts and resetting all administrative settings to their defaults, while optionally preserving user preferences.

Online or Offline


5.3.1 exportMftMetadata

Command Category: MFT Metadata Commands

Use with WLST: Online or Offline

5.3.1.1 Description

Exports the entire MFT configuration, excluding passwords, to a ZIP file. In the event of an unsupported operation, the command returns a WLSTException.

5.3.1.2 Syntax

exportMftMetadata(archive_file_path)
expMD(archive_file_path)
Argument Definition
archive_file_path

Full path to the ZIP file to which to export.

5.3.1.3 Example

The following example exports the MFT configuration to /export/mft-config-dec-2012.zip.

exportMftMetadata('/export/mft-config-dec-2012.zip')

5.3.2 exportTransferMetadata

Command Category: MFT Metadata Commands

Use with WLST: Online or Offline

5.3.2.1 Description

Exports a transfer artifact and related metadata to a ZIP file. In the event of an unsupported operation, the command returns a WLSTException.

5.3.2.2 Syntax

exportTransferMetadata(archive_file_path, transfer_name)
expXfrMD(archive_file_path, transfer_name)
Argument Definition
archive_file_path

Full path to the ZIP file to which to export.

transfer_name

Transfer artifact name.

5.3.2.3 Example

The following example exports a transfer artifact named order-xfr and its metadata to /export/order-xfr.zip.

exportTransferMetadata('/export/order-xfr.zip', 'order-xfr')

5.3.3 importMftMetadata

Command Category: MFT Metadata Commands

Use with WLST: Online or Offline

5.3.3.1 Description

Imports a previously exported MFT configuration from a ZIP file. In the event of an unsupported operation, the command returns a WLSTException.

5.3.3.2 Syntax

importMftMetadata(archive_file_path)
impMD(archive_file_path)
Argument Definition
archive_file_path

Full path to the ZIP file to which to export.

5.3.3.3 Example

The following example imports the MFT configuration from /export/mft-config-dec-2012.zip.

importMftMetadata('/export/mft-config-dec-2012.zip')

5.3.4 resetMetadata

Command Category: MFT Metadata Commands

Use with WLST: Online or Offline

5.3.4.1 Description

Resets the MFT configuration, deleting all artifacts and resetting all administrative settings to their defaults, while optionally preserving user preferences. In the event of an unsupported operation, the command returns a WLSTException.

5.3.4.2 Syntax

resetMetadata(preserve_preferences)
resMD(preserve_preferences)
Argument Definition
preserve_preferences

If TRUE, preserves user preferences. If FALSE, resets user preferences along with the rest of the configuration.

5.3.4.3 Example

The following example resets the MFT configuration but preserves user preferences.

resetMetadata('TRUE')

5.4 MFT Key Management Commands

Use the MFT WLST Key Management commands, listed in Table 5-4, to manage SSL, SSH, and PGP keys in the MFT keystore. For additional information, see "Keystore Management" in Using Oracle Managed File Transfer.


Table 5-4 MFT Key Management WLST Commands

Use this command... To... Use with WLST

deleteCSFKey or delKey

Delete a key alias from the MFT keystore.

Online or Offline

exportCSFKey or expKey

Export keys from the MFT keystore to a key file.

Online or Offline

generateKeys or genKeys

Generate keys and save them to one or more key files.

Online or Offline

importCSFKey or impKey

Import a key to the MFT keystore from a key file.

Online or Offline

listCSFKeyAliases or lsKeyAliases

List key aliases in the MFT keystore.

Online or Offline

updateCSFKey or updKey

Delete a key alias from the MFT keystore and generate a new key file.

Online or Offline


5.4.1 deleteCSFKey

Command Category: MFT Key Management Commands

Use with WLST: Online or Offline

5.4.1.1 Description

Deletes a key alias from the MFT keystore. In the event of an unsupported operation, the command returns a WLSTException.

5.4.1.2 Syntax

deleteCSFKey(key_format, key_type, alias)
delKey(key_format, key_type, alias)
Argument Definition
key_format

Key format: SSH or PGP.

key_type

Key format: PRIVATE or PUBLIC.

alias

Key alias.

5.4.1.3 Example

The following example deletes a PRIVATE SSH key with the alias my-alias.

deleteCSFKey('SSH', 'PRIVATE', 'my-alias')

5.4.2 exportCSFKey

Command Category: MFT Key Management Commands

Use with WLST: Online or Offline

5.4.2.1 Description

Exports keys from the MFT keystore to a key file. In the event of an unsupported operation, the command returns a WLSTException.

5.4.2.2 Syntax

exportCSFKey(key_format, key_type, key_file_path)
expKey(key_format, key_type, key_file_path)
Argument Definition
key_format

Key format: SSH or PGP.

key_type

Key format: PRIVATE or PUBLIC.

key_file_path

Full path to the key file to which to export.

5.4.2.3 Example

The following example exports PRIVATE SSH keys to the file /export/ssh/my_private_keys.ppk.

exportCSFKey('SSH', 'PRIVATE', '/export/ssh/my_private_keys.ppk')

5.4.3 generateKeys

Command Category: MFT Key Management Commands

Use with WLST: Online or Offline

5.4.3.1 Description

Generates keys and saves them to one or more key files. The key type is RSA and the key size is 1024 bits. In the event of an unsupported operation, the command returns a WLSTException.

5.4.3.2 Syntax

generateKeys(key_format, password, key_file_path)
genKeys(key_format, password, key_file_path)
Argument Definition
key_format

Key format: SSH or PGP.

password

Optional password for the private key.

key_file_path

Full path to the generated key file or directory.

For SSH, the path must include the key file name.

For PGP, two files are generated under the specified path: the secret.asc file contains the PGP private key, and the pub.asc file contains the PGP public key.

5.4.3.3 Example

The following example exports SSH keys without password protection to the file /export/ssh/ssh-pvt-keys.ppk.

generateKeys('SSH', '','/export/ssh/ssh-pvt-keys.ppk')

The following example exports PGP keys with password protection to the directory /export/pgp.

generateKeys('PGP', 'P@s$W0rd','/export/pgp')

5.4.4 importCSFKey

Command Category: MFT Key Management Commands

Use with WLST: Online or Offline

5.4.4.1 Description

Imports a key to the MFT keystore from a key file and creates an alias. In the event of an unsupported operation, the command returns a WLSTException.

5.4.4.2 Syntax

importCSFKey(key_format, key_type, alias, key_file_path)
impKey(key_format, key_type, alias, key_file_path)
Argument Definition
key_format

Key format: SSH or PGP.

key_type

Key format: PRIVATE or PUBLIC.

alias

Key alias.

key_file_path

Full path to the key file from which to import.

5.4.4.3 Example

The following example imports a PRIVATE SSH key with the alias my-alias from the file /export/ssh/my_private_keys.ppk.

importCSFKey('SSH', 'PRIVATE', 'my-alias', '/export/ssh/my_private_keys.ppk')

The following example imports a PUBLIC PGP key with the alias mftpgppub from the file /export/pgp/pub.asc.

importCSFKey('PGP', 'PUBLIC', 'mftpgppub', '/export/pgp/pub.asc')

The following example imports a PRIVATE PGP key with the alias mftpgppri from the file /export/pgp/secret.asc.

importCSFKey('PGP', 'PRIVATE', 'mftpgppri', '/export/pgp/secret.asc')

5.4.5 listCSFKeyAliases

Command Category: MFT Key Management Commands

Use with WLST: Online or Offline

5.4.5.1 Description

Lists key aliases in the MFT keystore. In the event of an unsupported operation, the command returns a WLSTException.

5.4.5.2 Syntax

listCSFKeyAliases(key_format, key_type, alias)
lsKeyAliases(key_format, key_type, alias)
Argument Definition
key_format

Key format: SSH or PGP.

key_type

Key format: PRIVATE or PUBLIC.

5.4.5.3 Example

The following example lists PRIVATE SSH keys.

listCSFKeyAliases('SSH', 'PRIVATE')

5.4.6 updateCSFKey

Command Category: MFT Key Management Commands

Use with WLST: Online or Offline

5.4.6.1 Description

Deletes a key alias from the MFT keystore and generates a new key file. In the event of an unsupported operation, the command returns a WLSTException.

5.4.6.2 Syntax

updateCSFKey(key_format, key_type, alias, key_file_path)
updKey(key_format, key_type, alias, key_file_path)
Argument Definition
key_format

Key format: SSH or PGP.

key_type

Key format: PRIVATE or PUBLIC.

alias

Key alias.

key_file_path

Full path to the key file to generate.

5.4.6.3 Example

The following example deletes a PRIVATE SSH key with the alias my-alias and generates the key file /export/ssh/my-private-key.ppk.

updateCSFKey('SSH', 'PRIVATE', 'my-alias', '/export/ssh/my-private-key.ppk')

5.5 MFT Deployment History Commands

Use the MFT WLST Deployment History commands, listed in Table 5-5, to view the deployment history of source, transfer, and target artifacts.


Table 5-5 MFT Deployment History WLST Commands

Use this command... To... Use with WLST

getSourceDeploymentHistory or getSrcDH

Return the deployment history of a source artifact.

Online or Offline

getTargetDeploymentHistory or getTrgtDH

Return the deployment history of a target artifact.

Online or Offline

getTransferDeploymentHistory or getXfrDH

Return the deployment history of a transfer artifact.

Online or Offline


5.5.1 getSourceDeploymentHistory

Command Category: MFT Deployment History Commands

Use with WLST: Online or Offline

5.5.1.1 Description

Returns the deployment history of a source artifact. In the event of an unsupported operation, the command returns a WLSTException.

5.5.1.2 Syntax

getSourceDeploymentHistory(source_name)
getSrcDH(source_name)
Argument Definition
source_name

Source artifact name.

5.5.1.3 Example

The following example returns the deployment history of a source artifact named order-file-src.

getSourceDeploymentHistory('order-file-src')

5.5.2 getTargetDeploymentHistory

Command Category: MFT Deployment History Commands

Use with WLST: Online or Offline

5.5.2.1 Description

Returns the deployment history of a target artifact. In the event of an unsupported operation, the command returns a WLSTException.

5.5.2.2 Syntax

getTargetDeploymentHistory(target_name)
getTrgtDH(target_name)
Argument Definition
target_name

Target artifact name.

5.5.2.3 Example

The following example returns the deployment history of a target artifact named order-file-tgt.

getTargetDeploymentHistory('order-file-tgt')

5.5.3 getTransferDeploymentHistory

Command Category: MFT Deployment History Commands

Use with WLST: Online or Offline

5.5.3.1 Description

Returns the deployment history of a transfer artifact. In the event of an unsupported operation, the command returns a WLSTException.

5.5.3.2 Syntax

getTransferDeploymentHistory(transfer_name)
getXfrDH(transfer_name)
Argument Definition
transfer_name

Transfer artifact name.

5.5.3.3 Example

The following example returns the deployment history of a transfer artifact named order-xfr.

getTransferDeploymentHistory('order-xfr')

5.6 MFT Transfer Management Commands

Use the MFT WLST Transfer Management commands, listed in Table 5-6, to manage transfer instances.


Table 5-6 MFT Transfer Management WLST Commands

Use this command... To... Use with WLST

getTransferInfo or getXfrInfo

Return information about a transfer artifact.

Online or Offline

pauseTransfer or pauseXfr

Pause an in-progress transfer.

Online or Offline

resubmit or resub

Resubmit a failed transfer.

Online or Offline

resumeTransfer or resXfr

Resume a paused transfer.

Online or Offline


5.6.1 getTransferInfo

Command Category: MFT Transfer Management Commands

Use with WLST: Online or Offline

5.6.1.1 Description

Returns information about a transfer artifact. In the event of an unsupported operation, the command returns a WLSTException.

5.6.1.2 Syntax

getTransferInfo(transfer_name, label)
getXfrInfo(transfer_name, label)
Argument Definition
transfer_name

Transfer artifact name.

label

Artifact label in the MDS (Metadata Store).

Use Show Deployment Details on the Deployment tab to view this label.

5.6.1.3 Example

The following example returns information about a transfer artifact named order-xfr with the label soa_mft-2012-12-07 22:28:17.392.

getTransferInfo('order-xfr', 'soa_mft-2013-09-26 22:28:17.392')
ID                                        | NAME          | LABEL
xfer_521a6788-4e24-4822-bb03-43a4a8eaa8ce | ftp-file-xfer | soa_mft-2013-09-26 16:00:09.803

5.6.2 pauseTransfer

Command Category: MFT Transfer Management Commands

Use with WLST: Online or Offline

5.6.2.1 Description

Pauses an in-progress transfer. In the event of an unsupported operation, the command returns a WLSTException.

5.6.2.2 Syntax

pauseTransfer(instance_id, comment)
pauseXfr(instance_id, comment)
Argument Definition
instance_id

Target instance ID for the transfer.

Open the Advanced section of the target report to view the instance ID. For information about the target report, see "Interpreting Source, Transfer, and Target Reports" in Using Oracle Managed File Transfer.

comment

Text string describing the reason for pausing.

5.6.2.3 Example

The following example pauses a transfer with the target instance ID 240C93AD-5401-483B-8182-274FA0705DF1 and provides a reason.

pauseTransfer('240C93AD-5401-483B-8182-274FA0705DF1', 'resume when less network traffic')

5.6.3 resubmit

Command Category: MFT Transfer Management Commands

Use with WLST: Online or Offline

5.6.3.1 Description

Resubmits a transfer. You can resubmit a successful or failed transfer. In the event of an unsupported operation, the command returns a WLSTException.

5.6.3.2 Syntax

resubmit(resubmit_type, instance_ids, comment)
resub(resubmit_type, instance_ids, comment)
Argument Definition
resubmit_type

Resubmit type: SOURCE, TRANSFER_INSTANCE, TARGET, or TARGET_INSTANCE.

For TARGET, the file is delivered without preprocessing. For TARGET_INSTANCE, any preprocessing is called again before delivery.

instance_ids

Comma-separated instance IDs.

Open the Advanced section of the source, transfer, or target report to view the instance ID. For information about these reports, see "Interpreting Source, Transfer, and Target Reports" in Using Oracle Managed File Transfer.

comment

Text string describing the reason for resubmitting.

5.6.3.3 Example

The following example resubmits a SOURCE with the instance ID 3D48B12B-295A-4F52-A8EE-BD1CC1A20246 and provides a reason.

resubmit('SOURCE', '3D48B12B-295A-4F52-A8EE-BD1CC1A20246', 'trying again')

5.6.4 resumeTransfer

Command Category: MFT Transfer Management Commands

Use with WLST: Online or Offline

5.6.4.1 Description

Resumes a paused transfer. In the event of an unsupported operation, the command returns a WLSTException.

5.6.4.2 Syntax

resumeTransfer(instance_id, comment)
resXfr(instance_id, comment)
Argument Definition
instance_id

Target instance ID for the transfer.

Open the Advanced section of the target report to view the instance ID. For information about the target report, see "Interpreting Source, Transfer, and Target Reports" in Using Oracle Managed File Transfer.

comment

Text string describing the reason for resuming.

5.6.4.3 Example

The following example resumes a transfer with the target instance ID 240C93AD-5401-483B-8182-274FA0705DF1 and provides a reason.

resumeTransfer('240C93AD-5401-483B-8182-274FA0705DF1', 'less network traffic now')

5.7 MFT Embedded Server Commands

Use the MFT WLST Embedded Server commands, listed in Table 5-7, to manage embedded FTP and sFTP servers.


Table 5-7 MFT Embedded Server WLST Commands

Use this command... To... Use with WLST

ConfigureHomeDir or confHmDir

Assigns a home directory on an embedded server.

Online or Offline

grantPermissionToDirectory or grPermDir

Grant permission to an embedded server directory.

Online or Offline

listAllPermissions or lsPerms

List all permissions available for a given principal and server type.

Online or Offline

revokePermissionForDirectory or revPermDir

Revoke permissions of an embedded server directory.

Online or Offline

startEmbeddedServer or startES

Start an embedded FTP or sFTP server that was stopped.

Online or Offline

stopEmbeddedServer or stopES

Stop an embedded FTP or sFTP server that is running.

Online or Offline

updatePorts or updPorts

Update the port for an embedded FTP or sFTP server.

Online or Offline


5.7.1 ConfigureHomeDir

Command Category: MFT Embedded Server Commands

Use with WLST: Online or Offline

5.7.1.1 Description

Assigns the specified directory to the user as home directory where that user is located on login to embedded servers.

5.7.1.2 Syntax

configureHomeDir(directory_path, user_name)
Argument Definition

directory_path

Any valid path starting from the embedded server root.

user_name

A WebLogic user ID

5.7.1.3 Example

The following example assigns directory dir1 as the home directory for a user named "user1".

configureHomeDir("/dir1","user1")

5.7.2 grantPermissionToDirectory

Command Category: MFT Embedded Server Commands

Use with WLST: Online or Offline

5.7.2.1 Description

Grant permission to an embedded server directory. Users and groups can be assigned a set of permissions to an existing directory on an embedded server.

5.7.2.2 Syntax

grantPermissionToDirectory(directory_path, principal_name, principal_type, permissions, server_type, include_subfolder)
Argument Definition

directory_path

Any valid path starting from the embedded server root

principal_name

An enterprise user, group or application role name.

principal_type

One of the following:

  • USER

  • GROUP

  • APPLICATION_ROLE

permissions

Comma separated list of the following permissions:

  • READ

  • WRITE

  • LIST

  • DELETE

server_type

FTP or SFTP

include_subfolder

true or false

5.7.2.3 Example

The following example assigns read, write, list and delete permissions to the directory /orders (and sub-directories) for the user "weblogic" on an FTP server:

grantPermissionToDirectory("/orders","weblogic","USER", "READ, WRITE, LIST, DELETE","FTP",true) 

5.7.3 listAllPermissions

Command Category: MFT Embedded Server Commands

Use with WLST: Online or Offline

5.7.3.1 Description

List all permissions available for a given principal and server type. The server type can be FTP or SFTP.

5.7.3.2 Syntax

listAllPermissions(principal_name,server_type)
Argument Definition

principal_name

An enterprise user, group or application role name.

server_type

FTP or SFTP

5.7.3.3 Example

The following example lists all permissions for the principal named "weblogic" on an FTP server.

listAllPermissions("weblogic","FTP"

5.7.4 revokePermissionForDirectory

Command Category: MFT Embedded Server Commands

Use with WLST: Online or Offline

5.7.4.1 Description

Revoke a set of permissions from an embedded server directory.

5.7.4.2 Syntax

revokePermissionForDirectory(directory_path, principal_name, principal_type, permissions, server_type, include_subfolder)
Argument Definition

directory_path

Any valid path starting from the embedded server root

principal_name

An enterprise user, group or application role name.

principal_type

One of the following:

  • USER

  • GROUP

  • APPLICATION_ROLE

permissions

Comma separated list of the following permissions:

  • READ

  • WRITE

  • LIST

  • DELETE

server_type

FTP or SFTP

include_subfolder

true or false

5.7.4.3 Example

The following example revokes read, write, list and delete permissions from the directory /orders (and sub-directories) for the user "weblogic" on an FTP server:

grantPermissionToDirectory("/orders","weblogic","USER", "READ, WRITE, LIST, DELETE","FTP",true) 

5.7.5 startEmbeddedServer

Command Category: MFT Embedded Server Commands

Use with WLST: Online or Offline

5.7.5.1 Description

Starts an embedded FTP, FTPS (FTP over SSL), or sFTP (SSH-FTP) server that was stopped. In the event of an unsupported operation, the command returns a WLSTException.

5.7.5.2 Syntax

startEmbeddedServer(server_type)
startES(server_type)
Argument Definition
server_type

Embedded server type: FTP, FTPS, or SFTP.

5.7.5.3 Example

The following example starts the embedded FTP server.

startEmbeddedServer('FTP')

5.7.6 stopEmbeddedServer

Command Category: MFT Embedded Server Commands

Use with WLST: Online or Offline

5.7.6.1 Description

Stops an embedded FTP, FTPS (FTP over SSL), or sFTP (SSH-FTP) server that is running. In the event of an unsupported operation, the command returns a WLSTException.

5.7.6.2 Syntax

stopEmbeddedServer(server_type)
stopES(server_type)
Argument Definition
server_type

Embedded server type: FTP, FTPS, or SFTP.

5.7.6.3 Example

The following example stops the embedded FTP server.

stopEmbeddedServer('FTP')

5.7.7 updatePorts

Command Category: MFT Embedded Server Commands

Use with WLST: Online or Offline

5.7.7.1 Description

Updates the port for an embedded FTP, FTPS (FTP over SSL), or sFTP (SSH-FTP) server, which is a service of an Oracle WebLogic Server managed server dedicated to MFT. In the event of an unsupported operation, the command returns a WLSTException.

5.7.7.2 Syntax

updatePorts(server_instance, service, port)
updPorts(server_instance, service, port)
Argument Definition
server_instance

Name of Oracle WebLogic Server managed server dedicated to MFT.

service

Service (embedded server type): FTP, FTPS, or SFTP.

port

Port number.

5.7.7.3 Example

The following example updates the port of the embedded FTP server.

updatePorts('mft_server1', 'FTP', 7021)

5.8 MFT Callout Commands

Use the MFT WLST Callout commands, listed in Table 5-8, to manage custom callouts.


Table 5-8 MFT Callout WLST Commands

Use this command... To... Use with WLST

createCallouts or crtCalls

Create callouts based on an XML file that defines them.

Online or Offline

deleteCallout or delCalls

Delete a callout.

Online or Offline

listCallouts or lsCalls

List callouts.

Online or Offline

updateCallouts or updCalls

Update callouts with the same names based on an XML file that defines them.

Online or Offline


5.8.1 createCallouts

Command Category: MFT Callout Commands

Use with WLST: Online or Offline

5.8.1.1 Description

Creates callouts based on an XML file that defines them. In the event of an unsupported operation, the command returns a WLSTException.

See Processing Transfers with Custom Callouts in Using Oracle Managed File Transfer for callout instructions and examples.

5.8.1.2 Syntax

createCallouts(def_file_path)
crtCalls(def_file_path)
Argument Definition
def_file_path

Full path to the callout definition XML file.

5.8.1.3 Example

The following example creates callouts based on a definition file named /tmp/CalloutDefn.xml.

createCallouts('/tmp/CalloutDefn.xml')

5.8.2 deleteCallout

Command Category: MFT Callout Commands

Use with WLST: Online or Offline

5.8.2.1 Description

Deletes a callout. In the event of an unsupported operation, the command returns a WLSTException.

5.8.2.2 Syntax

deleteCallout(callout_name)
delCalls(callout_name)

Argument Definition
callout_name

Callout name.


5.8.2.3 Example

The following example deletes a callout named NotifyTransferComplete.

deleteCallout('NotifyTransferComplete')

5.8.3 listCallouts

Command Category: MFT Callout Commands

Use with WLST: Online or Offline

5.8.3.1 Description

Lists callouts. In the event of an unsupported operation, the command returns a WLSTException.

5.8.3.2 Syntax

listCallouts()
lsCalls()

5.8.3.3 Example

The following example lists callouts.

listCallouts()

5.8.4 updateCallouts

Command Category: MFT Callout Commands

Use with WLST: Online or Offline

5.8.4.1 Description

Updates callouts with the same names based on an XML file that defines them. In the event of an unsupported operation, the command returns a WLSTException.

Note:

Parameters of existing callouts cannot be added, deleted, or modified.

5.8.4.2 Syntax

updateCallouts(def_file_path)
updCalls(def_file_path)
Argument Definition
def_file_path

Full path to the callout definition XML file.

5.8.4.3 Example

The following example updates callouts based on a definition file named /tmp/CalloutDefn.xml.

updateCallouts('/tmp/CalloutDefn.xml')

5.9 MFT Event Notification Commands

Use the MFT WLST Event Notification commands, listed in Table 5-9, to manage contact notifications of events.


Table 5-9 MFT Contact WLST Commands

Use this command... To... Use with WLST

addContactToNotification or addContNote

Add a contact to a specific event notification.

Online or Offline

createContact or CrtCont

Create a contact for event notifications.

Online or Offline

deleteContact or delCont

Delete a contact.

Online or Offline

listContacts or lsConts

List contacts.

Online or Offline

removeContactFromNotification or remContNote

Remove a contact from a specific event notification.

Online or Offline

updateEvent or updEvt

Enable or disable a specific event notification.

Online or Offline


5.9.1 addContactToNotification

Command Category: MFT Contact Commands

Use with WLST: Online or Offline

5.9.1.1 Description

Adds a contact to a specific event notification. In the event of an unsupported operation, the command returns a WLSTException.

5.9.1.2 Syntax

addContactToNotification(event, contact_type, value)
addContNote(event, contact_type, value)
Argument Definition
event

Event: RUNTIME_ERROR_EVENT, DELETE_ARTIFACT_EVENT, DEPLOY_ARTIFACT_EVENT, EXPORT_IMPORT_EVENT, PURGE_EVENT, or ARCHIVE_RESTORE_EVENT.

contact_type

Contact type: EMAIL, PHONE, FAX, or SMS.

value

Email address or phone number.

5.9.1.3 Example

The following example adds EMAIL contact jane.doe@example.com to RUNTIME_ERROR_EVENT notifications.

addContactToNotification('RUNTIME_ERROR_EVENT', 'EMAIL', 'jane.doe@example.com')

5.9.2 createContact

Command Category: MFT Contact Commands

Use with WLST: Online or Offline

5.9.2.1 Description

Creates a contact for event notifications. In the event of an unsupported operation, the command returns a WLSTException.

See Configuring an Email Driver for Notifications in Using Oracle Managed File Transfer for information on how to configure an email driver. See Configuring an SMS Driver for Notifications in Using Oracle Managed File Transfer for information on how to configure an SMS driver.

Note:

Phone and FAX notifications are not supported in this release of Oracle Managed File Transfer.

5.9.2.2 Syntax

createContact(contact_type, value)
crtCont(contact_type, value)
Argument Definition
contact_type

Contact type: EMAIL, PHONE, FAX, or SMS.

value

Email address or phone number.

5.9.2.3 Example

The following example creates a contact based on the email address jane.doe@example.com.

createContact('EMAIL', 'jane.doe@example.com')

5.9.3 deleteContact

Command Category: MFT Contact Commands

Use with WLST: Online or Offline

5.9.3.1 Description

Deletes a contact. In the event of an unsupported operation, the command returns a WLSTException.

5.9.3.2 Syntax

deleteContact(contact_type, value)
delCont(contact_type, value)
Argument Definition
contact_type

Contact type: EMAIL, PHONE, FAX, or SMS.

value

Email address or phone number.

5.9.3.3 Example

The following example deletes a contact based on the email address jane.doe@example.com.

deleteContact('EMAIL', 'jane.doe@example.com')

5.9.4 listContacts

Command Category: MFT Contact Commands

Use with WLST: Online or Offline

5.9.4.1 Description

Lists contacts. In the event of an unsupported operation, the command returns a WLSTException.

5.9.4.2 Syntax

listContacts(contact_type)
lsConts(contact_type)
Argument Definition
contact_type

Contact type: EMAIL, PHONE, FAX, or SMS.

5.9.4.3 Example

The following example lists email contacts.

listContacts('EMAIL')

5.9.5 removeContactFromNotification

Command Category: MFT Contact Commands

Use with WLST: Online or Offline

5.9.5.1 Description

Removes a contact from a specific event notification. In the event of an unsupported operation, the command returns a WLSTException.

When you remove the last contact from an event, the event is disabled. However, the reverse is not true. When you add the first contact to an event, it is not enabled automatically. Enable an event using the updateEvent command.

5.9.5.2 Syntax

removeContactFromNotification(event, contact_type, value)
remContNote(event, contact_type, value)
Argument Definition
event

Event: RUNTIME_ERROR_EVENT, DELETE_ARTIFACT_EVENT, DEPLOY_ARTIFACT_EVENT, or EXPORT_IMPORT_EVENT.

contact_type

Contact type: EMAIL, PHONE, FAX, or SMS.

value

Email address or phone number.

5.9.5.3 Example

The following example removes EMAIL contact jane.doe@example.com from RUNTIME_ERROR_EVENT notifications.

removeContactFromNotification('RUNTIME_ERROR_EVENT', 'EMAIL', 'jane.doe@example.com')

5.9.6 updateEvent

Command Category: MFT Contact Commands

Use with WLST: Online or Offline

5.9.6.1 Description

Enables or disables a specific event notification. Event notifications are disabled by default. In the event of an unsupported operation, the command returns a WLSTException.

5.9.6.2 Syntax

updateEvent(event, enabled)
updEvt(event, enabled)

Argument Definition
event

Event: RUNTIME_ERROR_EVENT, DELETE_ARTIFACT_EVENT, DEPLOY_ARTIFACT_EVENT, or EXPORT_IMPORT_EVENT.

enabled

Enabled: TRUE or FALSE.


5.9.6.3 Example

The following example disables DELETE_ARTIFACT_EVENT notifications.

updateEvent('DELETE_ARTIFACT_EVENT', 'FALSE')

5.10 MFT Archive and Restore Commands

Use the MFT Archive and Restore commands, listed in Table 5-10, to archive and restore runtime instances or file system data based on criteria such as status and date ranges.


Table 5-10 MFT Archive and Restore WLST Commands

Use this command... To... Use with WLST

archiveInstanceData or arcData

Archive runtime instances based on specified criteria.

Online or Offline

restoreInstanceData or resData

Restore previously archived runtime instances.

Online or Offline

archivePayloads or arcPLs

Archive file system data corresponding to runtime instance data based on specified criteria.

Online or Offline

restorePayloadsByName or resPLbyN

Restore previously archived file system data by the zip file name.

Online or Offline

restorePayloadsByPrefix or resPLbyP

Restore previously archived file system data by the zip file name prefix.

Online or Offline


5.10.1 archiveInstanceData

Command Category: MFT Archive and Restore Commands

Use with WLST: Online or Offline

5.10.1.1 Description

Archives runtime instances based on specified criteria. Optionally archives file system data. In the event of an unsupported operation, the command returns a WLSTException.

Before you can run this command, you must create an MFT archive directory on the database server using the following SQL commands:

CREATE DIRECTORY MFT_DIR AS path;
GRANT READ, WRITE ON DIRECTORY MFT_DIR TO MFT_STB;

For more information about the database and the schema owner (MFT_STB), see Installing and Configuring Managed File Transfer.

5.10.1.2 Syntax

archiveInstanceData(arguments)
arcData(arguments)

Argument Definition
archiveFileName

Name of the runtime instance archive file to be saved to the defined MFT archive directory. The default extension is .dmp. This argument is required.

startDate

Timestamp in format dd-MM-yyyy H:m:s:S. Default is no date and time specified. Expressions are not supported.

endDate

Timestamp in format dd-MM-yyyy H:m:s:S. Default is the current date and time. Expressions are not supported.

batchId

Identifier in the output of a previous archiveInstanceData command. Default input is an empty string. Use to rerun a tested or failed archiveInstanceData from the point of failure or to run archivePayloads.

status

Status: * for all statuses, C for COMPLETED, F for FAILED, or A for ACTIVE (in progress). Default is C. You can specify multiple comma-separated statuses.

testMode

Whether what to archive is tested but not archived: TRUE or FALSE. Default is TRUE. Therefore, to actually archive runtime instances, you must explicitly set testMode=FALSE.

comments

Comment string. Default is an empty string.

runInSync

Whether to run immediately, synchronously, and return (TRUE), or run in the background, asynchronously, allowing execution of other WLST commands (FALSE). Default is FALSE.

fsArchiveFolderPath

Path to the folder where the payload archive .zip file is saved. Default is an empty string, which means no payloads are archived. This is independent of the runtime instance archive file and the MFT archive directory.


5.10.1.3 Example

The following example runs in test mode (does not archive anything) and in the background (does not block WLST commands while running) for all instances with status COMPLETED, and provides statistics such as how many instances or payloads would be archived.

archiveInstanceData()

Here is an example of the output:

Total no. of instances to be archived: 105.
Total no. of payloads to be archived: 105.
Nothing has been archived as test mode was TRUE.
To archive these records, run the same command
by passing batch id 546781 and test mode as FALSE.

The following example runs in test mode and in the background for instances before March 31st, 2013 with status COMPLETED, and provides archive statistics. Note that when the startDate argument is omitted, the endDate argument must be explicitly labeled.

archiveInstanceData(endDate='31-03-2013 00:00:00:00')

The following example archives instances from February 1st, 2013 to March 31st, 2013 with status COMPLETED to the file mft.dmp, and provides archive statistics. Note that when the startDate and endDate arguments are both included, labels may be omitted.

archiveInstanceData(archiveFileName='mft.dmp','01-02-2013 00:00:00:00', '31-03-2013 00:00:00:00', testMode='FALSE')

The following example archives instances from February 1st, 2013 to March 31st, 2013 with status ACTIVE or FAILED to the file mft.dmp, and provides archive statistics. Because runInSync='TRUE' is specified, the archive occurs immediately and blocks further WLST commands until completion. Because runFSArchive='TRUE' is specified, file system data is also archived.

archiveInstanceData(archiveFileName='mft.dmp','01-02-2013 00:00:00:00', '31-03-2013 00:00:00:00', testMode='FALSE', status='A,F',
runInSync='TRUE', fsArchiveFolderPath='2013-01-02-MftArchive')

The following example runs a previously tested or failed archive with batch ID 546781 from the point of failure.

archiveInstanceData(archiveFileName='mft2.dmp',batchId='546781', testMode='FALSE')

5.10.2 restoreInstanceData

Command Category: MFT Archive and Restore Commands

Use with WLST: Online or Offline

5.10.2.1 Description

Restores previously archived runtime instances. In the event of an unsupported operation, the command returns a WLSTException.

5.10.2.2 Syntax

restoreInstanceData(arguments)
resData(arguments)
Argument Definition
archiveFilePath

Name of the archive file in the MFT archive directory to be restored. For details about how this directory is defined, see archiveInstanceData. The default extension is .dmp. This argument is required.

fileNamePrefix

String to identify the file name prefix of the corresponding payload archive files, usually the batch ID. You must have run archivePayloads with the archiveInstanceData batch ID first. No default.

fsFolderPath

String to identify the path to the directory where the corresponding payload archive files are stored. No default.

runInSync

Whether to run immediately, synchronously, and return (TRUE), or run in the background, asynchronously, allowing execution of other WLST commands (FALSE). Default is FALSE.

5.10.2.3 Example

The following example restores runtime instance data previously archived by an archiveInstanceData command. The corresponding payload archive is restored from /tmp/mft/546781.zip. This command runs in the background.

restoreInstanceData(archiveFilePath="mft_runtime_archive.dmp", fileNamePrefix="546781", fsFolderPath="/tmp/mft")

5.10.3 archivePayloads

Command Category: MFT Archive and Restore Commands

Use with WLST: Online or Offline

5.10.3.1 Description

Archives file system data corresponding to runtime instance data based on specified criteria. In the event of an unsupported operation, the command returns a WLSTException.

5.10.3.2 Syntax

archivePayloads(arguments)
arcPLs(arguments)
Argument Definition
batchId

String to identify the archive criteria. No default: obtain a batchId by running archiveInstanceData first. This argument is required.

archivePath

Path to the directory to which the batchId.zip archive is saved. This directory must exist. A very large archive may be saved in multiple files named batchId_n.zip. This argument is required.

runInSync

Whether to run immediately, synchronously, and return (TRUE), or run in the background, asynchronously, allowing execution of other WLST commands (FALSE). Default is FALSE.

5.10.3.3 MBean Properties

For details about how to set MBean properties using Enterprise Manager, see Setting System MBean Properties for MFT WLST Commands.


Property Definition
FS_ARCHIVE_MAX_SIZE 

String to set a size limit in MB for archive zip files. The default value is zero, which sets no limit.

FS_ARCHIVE_MAX_FILES_PER_ZIP

String to set a limit on the number of files an archive zip file can contain. The default value is zero, which sets no limit.


5.10.3.4 Example

The following example archives file system data corresponding to the runtime instance data previously archived by an archiveInstanceData command with the batch ID 546781. The archive is saved to /tmp/mft/546781.zip and runs immediately.

archivePayloads(batchId='546781',archivePath='/tmp/mft',runInSync='TRUE')

5.10.4 restorePayloadsByName

Command Category: MFT Archive and Restore Commands

Use with WLST: Online or Offline

5.10.4.1 Description

Restores previously archived file system data. In the event of an unsupported operation, the command returns a WLSTException.

5.10.4.2 Syntax

restorePayloadsByName(arguments)
resPLbyN(arguments)
Argument Definition
fileNames

String to identify the names of the .zip files to restore. No default. This argument is required.

If the .zip file names have been changed to something other than the batch IDs, you must specify the new file names instead of the batch IDs for this argument.

For an archive that consists of multiple batchId_n.zip or prefix_n.zip files, you can use the restorePayloadsByPrefix command instead.

folderPath

Path to the directory in which the .zip archives were saved. This argument is required.

runInSync

Whether to run immediately, synchronously, and return (TRUE), or run in the background, asynchronously, allowing execution of other WLST commands (FALSE). Default is FALSE.

5.10.4.3 MBean Properties

For details about how to set MBean properties using Enterprise Manager, see Setting System MBean Properties for MFT WLST Commands.


Property Definition
FS_RESTORE_OVERWRITE_EXISTING

String to determine whether a restore overwrites files having the same name. The default value is TRUE.


5.10.4.4 Example

The following example restores file system data corresponding to the runtime instance data previously archived by an archivePayloads command with the batch ID 546781. The archive is restored from /tmp/mft/546781.zip and runs immediately.

restorePayloadsByName(fileNames='546781',folderPath='/tmp/mft',runInSync='TRUE')

5.10.5 restorePayloadsByPrefix

Command Category: MFT Archive and Restore Commands

Use with WLST: Online or Offline

5.10.5.1 Description

Restores previously archived file system data. In the event of an unsupported operation, the command returns a WLSTException.

5.10.5.2 Syntax

restorePayloadsByPrefix(arguments)
resPLbyP(arguments)
Argument Definition
fileNamePrefix

String to identify the .zip files to restore, usually the batch ID. No default: obtain a batchId by running archivePayloads first. This argument is required.

If the .zip file names have been changed to something other than the batch ID, you must specify the new file name instead of the batch ID for this argument.

If you rename one prefix_n.zip file you must rename all, without changing the _n portion, or this command will not restore the entire archive.

folderPath

Path to the directory in which the .zip archives were saved. This argument is required.

runInSync

Whether to run immediately, synchronously, and return (TRUE), or run in the background, asynchronously, allowing execution of other WLST commands (FALSE). Default is FALSE.

5.10.5.3 MBean Properties

For details about how to set MBean properties using Enterprise Manager, see Setting System MBean Properties for MFT WLST Commands.


Property Definition
FS_RESTORE_OVERWRITE_EXISTING

String to determine whether a restore overwrites files having the same name. The default value is TRUE.


5.10.5.4 Example

The following example restores file system data corresponding to the runtime instance data previously archived by an archivePayloads command with the batch ID 546781. The archive is restored from /tmp/mft/546781.zip and runs immediately.

restorePayloadsByPrefix(fileNamePrefix='546781',folderPath='/tmp/mft',runInSync='TRUE')

5.11 MFT Purge Commands

Use the MFT Purge commands, listed in Table 5-11, to purge runtime instances or file system data based on criteria such as status and date ranges.


Table 5-11 MFT Purge WLST Commands

Use this command... To... Use with WLST

purgeInstanceData or prgData

Purge runtime instances based on specified criteria. Optionally purges file system data.

Online or Offline

purgePayloads or prgPLs

Purge file system data corresponding to runtime instance data based on specified criteria.

Online or Offline


5.11.1 purgeInstanceData

Command Category: MFT Purge Commands

Use with WLST: Online or Offline

5.11.1.1 Description

Purges runtime instances based on specified criteria. Optionally purges file system data. In the event of an unsupported operation, the command returns a WLSTException.

5.11.1.2 Syntax

purgeInstanceData(optional_arguments)
prgData(optional_arguments)
Argument Definition
startDate

Timestamp in format dd-MM-yyyy H:m:s:S. Default is no date and time specified. Expressions are not supported.

endDate

Timestamp in format dd-MM-yyyy H:m:s:S. Default is the current date and time. Expressions are not supported.

batchId

Identifier in the output of a previous purgeInstanceData command. Default input is an empty string. Use to rerun a tested or failed purgeInstanceData from the point of failure or to run purgePayloads.

status

Status: * for all statuses, C for COMPLETED, F for FAILED, or A for ACTIVE (in progress). Default is C. You can specify multiple comma-separated statuses.

testMode

Whether what to purge is tested but not purged: TRUE or FALSE. Default is TRUE. Therefore, to actually purge runtime instances, you must explicitly set testMode=FALSE.

comments

Comment string. Default is an empty string.

runInSync

Whether to run immediately, synchronously, and return (TRUE), or run in the background, asynchronously, allowing execution of other WLST commands (FALSE). Default is FALSE.

runPayloadPurge

Whether to also purge file system data corresponding to runtime instance data: TRUE or FALSE. Default is FALSE. To purge file system data separately, use purgePayloads.

5.11.1.3 Example

The following example runs in test mode (does not purge anything) and in the background (does not block WLST commands while running) for all instances with status COMPLETED, and provides statistics such as how many instances or payloads would be purged.

purgeInstanceData()

Here is an example of the output:

Total no. of purgeable instances: 105.
Total no. of purgeable payloads: 105.
Nothing has been purged as test_mode was TRUE.
To purge these records, run the same command
by passing batchId 546781 and test mode as FALSE.

The following example runs in test mode and in the background for instances before March 31st, 2013 with status COMPLETED, and provides purge statistics. Note that when the startDate argument is omitted, the endDate argument must be explicitly labeled.

purgeInstanceData(endDate='31-03-2013 00:00:00:00')

The following example purges instances from February 1st, 2013 to March 31st, 2013 with status COMPLETED, and provides purge statistics. Note that when the startDate and endDate arguments are both included, labels may be omitted.

purgeInstanceData('01-02-2013 00:00:00:00', '31-03-2013 00:00:00:00', testMode='FALSE')

The following example purges instances from February 1st, 2013 to March 31st, 2013 with status ACTIVE or FAILED, and provides purge statistics. Because runInSync='TRUE' is specified, the purge occurs immediately and blocks further WLST commands until completion. Because runPayloadPurge='TRUE' is specified, file system data is also purged.

purgeInstanceData('01-02-2013 00:00:00:00', '31-03-2013 00:00:00:00', testMode='FALSE', status='A,F', runInSync='TRUE',
runPayloadPurge='TRUE')

The following example runs a previously tested or failed purge with batch ID 546781 from the point of failure.

purgeInstanceData(batchId='546781', testMode='FALSE')

5.11.2 purgePayloads

Command Category: MFT Purge Commands

Use with WLST: Online or Offline

5.11.2.1 Description

Purges file system data corresponding to runtime instance data based on specified criteria. In the event of an unsupported operation, the command returns a WLSTException.

5.11.2.2 Syntax

purgePayloads(arguments)
prgPLs(arguments)
Argument Definition
batchId

String to identify the purge criteria. No default: obtain a batchId by running purgeInstanceData first.

detailedAudit

Whether each purged file is audited: TRUE or FALSE. Default is TRUE.

runInSync

Whether to run immediately, synchronously, and return (TRUE), or run in the background, asynchronously, allowing execution of other WLST commands (FALSE). Default is FALSE.

5.11.2.3 MBean Properties

For details about how to set MBean properties using Enterprise Manager, see Setting System MBean Properties for MFT WLST Commands.


Property Definition
FS_PURGE_BATCH_SIZE

String to determine the batch size for reading payload paths. The purgePayloads command reads the payload paths from the database in batches to avoid running out of memory. The default value is 5000.

FS_PURGE_TEMP_TABLES_LIFE

String to determine the minimum age in days of temporary tables that are deleted after a payload purge. The default value is 30.

FS_PURGE_THREAD_COUNT

String to determine how many threads per node are used for performing the payload purge. The default value is 1.


5.11.2.4 Example

The following example purges file system data corresponding to the runtime instance data previously purged by a purgeInstanceData command with the batch ID 546781. Detailed audits of purged files are performed, and the purge runs in the background.

purgePayloads(batchId='546781')

The following example purges file system data corresponding to the runtime instance data previously purged by a purgeInstanceData command with the batch ID 546781. Detailed audits of purged files are not performed, and the purge runs in the background.

purgePayloads(batchId='546781', detailedAudit='FALSE')

The following example purges file system data corresponding to the runtime instance data previously purged by a purgeInstanceData command with the batch ID 546781. Detailed audits of purged files are performed, and the purge occurs immediately.

purgePayloads(batchId='546781', detailedAudit='TRUE', runInSync='TRUE')

5.12 Setting System MBean Properties for MFT WLST Commands

Some MFT WLST commands have associated properties you can set to refine the operations they perform.

The steps for this process are:

  1. Log in to the Oracle Enterprise Manager console.

  2. In the Target Navigation pane, expand the Weblogic Domain node.

  3. Select the domain on which the Oracle WebLogic Server managed server dedicated to Oracle Managed File Transfer is installed.

    For example, the domain might be soainfra or base_domain.

  4. Right-click on the domain and select System MBean Browser.

  5. Click the Find icon.

  6. Type MFTConfig in the MBean Name text box. Press Enter.

    The Application Defined MBeans: MFTConfig: mft page appears.

  7. Click the Operations tab.

  8. Click addProperty.

    The Operation: addProperty page appears.

  9. Type the property name in the key text box. Type the property value in the value text box. Typing a comment is optional. Click Invoke.

  10. To verify that the property has been added:

    1. Click Return.

    2. Click the Attributes tab.

    3. Click Properties.

      The Attribute: Properties page appears. The property you added should be listed.