F Zero Downtime Migration ZDMCLI Command Reference

The following topics describe the Zero Downtime Migration ZDMCLI command usage and options.

abort job

Terminates the specified job, if running.

Syntax

$ZDM_HOME/bin/zdmcli abort job
  -jobid job_id

Options

Table F-1 ZDMCLI abort job Options

Option Description
-jobid job_id Unique job ID value (integer) for the scheduled job. The job ID is assigned when the job is scheduled.

add imagetype

Configures a new image type of the specified name and its associated user actions.

Syntax

$ZDM_HOME/bin/zdmcli add imagetype
  -imagetype image_type
  -basetype CUSTOM_PLUGIN
  [-useractions user_action_list]

Options

Table F-2 ZDMCLI add imagetype Options

Option Description
-imagetype image_type

Name of the image type to be created

-basetype CUSTOM_PLUGIN

The base image type for which the image type is created.

Note that CUSTOM_PLUGIN is the only valid value for this mandatory argument.

-useractions user_action_list

Comma-separated list of user action names

add useraction

Configures a new user action of the specified name with its associated script and action file.

Syntax

$ZDM_HOME/bin/zdmcli add useraction
  -useraction user_action_name 
  -actionscript script_name 
  [-actionfile file_name] 
  {-pre | -post}
  -optype MIGRATE_DATABASE 
  [-phase operation_phase]
  [-onerror {ABORT | CONTINUE}]
  [-runscope
     {ONENODE |
      ALLNODES |
      AUTO}]

Options

Table F-3 ZDMCLI add useraction Options

Option Description
-useraction user_action_name

Name of the user action

-actionscript script_name

Script file to be run

-actionfile file_name

File associated with and needed by the user action

-pre

Runs the user action before the operation

-post

Runs the user action after the operation

-optype MIGRATE_DATABASE

Defines the operation for which the user action is configured as MIGRATE_DATABASE.

-phase phase_of_operation

Migration operation phase for which the user action is configured

-onerror {ABORT | CONTINUE}

The response if the user action encounters an error during execution

-runscope {ONENODE | ALLNODES | AUTO}

The servers on which the user action is run.

Specify AUTO to choose the run scope based on the other command options.

migrate database

Performs a migration of a database to the Oracle Cloud.

Syntax

$ZDM_HOME/bin/zdmcli migrate database 
  {-sourcedb db_name |
   -sourcesid source_oracle_sid}
  -sourcenode source_host_name
  -targetnode target_host_name
  -rsp zdm_template_path 
  -backupuser user_name 
  [-targethome target_home] 
  [-eval] 
  [-imagetype] 
  [-tdekeystorepasswd] 
  [-tdemasterkey] 
  [-sourcesyswallet sys_wallet_path]
  [-osswallet oss_wallet_path]
  [-tdekeystorewallet tde_wallet_path]
  [-useractiondata user_action_data]
  [{-srcroot |
    -srccred cred_name |
    -srcuser user_name |
    {-srcsudouser sudo_user_name -srcsudopath sudo_binary_path} |
    {-srcauth plugin_name 
       [-srcarg1 name1:value1 
          [-srcarg2 name2:value2...]]}}]
  {-tgtroot |
   -tgtcred cred_name |
   -tgtuser user_name |
   {-tgtsudouser sudo_user_name -tgtsudopath sudo_binary_path} |
   {-tgtauth plugin_name 
      [-tgtarg1 name1:value1 
         [-tgtarg2 name2:value2...]]}} 
  [-schedule {timer_value | NOW}] 
  [-pauseafter phase] 
  [-listphases] 
  [-ignoremissingpatches patch_name [,patch_name...]] 
  [-ignore {ALL | WARNING | PATCH_CHECK}]

Options

Table F-4 ZDMCLI migrate database Options

Option Description
-sourcedb db_name

Name of the source database you want to migrate

-sourcenode source_host_name

Host on which the source database is running

-targetnode target_host_name

Target server to which the source database is migrated

-targethome target_home

Location of the target database ORACLE_HOME

-imagetype image_type

Name of the user action imagetype

-useractiondata user_action_data

Value to be passed to useractiondata parameter of the user action script

-rsp zdm_template_path

Location of the Zero Downtime Migration response file

-sourcesid source_oracle_sid

ORACLE_SID of the source single instance database without Grid Infrastructure

-eval

Evaluate the migration job without actually running the migrate database command against the source and target

-backupuser user_name

Name of the user allowed to back up or restore the database

-srcroot

Directs Zero Downtime Migration to use root credentials to access the source database server

-srccred cred_name

Credential name with which to associate the user name and password credentials to access the source database server

-srcuser user_name

Name of the privileged user performing operations on the source database server

-srcsudouser user_name

Perform super user operations as sudo user name on the source database server

-srcsudopath sudo_binary_path

Location of sudo binary on the source database server

-srcauth plug-in_name [plug-in_args]

Use an authentication plug-in to access the source database server

-tgtroot

Use root credentials to access the target database server

-tgtcred cred_name

Credential name with which to associate the user name and password credentials to access the target database server

-tgtuser user_name

Name of the user performing operations on the target database server

-tgtsudouser user_name

Perform super user operations as sudo user name on the target database server

-tgtsudopath sudo_binary_path

Location of sudo binary on the target database server

-tgtauth plugin_name [plugin_args]

Use an authentication plug-in to access the target database server

-tdekeystorepasswd

Transparent Data Encryption (TDE) keystore password, required for password-based keystore or wallet

-tdemasterkey

Transparent Data Encryption (TDE) master encryption key

-schedule timer_value

Scheduled time to execute the operation, in ISO-8601 format. For example: 2016-12-21T19:13:17+05

-pauseafter phase

Pause the job after running the specified phase

-ignoremissingpatches

Proceed with the migration even though the specified patches, which are present in the source path or working copy, might be missing from the destination path or working copy

-ignore {ALL | WARNING | PATCH_CHECK}

Ignore all checks or specific type of checks

-listphases

List the phases for this operation

-sourcesyswallet sys_wallet_path

Full path for the auto-login wallet file on the Zero Downtime Migration host containing the SYS password of the source database

-osswallet oss_wallet_path

Full path for the auto-login wallet file on the Zero Downtime Migration host containing the credential for the Object Storage Service (OSS) backup user

-tdekeystorewallet tde_wallet_path

Full path for the auto-login wallet file on the Zero Downtime Migration host containing the Transparent Data Encryption (TDE) keystore password

modify useraction

Modifies the configuration of the user action with the specified name.

Syntax

$ZDM_HOME/bin/zdmcli modify useraction
  -useraction user_action_name 
  [-actionscript script_name] 
  [-actionfile file_name] 
  [-pre | -post] 
  [-optype MIGRATE_DATABASE] 
  [-phase phase] 
  [-onerror {ABORT | CONTINUE}] 
  [-runscope 
     {ONENODE |
      ALLNODES |
      AUTO}]

Options

Table F-5 ZDMCLI modify useraction Options

Option Description
-useraction user_action_name

Name of the user action

-actionscript script_name

Script file to be run

-actionfile file_name

Accompanying file needed by the user action

-pre

Runs the user action before the operation

-post

Runs the user action after the operation

-optype MIGRATE_DATABASE

Defines the operation for which the user action is configured as MIGRATE_DATABASE

-onerror {ABORT | CONTINUE}

Defines whether to stop or continue running if an error occurs while the user action is running

-runscope {ONENODE | ALLNODES | AUTO}

The servers where the user action will be run.

Specify AUTO to choose the run scope based on the other command options.

query job

Gets the current status of scheduled migration jobs.

Syntax

$ZDM_HOME/bin/zdmcli query job
  [-jobid job_id
     [-jobtype]] 
  [-sourcenode source_host_name
     [-sourcedb db_name |
     -sourcesid sid]]
  [-targetnode target_host_name]
  [-latest]
  [-eval |
  -migrate] 
  [-status 
     {SCHEDULED |
      EXECUTING |
      UNKNOWN |
      TERMINATED |
      FAILED |
      SUCCEEDED |
      PAUSED |
      ABORTED}] 
  [-dbname database_name] 
  [-since timer_value] 
  [-upto timer_value] 
  [-brief]
  [-statusonly]

Options

Table F-6 ZDMCLI query job Options

Option Description
-jobid job_id

Unique job ID value (integer) for the scheduled migration job

The job ID is assigned when the migration job is scheduled.

-job_type

Returns the type of the scheduled job

-sourcenode source_host_name

Server on which the source database is running

-sourcedb db_name

Name of the source database to be migrated

-sourcesid sid

The ORACLE_SID of the source single instance database without Grid Infrastructure

-targetnode target_host_name

Target server to which the database is migrated

-latest

Returns the most recent job that matches the given criteria

-eval

Returns evaluation jobs only

-migrate

Returns migration jobs only

-status {SCHEDULED | EXECUTING | UNKNOWN | TERMINATED | FAILED | SUCCEEDED | PAUSED | ABORTED}

Returns jobs that match the specified job status

-dbname unique_db_name

Specifies the database DB_UNIQUE_NAME value

-since timer_value

Date from which to get the jobs, in ISO-8601 format. For example: 2016-12-21T19:13:17+05

-upto timer_value

Upper limit time to which to get the jobs, in ISO-8601 format. For example: 2016-12-21T19:13:17+05

-brief

Returns job details summary only

-statusonly

Returns only the job status and current phase name

resume job

Resumes a specified job that was paused.

Syntax

$ZDM_HOME/bin/zdmcli resume job
  -jobid job_id
  [-pauseafter pause_phase]

Options

Table F-7 ZDMCLI resume job Options

Option Description
-jobid job_id

Unique job ID value (integer) for the scheduled job

The job ID is assigned when the migration job is scheduled.

-pauseafter pause_phase

Pausees the migration job after running the specified phase