pdb_clone_management

Creates a new cloned PDB.

Format

emcli pdb_clone_management
     [-cloneToOracleCloud = Clone PDB to Container database (CDB) on Oracle Cloud]     -input_file = pdb_input_file

[ ]  indicates that the parameter is optional.

Options

  • cloneToOracleCloud

    Specifies if the destination CDB is on Oracle Cloud.

  • input_file

    Location of the file containing properties required for cloning a PDB. The allowed properties for this job are:

    SRC_CDB_TARGET = Enterprise Manager target name of the CDB containing the source PDB.

    SRC_CDB_TYPE = Enterprise Manager target type of the CDB containing the source PDB.

    SRC_CDB_CREDS = Named credentials for the source CDB.

    SRC_HOST = Enterprise Manager target name of host containing source CDB. If not provided, will be defaulted from CDB.

    SRC_HOST_CREDS = Named credentials for the source target host.

    SRC_PDB_TARGET = Enterprise Manager target name of the source PDB.

    SRC_WORK_DIR = Work directory at source host where files will be temporarily stored. If not provided, will be defaulted to agent work directory.

    DEST_HOST = Enterprise Manager target name of host containing destination CDB. If not provided, will be defaulted from CDB.

    DEST_HOST_CREDS = Named credentials for the destination target host. If destination host is on OPC, this should be Host SSH credentials.

    DEST_LOCATION = Data file location at the destination where the new PDB will be hosted.

    DEST_CDB_TARGET = Enterprise Manager target name of CDB where the new PDB should be cloned.

    DEST_CDB_TYPE = Enterprise Manager target type of destination CDB.

    DEST_CDB_CREDS = Named credentials for the destination CDB.

    DEST_PDB_NAME = Name of the new PDB.

    EXISTING_BACKUP = Absolute location of the existing backup in the file system, if it should be used to clone new PDB.

    EXISTING_BACKUP_METADATA = Absolute location of the metadata template of the backup. Required, if EXISTING_BACKUP is provided.

    BACKUP_TYPE = [TAR || OSIMAGE || RMAN]

    If existing backup is provided, this represents the type of the backup. If not, this represents the type of backup that should be taken during job execution. If both, EXISTING_BACKUP and BACKUP_TYPE are not provided, source PDB will be unplugged and copied over to destination for creating new clone. After the data files are copied, the source PDB will be plugged back.

    Mandatory properties:

    SRC_PDB_TARGET, SRC_HOST_CREDS, SRC_CDB_CREDS, SRC_WORK_DIR, DEST_HOST_CREDS, DEST_LOCATION, DEST_CDB_TARGET, DEST_CDB_TYPE, DEST_CDB_CREDS, DEST_PDB_NAME

    Clone Types:

    Full Clone - Live backup: Takes a backup of the source PDB and creates a new PDB. BACKUP_TYPE specifies the type of backup.

    Full Clone - Existing Backup: Uses an existing backup of the source PDB and creates a new PDB. BACKUP_TYPE specifies the type of backup.

    EXISTING_BACKUP: Specifies the backup name and EXISTING_BACKUP.

    METADATA: Specifies the metadata for the backup.Full Clone - Unplug/Plug: Unplugs the source PDB, creates a new PDB at the destination using the unplugged source, and plugs the source back.

Example

The following example creates a new cloned PDB from the information contained in the pdb_clone.props file.

emcli pdb_clone_management 
      -input_file=data:/u01/files/pdb_clone.props