Using the dbaascli Utility on Exadata Cloud@Customer

Learn to use the dbaascli utility on Exadata Cloud@Customer.

About Using the dbaascli Utility on Exadata Cloud@Customer

You can use the dbaascli utility to perform various database lifecycle and administration operations on Exadata Cloud@Customer such as changing the password of a database user, starting a database, managing pluggable databases (PDBs), scaling the CPU core count in disconnected mode, and more.

You must use the DBaaS console or command-line interface to scale resources. The capabilities of the dbaascli utility are in addition to, and separate from, the Oracle Cloud Infrastructure Console, API, or command-line interface (CLI). Unless specified differently, you need root access to dbaascli to run all administration commands.

To use the utility, you must be connected to an Exadata Cloud@Customer virtual machine. See Connecting to a Virtual Machine with SSH.

To get possible commands available with dbaascli, run dbaascli --help.

To get command-specific help, run dbaascli command --help. For example, dbaascli database create --help.

Creating Oracle Database Using dbaascli

Using dbaascli, you can create an Oracle Database by first creating an Oracle Database home of desired version, followed by creating a database in that Oracle Database home.

Listing Available Software Images and Versions for Database

To get a list of available supported versions for creating Oracle Database, use the dbaascli cswlib showImages command.

  1. Connect to the virtual machine as the opc user.

    For detailed instructions, see Connecting to a Virtual Machine with SSH.

  2. Start a root user command shell:
    sudo -s
  3. Run the following command:
    dbaascli cswlib showImages

    The command output lists the available database software images.

  4. Exit the root user command shell:
    exit

    For more details on advanced supported options, see dbaascli cswlib showImages.

Example 21-1 dbaascli cswlib showImages

dbaascli cswlib showImages

DBAAS CLI version MAIN Executing command cswlib showImages 
INFO : Log file => /var/opt/oracle/log/list/list_2021-05-10_10:11:00.56966610630.log 
INFO: Using custom url : https://swiftobjectstorage.us-phoenix-1.oraclecloud.com/v1/intexadatateam/qa-patches/images 
############ List of Available DB Images #############
1.IMAGE_TAG=19.8.0.0.0
VERSION=19.8.0.0.0
DESCRIPTION=19c JUL 2020 DB Image
IMAGE_ALIASES=19000-19800,19000-JUL2020

2.IMAGE_TAG=19.8.0.0.0-NC
VERSION=19.8.0.0.0
DESCRIPTION=19c JUL 2020 Non CDB Image
IMAGE_ALIASES=19000-NC19800,19000-NCJUL2020

3.IMAGE_TAG=19.9.0.0.0
VERSION=19.9.0.0.0
DESCRIPTION=19c OCT 2020 DB Image
IMAGE_ALIASES=19000-19900,19000-OCT2020

4.IMAGE_TAG=19.9.0.0.0-NC
VERSION=19.9.0.0.0
DESCRIPTION=19c OCT 2020 Non CDB Image
IMAGE_ALIASES=19000-NC19900,19000-NCOCT2020
Note

You can specify the target version in dbaascli dbhome create command as --version value from the dbaascli cswlib showImages command output.

Creating Oracle Database Home

To create an Oracle Database home of desired version, use the dbaascli dbhome create command.

Note

You can create an Oracle Database home with a specified Oracle Home Name and Oracle Home Path. If you do not specify, then these are computed automatically (recommended).
  1. Connect to the virtual machine as the opc user.

    For detailed instructions, see Connecting to a Virtual Machine with SSH.

  2. Start a root user command shell:
    sudo -s
  3. Run the following command:
    dbaascli dbhome create --version Oracle Home Version
    Where:
    • --version specifies the Oracle Database version
    • --imageTag specifies the Image Tag of the image to be used
    For example:
    dbaascli dbhome create --version 19.9.0.0.0
  4. Exit the root user command shell:
    exit

    For more details on advanced supported options, see dbaascli dbhome create.

Running Prerequisite Checks Prior to Creating Oracle Database Home

To run prerequisites checks, use the --executePrereqs command option. This will perform only the prerequisite checks without performing the actual Oracle Database home creation.

  1. Connect to the virtual machine as the opc user.

    For detailed instructions, see Connecting to a Virtual Machine with SSH.

  2. Start a root user command shell:
    sudo -s
  3. Run the following command:
    dbaascli dbhome create --version Oracle Home Version --imageTag image tag --executePrereqs
    Where:
    • --version specifies the Oracle Database version
    • --imageTag specifies the Image Tag of the image to be used
  4. Exit the root user command shell:
    exit

    For more details on advanced supported options, see dbaascli dbhome create.

Creating Oracle Database In the Specified Oracle Database Home

To create an Oracle Database in the specified Oracle Database home of desired version, use the dbaascli database create command.

You can use the dbaascli database create command to:
  • Create a Container Database (CDB) or non-Container Database
  • Create a CDB with pluggable databases (PDBs)
  • Create an Oracle Database with the specified Character Set
  • Create Oracle Databases on a subset of cluster nodes
  1. Connect to the virtual machine as the opc user.

    For detailed instructions, see Connecting to a Virtual Machine with SSH.

  2. Start a root user command shell:
    sudo -s
  3. Run the following command:
    dbaascli database create --dbName database name --oracleHome Oracle Home Path
    Where:
    • --dbName specifies the name of the database
    • --oracleHome specifies Oracle home location
    To create a CDB, run the following command:
    dbaascli database create --dbName database name --oracleHome Oracle Home Path
    To create a non-CDB, run the following command:
    dbaascli database create --dbName database name --oracleHome Oracle Home Path --createAsCDB false

    When prompted, enter the sys and tde passwords.

  4. Exit the root user command shell:
    exit

    For more details on advanced supported options, see dbaascli database create.

Running Prerequisite Checks Prior to Creating Oracle Database

To run prerequisites checks, use the --executePrereqs command option. This will perform only the prerequisite checks without performing the actual Oracle Database creation.

  1. Connect to the virtual machine as the opc user.

    For detailed instructions, see Connecting to a Virtual Machine with SSH.

  2. Start a root user command shell:
    sudo -s
  3. Run the following command:
    dbaascli database create --dbName database name --oracleHome Oracle Home Path --executePrereqs
    Where:
    • --dbName specifies the name of the database
    • --oracleHome specifies the Oracle home location
  4. Exit the root user command shell:
    exit

    For more details on advanced supported options, see dbaascli database create.

Resuming or Reverting Oracle Database Creation Operation

To resume or revert a failed database creation operation, use the --resume or --revert command option.

For example:
dbaascli database create --dbName database name --oracleHome Oracle Home Path --resume
Note

  • While using the --resume or --revert command options, ensure that you use the same command from the same node that was used for actual create operation flow.
  • You can resume database creation only if there is a failure in the post database creation step.

Patching Oracle Grid Infrastructure and Oracle Databases Using dbaascli

Learn to use the dbaascli utility to perform patching operations for Oracle Grid Infrastructure and Oracle Database on an Exadata Cloud@Customer system.

Patching Databases using dbaascli

Using dbaascli, you can choose to patch a database by patching Oracle home, or by moving the database to an Oracle home with the desired patch level.

  • Patching an Oracle home (in-place patching). This updates all databases located in the Oracle home.
  • Moving a database to a different Oracle home that has the desired Oracle Database software version (out-of-place patching).
Patching a Database Home (In-Place Database Patching)

To patch an Oracle home, use the dbaascli dbhome patch command.

This will patch all databases running in the specified home, and the databases will remain in the home after the patching is complete. The following apply to using the dbhome patch command for in-place patching operations:
  • You can patch all of your database nodes or a subset of nodes.
  • Multi-node patching takes place in a rolling fashion.
  • Optionally, you can perform a software-only patch operation. Then, when you are ready, you can run datapatch to perform post-patch SQL actions.
  • You can patch an Oracle home containing one or more databases.

To patch an Oracle Home (dbhome):

  1. Connect to the virtual machine as the opc user.

    For detailed instructions, see Connecting to a Virtual Machine with SSH.

  2. Start a root user command shell:
    sudo -s
  3. Run the following command:
    dbaascli dbhome patch --oracleHome dbhome_path --targetVersion Oracle_Database_version
    Where:
    • --oracleHome identifies the path of the Oracle home to be patched.
    • --targetVersion specifies the target Oracle Database version to use for patching.
    For example:
    dbaascli dbhome patch --oracleHome /u02/app/oracle/product/19.0.0.0/dbhome_2 --targetVersion 19.9.0.0
  4. Exit the root user command shell:
    exit

    For more details on advanced supported options, see dbaascli dbhome patch.

Moving a Database to a Different Oracle Home (Out-of-Place Patching)

To patch an Oracle Database by moving it to an Oracle home that is already at the desired patch level, use the dbaascli database move command.

After the database move operation is complete, the database runs using the Oracle Database software version of the target Oracle Home.

To patch a database by moving it to a different Oracle Home:

  1. Connect to the virtual machine as the opc user.

    For detailed instructions, see Connecting to a Virtual Machine with SSH.

  2. Start a root user command shell:
    sudo -s
  3. Run the following command:
    dbaascli database move --ohome path_to_target_oracle_home --dbname database_name
    Where:
    • --ohome identifies the path of the target Oracle home that uses the desired Oracle Database software version. Note that the target Oracle home must exist in your system prior to using the database move command.
    • --dbname specifies the name of the database that is being moved.
    For example:
    dbaascli database move --ohome /u02/app/oracle/product/19.0.0.0/dbhome_2 --dbname xyz
  4. Exit the root user command shell:
    exit

    For more details on advanced supported options, see dbaascli database move.

Patching Oracle Grid Infrastructure

To apply a patch to Oracle Grid Infrastructure, use the grid patch command.

  1. Connect to the virtual machine as the opc user.

    For detailed instructions, see Connecting to a Virtual Machine with SSH.

  2. Start a root user command shell:
    sudo -s
  3. Run the following command:
    dbaascli grid patch --targetVersion target_software_version_number

    Where --targetVersion identifies target software version that the Oracle Grid Infrastructure will be patched to.

    For example:
    dbaascli grid patch --targetVersion 19.11.0.0.0
  4. Exit the root user command shell:
    exit

    For more details on advanced supported options, see dbaascli grid patch.

Listing Available Software Images and Versions for Database and Grid Infrastructure

To produce a list of available supported versions for patching, use the dbaascli cswlib showImages command.

  1. Connect to the virtual machine as the opc user.

    For detailed instructions, see Connecting to a Virtual Machine with SSH.

  2. Start a root user command shell:
    sudo -s
  3. Run the following command:
    dbaascli cswlib showImages

    The command output lists the available database software images and grid software images.

  4. Exit the root user command shell:
    exit

    For more details on advanced supported options, see dbaascli cswlib showImages.

Example 21-2 dbaascli cswlib showImages

dbaascli cswlib showImages

DBAAS CLI version MAIN Executing command cswlib showImages
INFO : Log file => /var/opt/oracle/log/list/list_2021-05-10_10:11:00.56966610630.log
INFO: Using custom url : https://swiftobjectstorage.us-phoenix-1.oraclecloud.com/v1/intexadatateam/qa-patches/images
############ List of Available DB Images #############

1.IMAGE_TAG=19.7.0.0.0-NC
  VERSION=19.7.0.0.0
  DESCRIPTION=19c APR 2020 Non CDB Image
  IMAGE_ALIASES=19000-NC19700,19000-NCAPR2020,NC19.7.0.0.0-NC

2.IMAGE_TAG=19.8.0.0.0
  VERSION=19.8.0.0.0
  DESCRIPTION=19c JUL 2020 DB Image
  IMAGE_ALIASES=19000-19800,19000-JUL2020

3.IMAGE_TAG=19.8.0.0.0-NC
  VERSION=19.8.0.0.0
  DESCRIPTION=19c JUL 2020 Non CDB Image
  IMAGE_ALIASES=19000-NC19800,19000-NCJUL2020,NC19.8.0.0.0-NC

4.IMAGE_TAG=19.9.0.0.0
  VERSION=19.9.0.0.0
  DESCRIPTION=19c OCT 2020 DB Image
  IMAGE_ALIASES=19000-19900,19000-OCT2020

5.IMAGE_TAG=19.9.0.0.0-NC
  VERSION=19.9.0.0.0
  DESCRIPTION=19c OCT 2020 Non CDB Image
  IMAGE_ALIASES=19000-NC19900,19000-NCOCT2020,NC19.9.0.0.0-NC

############ List of Available Grid Images #############

1.IMAGE_TAG=12.2.0.1.201020
VERSION=12.2.0.1.201020
DESCRIPTION=12c OCT 2020 GI Image
IMAGE_ALIASES=

2.IMAGE_TAG=12.2.0.1.210119
VERSION=12.2.0.1.210119
DESCRIPTION=12c JAN 2021 GI Image
IMAGE_ALIASES=

3.IMAGE_TAG=12.2.0.1.210420
VERSION=12.2.0.1.210420
DESCRIPTION=12c APR 2021 GI Image
IMAGE_ALIASES=

4.IMAGE_TAG=18.12.0.0.0
VERSION=18.12.0.0.0
DESCRIPTION=18c OCT 2020 GI Image
IMAGE_ALIASES=

5.IMAGE_TAG=18.13.0.0.0
VERSION=18.13.0.0.0
DESCRIPTION=18c JAN 2021 GI Image
IMAGE_ALIASES=

6.IMAGE_TAG=18.14.0.0.0
VERSION=18.14.0.0.0
DESCRIPTION=18c APR 2021 GI Image
IMAGE_ALIASES=

7.IMAGE_TAG=19.10.0.0.0
VERSION=19.10.0.0.0
DESCRIPTION=19c JAN 2021 GI Image
IMAGE_ALIASES=

Performing a Precheck Before Patching Databases and Grid Infrastructure

You can perform a prerequisites-checking operation (also called a "precheck") for the commands in this topic using the applicable precheck flag.

Running prechecks allows you to run only the precheck portion of the patching operation without performing actual patching. Oracle recommends running prechecks to discover software issues that could prevent successful patching.

To perform patching prechecks, first, connect to a virtual machine in your Exadata Cloud@Customer instance as the root user.

Precheck for Oracle Home Patching (In-Place Patching)

Use the --executePrereqs flag with the dbaascli dbhome patch command.

  1. Connect to the virtual machine as the opc user.

    For detailed instructions, see Connecting to a Virtual Machine with SSH.

  2. Start a root user command shell:
    sudo -s
  3. Run the following command:
    dbaascli dbhome patch --oracleHome dbhome_path --targetVersion Oracle_Database_version --executePrereqs
    Where:
    • --oracleHome identifies the path of the Oracle home to be prechecked.
    • --targetVersion specifies the target Oracle Database version to precheck.
  4. Exit the root user command shell:
    exit
Precheck for Database Move Patching (Out-of-Place Patching)

Use the --precheck flag with the dbaascli database move command.

  1. Connect to the virtual machine as the opc user.

    For detailed instructions, see Connecting to a Virtual Machine with SSH.

  2. Start a root user command shell:
    sudo -s
  3. Run the following command:
    dbaascli database move --ohome path_to_target_oracle_home --dbname database_name --precheck
    Where:
    • --ohome identifies the path of the target Oracle Home that uses the desired Oracle Database software version. Note that the target Oracle Home must exist in your system prior to using the database move command.
    • --dbname specifies the name of the database that is being moved
  4. Exit the root user command shell:
    exit
Precheck for Oracle Grid Infrastructure Patching

Use the --executePrereqs flag with the dbaascli grid patch command.

  1. Connect to the virtual machine as the opc user.

    For detailed instructions, see Connecting to a Virtual Machine with SSH.

  2. Start a root user command shell:
    sudo -s
  3. Run the following command:
    dbaascli grid patch --targetVersion target_software_version_number --executePrereqs

    Where --targetVersion identifies target software version that the Oracle Grid Infrastructure will be patched to.

  4. Exit the root user command shell:
    exit

Resuming or Rolling Back a Patching Operation

You can resume or revert a failed patching operation. Reverting a patch is known as a rollback.

Resuming a Patch Operation

To resume a patching operation, use the --resume flag with the original patching command.

  1. Connect to the virtual machine as the opc user.

    For detailed instructions, see Connecting to a Virtual Machine with SSH.

  2. Start a root user command shell:
    sudo -s
  3. Run the original patching command to resume a patching operation:
    For example:
    dbaascli dbhome patch --oracleHome /u02/app/oracle/product/19.0.0.0/dbhome_2 --targetVersion 19.9.0.0 --resume
  4. Exit the root user command shell:
    exit
Rolling Back a Patch

Use the --rollback flag with the original patching command to roll back (revert) a patching operation.

  1. Connect to the virtual machine as the opc user.

    For detailed instructions, see Connecting to a Virtual Machine with SSH.

  2. Start a root user command shell:
    sudo -s
  3. Run the original patching command to roll back (revert) a patching operation:
    For example:
    dbaascli grid patch --targetVersion 19.11.0.0.0 --rollback
    Note

    • Resume and Rollback operations are supported for Oracle Home patching and Oracle Grid Infrastructure patching operations. They are not supported for database move operations.
    • When resuming or rolling back a patching operation, you must run the resume or rollback command from the same node that was used to run the original patching command, and you must run the original command with the addition of the --resume or --rollback flag.
  4. Exit the root user command shell:
    exit

Updating Cloud Tooling Using dbaascli

To update the cloud tooling release for Oracle Exadata Cloud@Customer, complete this procedure.

Cloud-specific tooling is used on the Exadata Cloud@Customer Guest VMs for local operations, including dbaascli commands.

The cloud tooling is automatically updated by Oracle when new releases are made available. If needed, you can follow the steps below to ensure you have the latest version of the cloud-specific tooling on all of the virtual machines in the VM cluster.
Note

You can update the cloud-specific tooling by downloading and applying a software package containing the updated tools.
  1. Connect to a virtual machine as the opc user.

    For detailed instructions, see Connecting to a Virtual Machine with SSH.

  2. Start a root user command shell:
    sudo -s
  3. To update to the latest available cloud tooling release, run the following command:
    dbaascli admin updateStack --version LATEST

    The command takes care of updating the cloud tooling release on all the nodes of the cluster.

    For more details and other available options, refer to dbaascli admin updateStack --help.

Release Notes

This section provides a brief overview of changes made in a various releases of dbaascli.

Release 21.2.1.x.x

  • Redesigned Oracle Grid Infrastructure patching operation and added ability to resume from failed point, patch on subset of nodes, instance draining, and other enhancements. For details, see dbaascli grid patch --help. Also refer to the Patching Oracle Grid Infrastructure and Oracle Database Using dbaascli section.
  • Deprecated the support for exadbcpatchmulti for patching operations. dbaascli dbhome patch and dbaascli grid patch commands are provided for patching operation for database homes and Oracle Grid Infrastructure. Refer to the Patching Oracle Grid Infrastructure and Oracle Database Using dbaascli section for details. Also see, dbaascli Command Reference section.
  • Deprecated the support for dbaascli tools patch command to bring consistency in the command conventions. The new command is dbaascli admin updateStack.
  • Redesigned PDB management APIs for create, local clone, and remote clone operations. For details, see dbaascli pdb --help.
  • Redesigned database delete API. For details, see dbaascli database delete --help.
  • Revamped dbhome creation (support for custom software image, scale-out operation). For details, see dbaascli dbhome create --help.
  • Support for database creation on subset of cluster nodes. For details, see dbaascli database create --help.
  • Ability to run dbaascli in disconnected mode. Executing dbaascli command with --waitForCompletion=false gets you a job ID that can be queried later to get the status of the operation, using dbaascli job getStatus –jobid job_id
  • Enhanced dbhome patching experience with introduction of multiple options like skipPDBs, continueWithDowntime, and so on. For details, see dbaascli dbhome patch --help.
  • Support for better diagnostic collection. For details, see dbaascli diag collect --help.
  • Minor improvements in the area of database upgrade automation.
  • Various bug fixes and stability improvements.

dbaascli Command Reference

Use these commonly used commands to manage Exadata Cloud@Customer.

dbaascli admin updateStack

To install or update a dbaastools RPM, use the dbaascli admin updateStack command.

Prerequisites

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli admin updateStack --version | --location
[--resume]
[--prechecksOnly]
[--nodes]
[--force]
Where:
  • --version specifies dbaastools RPM patch ID or version number or LATEST
  • --location specifies the full path of the dbaastools RPM to be installed
  • --resume resumes the previous execution
  • --prechecksOnly runs only the prechecks for this operation
  • --nodes specifies a comma-delimited list of nodes to install the RPM on. If you do not pass this argument, then the RPM will be installed on all of the cluster nodes
  • --force forces the installation of a lower RPM version

Example 21-3 dbaascli admin updateStack

dbaascli admin updateStack --location /var/opt/oracle/dbaas_acfs/dbaastools_exa-1.0-1+MAIN_210507.0125.x86_64.rpm
DBAAS CLI version 21.1.1.1.0
Executing command admin updatestack --location /var/opt/oracle/dbaas_acfs/dbaastools_exa-1.0-1+MAIN_210507.0125.x86_64.rpm --force
INFO : Review log file => /var/opt/oracle/log/tooling/Update/Update_2021-05-13_15:30:19.82522522804.log
============ Calling RPM update plugin ===========
Loading PILOT...
Session ID of the current execution is: 93
Log file location: /var/opt/oracle/log/tooling/Update/pilot_2021-05-13_03-30-21-PM
-----------------
Running Plugin_initialization job
Completed Plugin_initialization job
-----------------
Running Default_value_initialization job
Completed Default_value_initialization job
-----------------
Running Rpm_version_validation job
Completed Rpm_version_validation job
-----------------
Running Rpm_source_validation job
Completed Rpm_source_validation job
-----------------
Running Disk_space_validate job
Completed Disk_space_validate job
-----------------
Running Rpm_download job
Completed Rpm_download job
-----------------
Running Rpm_validation job
-----------------
Running Rpm_local_installation job
Completed Rpm_local_installation job
-----------------
Running Rpm_remote_installation job
Completed Rpm_remote_installation job
-----------------
Running Installed_rpm_backup job
Completed Installed_rpm_backup job
-----------------
Running Rpm_cleanup job
Completed Rpm_cleanup job
============ Calling exacloud config plugin ===========
Loading PILOT...
Session ID of the current execution is: 94
Log file location: /var/opt/oracle/log/tooling/Update/pilot_2021-05-13_03-31-07-PM
-----------------
Running Plugin_initialize job
Completed Plugin_initialize job
-----------------
Running Validate_grid job
Completed Validate_grid job
-----------------
Running Validate_setup_scripts job
-----------------
Running Setup_journal_service job
-----------------
Running Setup_users job
Completed Setup_users job
-----------------
Running Create_sudoers job
-----------------
Running TTY_setup job
-----------------
Running Setup_atp_file_handlers job
-----------------
Running Mount_atp_huge_pages job
-----------------
Running Setup_huge_pages job
-----------------
Running Setup_rc_local job
-----------------
Running Update_u02_ownership job
-----------------
Running Setup_clean_db_logs_cron_job job
-----------------
Running Remove_rpm_update_cron_entries job
Completed Remove_rpm_update_cron_entries job
-----------------
Running Setup_backup_cron_entries job
Completed Setup_backup_cron_entries job
-----------------
Running Setup_acfs_symlinks job
-----------------
Running Create_acfs_volume job
-----------------
Running Add_oracle_user_to_acfs_resource job
Completed Add_oracle_user_to_acfs_resource job
-----------------
Running Setup_db_agent_wallet job
-----------------
Running Setup_tcps_wallet job
-----------------
Running Setup_image_encryption_wallet job
Completed Setup_image_encryption_wallet job
-----------------
Running Setup_bashrc job
-----------------
Running Pin_cluster_nodes job
-----------------
Running Setup_sys_asmsnmp_password job
-----------------
Running Configure_network_security job
-----------------
Running Setup_tcps_listeners job
-----------------
Running Populate_grid_creg job
-----------------
Running Upgrade_ahf job
Completed Upgrade_ahf job
-----------------
Running Setup_python job
Completed Setup_python job
-----------------
Running Setup_mysql job
Completed Setup_mysql job
-----------------
Running Enable_SQL_patch_update job
-----------------
Running Update_ADBD_listener_configuration job
-----------------
Running Setup_ovm_templates job
-----------------
Running Remove_exadbcpatch_keys job
Completed Remove_exadbcpatch_keys job
-----------------
Running Synchronize_config_files job
Completed Synchronize_config_files job
-----------------
Running Disable_auto_rpm_update job
Completed Disable_auto_rpm_update job
-----------------
Running Remove_wget_rpm job
Completed Remove_wget_rpm job
-----------------
Running Toggle_cleandb_logs job
Completed Toggle_cleandb_logs job
-----------------
Running Setup_backup_assistant job
Completed Setup_backup_assistant job
-----------------
Running Clean_duplicate_images job
Completed Clean_duplicate_images job
-----------------
Running Update_sql_net_ora_file job
Completed Update_sql_net_ora_file job
-----------------
Running Update_db_env_file job
Completed Update_db_env_file job
-----------------
Running Setup_backup_json_metastore job

dbaascli cpuscale get_status

To check the status of current or last scale request performed when network connectivity between the Control Plane Server and OCI region is disrupted, use the dbaascli cpuscale get_status command.

Prerequisites

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

Displays various command execution states as it progresses from scheduled, running, and finally to success or failure.

dbaascli cpuscale get_status

dbaascli cpuscale update

To scale up or down the CPU core count for a virtual machine in a VM cluster when network connectivity between the Control Plane Server and OCI region is disrupted, use the dbaascli cpuscale update command.

Prerequisites

To scale OCPUs up or down in a VM cluster in disconnected mode, run the dbaascli cpuscale update and dbaascli cpuscale get_status commands from any node inside a VM cluster to change the CPU core count for that cluster. If you have more than one VM cluster, then run a separate command from any node inside each VM cluster you want to scale up or down. These commands are designed to not work if issued during the normal connected mode and will time out after 600 seconds (10 minutes).

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

Exadata Cloud@Customer is considered to be in a Disconnected mode when there is a loss of connectivity with the DBaaS control plane running on Oracle Cloud Infrastructure (OCI).

dbaascli cpuscale update 
--coreCount coreCount 
--message message
Where:
  • --coreCount specifies the number of CPUs that you want to scale up or down per VM in a cluster
  • --message optionally, you can include a message for your reference

dbaascli cswlib download

To download available software images and makes them available in your Exadata Cloud@Customer environment, use the dbaascli cswlib download command.

Prerequisites

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli cswlib download --version | --ohImageType
--imageTag
Where:
  • --version specifies an Oracle home image version
  • --ohImageType specifies the image type. Valid values: db or gi
  • --imageTag specifies the image tag of the image

Example 21-4 dbaascli cswlib download --ohImageType --imageTag

dbaascli cswlib download --ohImageType db --imageTag 19.9.0.0.0
DBAAS CLI version 21.2.1.0.0
Executing command cswlib download --ohImageType db --imageTag 19.9.0.0.0
INFO : Download running for image_tag 19.9.0.0.0 and oh_image_type db, it may take few mins...
INFO: CSWLIB update latest db image bits
INFO: Log file is: /var/opt/oracle/log/misc/cswlib/cswlib_2021-07-12_05:45:52.77032639836.log
INFO: Using custom url : https://host.example.com/v1/intexadatateam/qa-patches/images
INFO : dbimage fixup executed.
INFO :: Successfully downloaded cswlib image image_location=/var/opt/oracle/dbaas_acfs/dbnid/19.9.0.0.0
INFO: CSWLIB update_bits of 19.9.0.0.0 db succeded !
INFO: dbaascli dbimage activateBP needs to be run to make the downloaded BP the default!

dbaascli cswlib showImages

To view the list of available Database and Grid Infrastructure images, use the dbaascli cswlib showImages command.

Prerequisites

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

cswlib showImages 
[--product]
[--containerURL]

Where:

  • --product identifies Oracle home product type. Valid values: database or grid.
  • --containerURL specifies OSS URI for Oracle Home Images.

Example 21-5 dbaascli cswlib showImages

dbaascli cswlib showImages

DBAAS CLI version MAIN Executing command cswlib showImages
INFO : Log file => /var/opt/oracle/log/list/list_2021-05-10_10:11:00.56966610630.log
INFO: Using custom url : https://swiftobjectstorage.us-phoenix-1.oraclecloud.com/v1/intexadatateam/qa-patches/images
############ List of Available DB Images #############

1.IMAGE_TAG=19.7.0.0.0-NC
  VERSION=19.7.0.0.0
  DESCRIPTION=19c APR 2020 Non CDB Image
  IMAGE_ALIASES=19000-NC19700,19000-NCAPR2020,NC19.7.0.0.0-NC

2.IMAGE_TAG=19.8.0.0.0
  VERSION=19.8.0.0.0
  DESCRIPTION=19c JUL 2020 DB Image
  IMAGE_ALIASES=19000-19800,19000-JUL2020

3.IMAGE_TAG=19.8.0.0.0-NC
  VERSION=19.8.0.0.0
  DESCRIPTION=19c JUL 2020 Non CDB Image
  IMAGE_ALIASES=19000-NC19800,19000-NCJUL2020,NC19.8.0.0.0-NC

4.IMAGE_TAG=19.9.0.0.0
  VERSION=19.9.0.0.0
  DESCRIPTION=19c OCT 2020 DB Image
  IMAGE_ALIASES=19000-19900,19000-OCT2020

5.IMAGE_TAG=19.9.0.0.0-NC
  VERSION=19.9.0.0.0
  DESCRIPTION=19c OCT 2020 Non CDB Image
  IMAGE_ALIASES=19000-NC19900,19000-NCOCT2020,NC19.9.0.0.0-NC

############ List of Available Grid Images #############

1.IMAGE_TAG=12.2.0.1.201020
VERSION=12.2.0.1.201020
DESCRIPTION=12c OCT 2020 GI Image
IMAGE_ALIASES=

2.IMAGE_TAG=12.2.0.1.210119
VERSION=12.2.0.1.210119
DESCRIPTION=12c JAN 2021 GI Image
IMAGE_ALIASES=

3.IMAGE_TAG=12.2.0.1.210420
VERSION=12.2.0.1.210420
DESCRIPTION=12c APR 2021 GI Image
IMAGE_ALIASES=

4.IMAGE_TAG=18.12.0.0.0
VERSION=18.12.0.0.0
DESCRIPTION=18c OCT 2020 GI Image
IMAGE_ALIASES=

5.IMAGE_TAG=18.13.0.0.0
VERSION=18.13.0.0.0
DESCRIPTION=18c JAN 2021 GI Image
IMAGE_ALIASES=

6.IMAGE_TAG=18.14.0.0.0
VERSION=18.14.0.0.0
DESCRIPTION=18c APR 2021 GI Image
IMAGE_ALIASES=

7.IMAGE_TAG=19.10.0.0.0
VERSION=19.10.0.0.0
DESCRIPTION=19c JAN 2021 GI Image
IMAGE_ALIASES=

dbaascli database bounce

To shut down and restart a specified Exadata Cloud@Customer database, use the dbaascli database bounce command.

Prerequisites

Run the command as the oracle user.

To use the utility, you must be connected to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli database bounce
[--dbname]
[--pdb]
--service
--user
[--password]
Where:
  • --dbname specifies the name of the database
  • --pdb specifies PDB name, defaults to ORACLE_SID
  • --service specifies the name of the service
  • --user specifies the user name of the service
  • --password specifies the password of the user

The command performs a database shutdown in immediate mode. The database is then restarted and opened. In Oracle Database 12c or later, all of the PDBs are also opened.

Example 21-6 dbaascli database bounce

dbaascli database bounce --service db19_MYPDB.paas.oracle.com --user oracle

dbaascli database changepassword

To change the password of an Oracle Database user, use the dbaascli database changepassword command.

Prerequisites

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli database changepassword --dbname dbname
Where:
  • --dbname specifies the name of the database that you want to act on

Example 21-7 dbaascli database changePassword

dbaascli database changepassword --dbname db19

dbaascli database create

To create Oracle Database, use the dbaascli database create command.

Prerequisite

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli database create --dbName --oracleHome | --oracleHomeName
[--dbSID]
[--dbNCharset]
[--tdeConfigMethod]
[--kmsKeyOCID]
[--nodeList]
[--executePrereqs]
[--skipPrereqs]
[--dbLanguage]
[--dbTerritory]
[--fraDestination]
[--fraSizeInMB]
[--resume]
[--dbUniqueName]
[--revert]
[--dbCharset]
[--honorNodeNumberForInstance]
[--waitForCompletion]
[--sgaSizeInMB]
[--pdbName]
[--pdbAdminUserName]
[--datafileDestination]
[--pgaSizeInMB]
[--createAsCDB]
Where:
  • --dbname specifies the name of the database
  • --oracleHome specifies the location of the Oracle home
  • --oracleHomeName specifies the name of the Oracle home
  • --dbSID specifies the SID of the database
  • --dbNCharset specifies database national character set
  • --tdeConfigMethod specifies TDE configuration method. Valid values: FILE, KMS
  • --kmsKeyOCID specifies KMS key OCID to use for TDE. This is applicable only if KMS is selected for TDE
  • --nodeList specifies a comma-delimited list of nodes for the database
  • --executePrereqs specifies yes to run only the prereqs for this operation. Valid values: yes or no
  • --skipPrereqs specifies yes to skip prerequisites for this operation. Valid values: yes or no
  • --dbLanguage specifies the database language
  • --dbTerritory specifies the database territory
  • --fraDestination specifies ASM disk group name to use for database Fast Recovery Area
  • --fraSizeInMB specifies the Fast Recovery Area size value in megabyte unit
  • --resume resumes the previous execution
  • --dbUniqueName specifies database unique name
  • --revert rolls back the previous run
  • --dbCharset specifies database character set
  • --honorNodeNumberForInstance specifies true or false to indicate instance name to be suffixed with the cluster node numbers. Default value: true
  • --waitForCompletion specifies false to run the operation in the background. Valid values: true or false
  • --sgaSizeInMB specifies the sga_target value in megabyte unit
  • --pdbName specifies the name of the PDB
  • --pdbAdminUserName specifies the PDB admin user name
  • --datafileDestination specifies the ASM disk group name to use for database datafiles
  • --pgaSizeInMB specifies the pga_aggregate_target value in megabyte unit
  • --createAsCDB specifies true or false to create the database as CDB or non-CDB

Example 21-8 dbaascli database create

dbaascli database create --dbName db19 --oracleHomeName myhome19 --dbSid db19sid --nodeList node1,node2 --createAsCDB true

dbaascli database delete

To delete an Oracle Database, use the dbaascli database delete command.

Prerequisite

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli database delete --dbname
[--deleteArchiveLogs]
[--deleteBackups]
[--precheckOnly]
[--waitForCompletion]
Where:
  • --dbname specifies the name of the database.
  • --deleteArchiveLogs specifies true or false to indicate deletion of database archive logs.
  • --deleteBackups specifies true or false to indicate deletion of database backups.
  • --precheckOnly specifies yes to run only the prechecks for this operation. Valid values: yes or no.
  • --waitForCompletion specifies false to run the operation in the background. Valid values: true or false.

Example 21-9 dbaascli database delete

dbaascli database delete --dbname db19

dbaascli database modifyParameters

To modify or reset initialization parameters for an Oracle Database, use the dbaascli database modifyParameters command.

Prerequisite

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli database modifyParameters --dbname --setParameters | --resetParameters | --responseFile
[--backupPrepared]
[--instance]
[--allowBounce]
Where:
  • --dbname specifies the name of the database.
  • --setParameters specifies a comma-delimited list of parameters to modify with new values. For example: parameter1=valueA,parameter2=valueB,and so on
  • --resetParameters specifies a comma-delimited list of parameters to be reset to their corresponding default values. For example, parameter1=valueA,parameter2=valueB, and so on
  • --responseFile specifies the absolute location of the response JSON file to modify the database parameters
  • --backupPrepared acknowledges that a proper database backup is in place prior to modifying critical or sensitive parameters.
  • --instance specifies the name of the instance on which the parameters will be processed. If not specified, then the operation will be performed at the database level.
  • --allowBounce grants permission to bounce the database in order to reflect the changes on applicable static parameters.

Example 21-10 dbaascli database modifyParameters

dbaascli database modifyParameters --dbname dbname --setParameters "log_archive_dest_state_17=ENABLE"

dbaascli database move

To perform out-of-place patching, use the dbaascli database move command.

Prerequisites

  • Before performing a move operation, ensure that all of the database instances associated with the database are up and running.

  • Run the command as the root user.

    To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

    See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli database move --oracleHome | --oracleHomeName
--dbname
[--resume]
[--skipPDBs]
[--ignorePrereqFailure]
[--continueWithDbDowntime]
[--rollback]
[--skipDatapatch]
[--skipClosedPDBs]
[--skipPrereqs]
[--executePrereqs]

Where:

  • database move moves the database from one home to another home
  • --oracleHome specifies Oracle home path
  • --oracleHomeName specifies the name of Oracle home
  • --dbname specifies the name of the database
  • --resume resumes the previous run
  • --skipPdbs skips running the datapatch on a specified comma-delimited list of PDBs. For example: pdb1,pdb2...
  • --ignorePrereqFailure ignores prerequisite check run failures
  • --continueWithDbDowntime specifies to continue patching with database downtime
  • --rollback rolls back the patches applied
  • --skipDatapatch skips datapatch execution on the databases
  • --skipClosedPDBs skips running datapatch on closed PDBs
  • --skipPrereqs skips prereqs
  • --executePrereqs runs prereqs

Example 21-11 dbaascli database move

dbaascli database move --dbname testdb1 --oracleHome /u02/app/oracle/product/12.1.0/dbhome_2

dbaascli database runDatapatch

To patch an Oracle Database, use the dbaascli database runDatapatch command.

Prerequisites

  • Before performing a move operation, ensure that all of the database instances associated with the database are up and running.

  • Run the command as the root user.

    To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

    See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli database runDatapatch --dbname
[--resume]
[--skipPdbs | --pdbs]
[--executePrereqs | --ignorePrereqFailure | --skipPrereqs]
[--patchList]
[--skipClosedPdbs]
[--rollback]

Where:

  • --dbname specifies the name of the database
  • --resume resumes the previous run
  • --skipPdbs skips running the datapatch on a specified comma-delimited list of PDBs. For example: pdb1,pdb2...
  • --pdbs runs the datapatch only on a specified command-delimited list of PDBs. For example: pdb1,pdb2...
  • --executePrereqs runs prerequisite checks
  • --ignorePrereqFailure ignores prerequisite check run failures
  • --skipPrereqs skips prerequisite checks
  • --patchList applies or rolls back the specified comma-delimited list of patches. For example: patch1,patch2...
  • --skipClosedPdbs skips running the datapatch on closed PDBs
  • --rollback rolls back the patches applied

dbaascli database start

To start an Oracle Database, use the dbaascli database start command.

Prerequisites

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli database start
[--dbname]
[--mode]
[--force]
Where:
  • --dbname specifies the name of the database
  • --mode mount or nomount for database and write, read, or upgrade for PDB
  • --force forces the database to stop

The command starts and opens the database. In Oracle Database 12c or later, all of the PDBs are also opened.

Example 21-12 dbaascli database start

dbaascli database start --dbname dbname --mode mount

dbaascli database status

To check the status of an Oracle Database, use the dbaascli database status command.

Prerequisites

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli database status
[--service][--dbname] 
[--user]
[--password]
Where:
  • --service specifies the name of the service
  • --dbname specifies the name of the database
  • --user specifies the user name of the service
  • --password specifies the password of the user

Output from the command includes the open mode of the database, the software release and edition of the database, and release version of other software components.

Example 21-13 dbaascli database status

dbaascli database status --dbname db19

dbaascli database stop

To stop an Oracle Database, use the dbaascli database stop command.

Prerequisites

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli database stop
[-–dbname]
[--mode]
Where:
  • --dbname specifies the name of the database that you want to stop
  • --mode specifies the mode of the database. Valid values: abort, immediate, normal, transactional

The command performs a database shutdown in immediate mode. No new connections or new transactions are permitted. Active transactions are rolled back, and all connected users are disconnected.

Example 21-14 dbaascli database stop

dbaascli database stop --dbname db19

dbaascli database upgrade

To upgrade an Oracle Database, use the dbaascli database upgrade command.

Prerequisite

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli database upgrade --targetHome | --targetHomeName
[--ignorePrereqFailure]
[--allStandbyPrepared]
[--removeGRP]
[--dbname]
[--increaseCompatibleParameter]
[--executePrereqs]
[--standBy]
[--revert]
[--postUpgrade]
[--upgradeOptions]
Where:
  • --targetHome specifies the target Oracle home location
  • --targetHomeName specifies the name of the target Oracle Database home
  • --ignorePrereqFailure ignores prereq failures
  • --allStandbyPrepared required for Data Guard configured primary databases. Flags to acknowledge that all the required operations are performed on the standby databases prior to upgrading primary database
  • --removeGRP automatically removes the Guaranteed Restore Point (GRP) backup only if the database upgrade was successful
  • --dbname specifies the name of the database.
  • --increaseCompatibleParameter automatically increases the compatible parameter as part of the database upgrade. The parameter will get increased only if the database upgrade was successful
  • --executePrereqs runs only the preupgrade checks
  • --standBy use this option to upgrade standby databases in Data Guard configurations
  • --revert reverts an Oracle Database to its original Oracle home
  • --postUpgrade use this option if postupgrade fails and needs to rerun the postupgrade steps
  • --upgradeOptions use this option to pass DBUA-specific arguments to perform the Oracle Database upgrade. Refer to the corresponding Oracle documentation for the supported arguments and options.

Example 21-15 dbaascli database upgrade pre-upgrade requisite checks

dbaascli database upgrade --dbbname dbname --targetHome Target Oracle home location --executePrereqs

dbaascli dbhome create

To create an Oracle Database home of desired version, use the dbaascli dbhome create command.

Prerequisite

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli dbhome create
[--version]
[--oracleHome]
[--oracleHomeName]
[--enableUnifiedAuditing] 
[--bp | --imageTag]
Where:
  • --version specifies the version of Oracle home. For example, 12201, 12102
  • --oracleHome specifies the location of Oracle home
  • --oracleHomeName specifies user-defined Oracle home name. If not provided, then the default name will be used
  • --enableUnifiedAuditing specifies true or false to enable or disable unified auditing link option in Oracle home
  • --bp applies to local restore to download BP from cswlib. For example, APR2019, JUL2019
  • --imageTag specifies Oracle home image tag

dbaascli dbhome info

To view information about Oracle home directory locations, use the dbaascli dbhome info command.

Prerequisites

Run the command as root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli dbhome info
[--dbName]
[--hName]
Where:
  • --dbName specifies the name of the database
  • --hName specifies the name of Oracle home

When prompted:

  • Press Enter to view information about all of the Oracle homes that are registered in the VM cluster.
  • To view information about a particular Oracle home, specify an Oracle home name.

dbaascli dbHome patch

To patch Oracle home, use the dbaascli dbHome patch command.

Prerequisite

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli dbHome patch --oracleHome | --oracleHomeName
--targetVersion
[--resume]
[--continueWithDbDowntime]
[--skipUnreachableNodes]
[--nodes]
[--executePrereqs | --ignorePrereqFailure | --skipPrereqs]
[--skipDatapatch]
[--containerURL]
[--imageLocation]
[--containerURL | --imageLocation]
[--containerURL]
  [--imageOCID]
  [--imageSHA256]
[--skipPDBs]
[--skipClosedPDBs]
[--rollback]
Where:
  • --oracleHome specifies the path of Oracle home
  • --oracleHomeName specifies the name of Oracle home
  • --targetVersion specified the target version
  • --resume resumes the previous run
  • --continueWithDbDowntime continues patching with database downtime
  • --skipUnreachableNodes skips operation on unreachable nodes
  • --nodes specifies a comma-delimited list of nodes if patching has to be performed on a subset of nodes
  • --executePrereqs runs prereqs
  • --ignorePrereqFailure ignores prereq run failures
  • --skipPrereqs skips prereqs
  • --skipDatapatch skips running datapatch on the databases
  • --skipPdbs skips running datapatch on a given comma-delimited list of PDBs. For xample: cdb1:pdb1,cdb2:pdb2, and so on
  • --containerURL specifies custom URL for fetching the database image
  • --imageOCID OCI storage PAR OCID, required for images stored in OCI
  • --imageSHA256 SHA256 checksum, required for images stored in OCI
  • --imageLocation specifies custom database image location
  • --skipPDBs skips running the datapatch on a specified comma-delimited list of PDBs. For example: cdb1:pdb1,cdb2:pdb2, and so on
  • --skipClosedPdbs skips running datapatch on closed PDBs
  • --rollback rolls back patched Oracle home.

Example 21-16 dbaascli dbhome patch

dbaascli dbhome patch --targetVersion 19.10 --oracleHome /u02/app/oracle/product/19.0.0.0/dbhome_2

dbaascli dbhome purge

To delete unused Oracle home directory locations, use the dbaascli dbhome purge command.

Prerequisite

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli dbhome purge
[--hName]
[--hPath]
Where:
  • --hName specifies the name of Oracle home to purge
  • --hPath specifies the path of Oracle home to purge

If your entries are valid, and the Oracle home is not associated with a database, then the Oracle binaries are removed from the Oracle home directory location. The associated metadata is also removed from the system.

Example 21-17 dbaascli dbhome purge

dbaascli dbhome purge --hName homeName

dbaascli diag collect

To collect diagnostics, use the dbaascli diag collect command.

Prerequisite

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli diag collect
[--destLocation]
[--nodes]
[--components]
[--objectStoreBucketURI]
[--startTime]
[--dbNames]
[--endTime]
Where:
  • --destLocation specifies the location on domU to collect logs. Default: /var/opt/oracle/dbaas_acfs
  • --nodes specifies a comma-delimited list of nodes to collect logs
  • --components specifies a list of components for log collection. Valid values: db, gi, os, dbaastools, all
  • --objectStoreBucketURI specifies OSS PAR URL to upload log collections
  • --startTime specifies the start time for log collection. Valid date and time format: YYYY-MM-DDTHH24:MM:SS
  • --dbNames specifies the database name for which to collect logs. You can specify only one database name.
  • --endTime specifies the end time for log collection. Valid date and time format: YYYY-MM-DDTHH24:MM:SS

dbaascli diag healthCheck

To run diagnostic health checks, use the dbaascli diag healthCheck command.

Prerequisite

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli diag healthCheck
[--destLocation]
[--nodes]
[--objectStoreBucketURI]
Where:
  • --destLocation specifies the location on domU to collect logs. Default: /var/opt/oracle/dbaas_acfs
  • --nodes specifies a comma-delimited list of nodes to collect logs
  • --objectStoreBucketURI specifies OSS PAR URL to upload log collection

dbaascli grid configureTCPS

To configure TCPS for the existing cluster, use the dbaascli grid configureTCPS command.

Prerequisite

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli grid configureTCPS
[--pkcs12WalletPath]
[--caCertChain]
[--precheckOnly]
[--serverCert]
[--privateKey]
[--certType]
[--privateKeyPasswordProtected]
Where:
  • --pkcs12WalletPath specifies the path of the certificate, which is in pkcs12 wallet format
  • --caCertChain concatenated list of certs, containing intermediate CA's and root CA certs
  • --precheckOnly specifies yes to run only the prechecks for this operation. Valid values: yes or no.
  • --serverCert specifies the path of PEM certificate to use or rotate for TCPS configuration.
  • --privateKey specifies the path of the private key file of the certificate.
  • --certType type of the cert to be added to the Grid Infrastructure wallet. Accepted values are: SELF_SIGNED_CERT, CA_SIGNED_CERT, or PKCS12_CERT. Default: SELF_SIGNED_CERT
  • --privateKeyPasswordProtected specifies if the private key is password protected or not. Valid values: true or false. Default: true.

Example 21-18 dbaascli grid configureTCPS

To configure grid using self-signed certificate:
dbaascli grid configureTCPS
To configure grid using CA-signed certificate:
dbaascli grid configureTCPS --cert_type CA_SIGNED_CERT --server_cert /tmp/certs/server_cert.pem --ca_cert_chain /tmp/certs/ca.pem --private_key /tmp/certs/encrypted_private.key --private_key_password_protected false

dbaascli grid patch

To patch Oracle Grid Infrastructure to the specified minor version, use the dbaascli grid patch command.

Prerequisites

Run the command as the root user.

See, Connecting to a Virtual Machine with SSH.

Syntax

grid patch --targetVersion
[--resume]
[--containerURL]
[--nodeList]
[--rollback]
[--executePrereqs]

Where:

  • grid patch patches the Grid Infrastructure to the specified minor version
  • --targetVersion specifies the target version to be patched to
  • --resume resumes the previous run
  • --containerURL specifies custom URL for fetching Grid Infrastructure image
  • --nodeList specifies a comma-delimited list of nodes if patching has to be performed on a subset of nodes
  • --rollback rolls back patched Oracle home
  • --executePrereqs runs prereqs

dbaascli grid rotateTCPSCert

To rotate TCPS certificates, use the dbaascli grid rotateTCPSCert command.

Prerequisite

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli grid rotateTCPSCert
[--pkcs12WalletPath]
[--caCertChain]
[--precheckOnly]
[--serverCert]
[--privateKey]
[--certType]
[--privateKeyPasswordProtected]
Where:
  • --pkcs12WalletPath specifies the path of the certificate, which is in pkcs12 wallet format
  • --caCertChain concatenated list of certs, containing intermediate CA's and root CA certs
  • --precheckOnly specifies yes to run only the prechecks for this operation. Valid values: yes or no.
  • --serverCert specifies the path of PEM certificate to use or rotate for TCPS configuration.
  • --privateKey specifies the path of the private key file of the certificate.
  • --certType type of the cert to be added to the Grid Infrastructure wallet. Accepted values are: SELF_SIGNED_CERT, CA_SIGNED_CERT, or PKCS12_CERT. Default: SELF_SIGNED_CERT
  • --privateKeyPasswordProtected specifies if the private key is password protected or not. Valid values: true or false. Default: true.

Example 21-19 dbaascli grid rotateTCPSCert

To rotate cert using self-signed certificate (default option):
dbaascli grid rotateTCPSCert
To rotate cert using CA-signed certificate:
dbaascli grid rotateTCPSCert --cert_type CA_SIGNED_CERT --server_cert /tmp/certs/server_cert.pem --ca_cert_chain /tmp/certs/ca.pem --private_key /tmp/certs/encrypted_private.key --privateKeyPasswordProtected true

dbaascli grid upgrade

To upgrade Oracle Grid Infrastrucure from one major version to another, use the dbaascli grid upgrade command.

Prerequisite

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli grid upgrade --version
[--resume]
[--executePrereqs | --ignorePrereqFailure | --skipPrereqs]
[--containerURL]
[--softwareOnly]
[--targetHome]
[--revert]
Where:
  • --version specifies the target version
  • --resume resumes the previous run
  • --executePrereqs runs prereqs for Grid Infrastrucure upgrade
  • --ignorePrereqFailure ignores prereq failures
  • --skipPrereqs skips prereqs
  • --containerUrl specifies the custom URL for fetching Grid Infrastrucure image
  • --softwareOnly installs only the Grid Infrastructure software
  • --targetHome specifies the path of existing target Grid home
  • --revert reverts failed run

Example 21-20 dbaascli grid upgrade

daascli grid upgrade --version 19.11.0.0.0 --executePrereqs
DBAAS CLI version MAIN
Executing command grid upgrade --version 19.11.0.0.0 --executePrereqs

dbaascli job getStatus

To view the status of a specified job, use the dbaascli job getStatus command.

Prerequisite

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli job getStatus --jobID
Where:
  • --jodID specifies the job ID

Example 21-21 dbaascli job getStatus

dbaascli job getStatus --jobID 13c82031-f202-41b7-9aef-f4a71df0f551
DBAAS CLI version MAIN
Executing command job getStatus --jobID 13c82031-f202-41b7-9aef-f4a71df0f551
{
  "jobId" : "13c82031-f202-41b7-9aef-f4a71df0f551",
  "status" : "Success",
  "message" : "database create job: Success",
  "createTimestamp" : 1628095442431,
  "updatedTime" : 1628095633660,
  "description" : "Service job report for operation database create",
  "appMessages" : {
    "schema" : [ ],
    "errorAction" : "SUCCEED_AND_SHOW"
  },
  "resourceList" : [ ],
  "pct_complete" : "100"
}

dbaascli pdb bounce

To bounce a pluggable database (PDB), use the dbaascli pdb bounce command.

Prerequisite

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli pdb bounce --dbname --pdbName | --pdbUID
[–openMode]
Where:
  • --dbname specifies the name of the container database that hosts the PDB
  • --pdbName specifies the name of the PDB
  • --pdbUID specifies the identifier of the PDB
  • --openMode specifies the target OPEN MODE of PDB

Example 21-22 dbaascli pdb bounce

dbaascli pdb bounce --dbname cdb_name --pdbName pdb name associated with the CDB
dbaascli pdb bounce --dbname cdb_name --pdbUID con_uid of that pdb
Optional:
  • --openMode READ_WRITE
  • --openMode READ_ONLY

dbaascli pdb close

To close a pluggable database (PDB), use the dbaascli pdb close command.

Prerequisite

Run the command as the oracle user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli pdb close --dbname --pdbName | --pdbUID
Where:
  • --dbname specifies the name of the container database that hosts the PDB.
  • --pdbname specifies the name of the PDB that you want to close.
  • --pdbUID specifies the identifier of the PDB

Upon successful completion of running this command, the PDB is closed on all of the container database instances.

Example 21-23 dbaascli pdb close

dbaascli pdb close --dbname cdb name --pdbName pdb name associated with the CDB
dbaascli pdb close --dbname cdb name --pdbUID con_uid of that pdb

dbaascli pdb connectString

To display Oracle Net connect string information for a pluggable database (PDB) run the dbaascli pdb connectString command.

Prerequisite

Run the command as the oracle user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli pdb connectString --dbname --pdbName | --pdbUID
Where:
  • --dbname specifies the name of the container database that hosts the PDB
  • --pdbname specifies the name of the PDB for which you want to display connect string information
  • --pdbUID specifies the identifier of the PDB

Example 21-24 dbaascli pdb connectString

dbaascli pdb connectString --dbname dbname --pdbName pdbName

dbaascli pdb create

To create a new pluggable database (PDB), use the dbaascli pdb create command.

Prerequisite

Run the command as the oracle user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli pdb create --dbName --pdbName
[--resume]
[--maxSize]
[--pdbAdminUserName]
[--maxCPU]
[--waitForCompletion]
[--primaryDBWalletTar]
[--executePrereqs]
[--skipPrereqs]
Where:
  • --dbName specifies the name of the container database that hosts the new PDB
  • --pdbName specifies the name of the new PDB that you want to create
  • --resume resumes the previous run
  • --maxSize optionally specifies the maximum total size of data files and temporary files for tablespaces belonging to the PDB. Setting this option is effectively the same as setting the MAXSIZE PDB storage clause in the CREATE PLUGGABLE DATABASE SQL command. You can impose a limit by specifying an integer followed by a size unit (K, M, G, or T), or you can specify UNLIMITED to explicitly enforce no limit
  • --pdbAdminUserName specifies the PDB admin user name
  • --maxCPU optionally specifies the maximum number of CPUs that are available to the PDB. Setting this option is effectively the same as setting the CPU_COUNT parameter in the PDB
  • --waitForCompletion specifies false to run the operation in the background. Valid values: true or false
  • --primaryDBWalletTar specifies the primary database wallet tar file. This is required only for standby database PDB operations
  • --executePrereqs specifies yes to run only the prereqs for this operation. Valid values: yes or no
  • --skipPrereqs specifies yes to skip prereqs for this operation. Valid values: yes or no

During the PDB creation process, you are prompted to specify the administration password for the new PDB.

Example 21-25 dbaascli pdb create

To create a pdb from seed in a standard db on non-data guard env
dbaascli pdb create --dbName db721 --pdbName new_pdb1 --maxsize 5G --maxcpu 2
To create pdb in data guard env
dbaascli pdb create --dbName db721 --pdbName new_pdb1
dbaascli pdb create --dbName db721 --pdbName new_pdb1 --primaryDBWalletTar /tmp/send_db721.tar

dbaascli pdb delete

To delete a pluggable database (PDB) run the dbaascli pdb delete command.

Prerequisite

Run the command as the oracle user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli pdb delete --dbName --pdbName | --pdbUID
[--executePrereqs value | --skipPrereqs value]
[--waitForCompletion]
Where:
  • --dbName specifies the name of the container database that hosts the PDB
  • --pdbname specifies the name of the PDB that you want to delete
  • --pdbUID specifies the name of the PDB that you want to delete
  • --executePrereqs specifies yes to run only the prereqs for this operation. Valid values: yes or no
  • --skipPrereqs specifies yes to skip prerequisites for this operation. Valid values: yes or no
  • --waitForCompletion specifies false to run the operation in the background. Valid values: true or false

dbaascli pdb getDetails

To view details of a pluggable database (PDB), use the dbaascli pdb getDetails command.

Prerequisite

Run the command as the oracle user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli pdb getDetails --dbname --pdbName | --pdbUID
Where:
  • --dbname specifies the name of the container database that hosts the PDB
  • --pdbname specifies the name of the PDB that you want to delete
  • --pdbUID specifies the identifier of the PDB

Example 21-26 dbaascli pdb getDetails

dbaascli pdb getDetails--dbname cdb name --pdbName pdb name associated with the CDB
dbaascli pdb getDetails--dbname cdb name --pdbUID con_uid of that pdb

dbaascli pdb list

To view the list of pluggable databases (PDB) in a container database, use the dbaascli pdb list command.

Prerequisite

Run the command as the oracle user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli pdb list --dbname
Where:
  • --dbname specifies the name of the container database that hosts the PDB

Example 21-27 dbaascli pdb list

dbaascli pdb list --dbname cdb name

dbaascli pdb localClone

To create a new pluggable database (PDB) as a clone of an existing PDB in the same container database (CDB), use the dbaascli pdb localClone command.

Prerequisite

Run the command as the oracle user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli pdb localClone --dbName --pdbName
[--resume]
[--maxCPU]
[--waitForCompletion]
[--primaryDBWalletTar]
[--maxSize]
[--targetPDBName]
[--executePrereqs]
[--skipPrereqs]
[--powerLimit]
Where:
  • --dbName specifies the name of the database
  • --pdbName specifies the name of the new PDB that you want to clone
  • --resume resumes the previous run
  • --maxCPU specifies the maximum number of CPUs to be allocated for the PDB
  • --waitForCompletion specifies false to run the operation in the background. Valid values: true or false
  • --primaryDBWalletTar specifies the primary database wallet tar file. This is required only for standby database PDB operations
  • --maxSize specifies the maximum storage size in GB for the new PDB
  • --targetPDBName specifies the name for the target PDB (new cloned PDB)
  • --executePrereqs specifies yes to run only the prereqs for this operation. Valid values: yes or no
  • --skipPrereqs skips prereqs for this operation. Valid values: yes or no
  • --powerLimit specifies the degree of parallelism to be used for the clone operation. Valid value is between 1 and 128

The newly cloned PDB inherits administration passwords from the source PDB.

Example 21-28 dbaascli pdb localClone

dbaascli pdb localClone --dbName db35 --pdbName PDB35 --targetPDBName local_clone1 --maxCPU 2 --maxSize 15

dbaascli pdb open

To open a pluggable database (PDB), use the dbaascli pdb open command.

Prerequisite

Run the command as the oracle user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli pdb open --dbname --pdbName | --pdbUID
[--openMode]
Where:
  • --dbname specifies the name of the container database that hosts the PDB.
  • --pdbName specifies the name of the PDB that you want to open
  • --pdbUID specifies the identifier of the PDB
  • --openMode specifies the target OPEN MODE of PDB

Upon successful completion, the PDB is opened on all of the container database instances.

Example 21-29 dbaascli pdb open

dbaascli pdb open --dbname cdb name --pdbName pdb name associated with the CDB
dbaascli pdb open --dbname cdb name --pdbUID con_uid of that pdb

Optional: --openMode READ_WRITE/READ_ONLY

dbaascli pdb remoteClone

To create a new pluggable database (PDB) as a clone of an existing PDB in another container database (CDB), use the dbaascli pdb remoteClone command.

Prerequisite

Run the command as the oracle user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli pdb remoteClone --sourceDBConnectionString --dbname --pdbName
[--resume]
[--maxSize]
[--waitForCompletion]
[--primaryDBWalletTar]
[--targetPDBName]
[--maxCPU]
[--sourcePDBExportedTDEKeyFile]
[--walletLocation]
[--executePrereqs]
[--skipPrereqs]
Where:
  • --sourceDBConnectionString specifies the source database connection string in the format scan_name:scan_port/database_service_name
  • --dbname specifies the name (DB_NAME) of the CDB that hosts the newly cloned PDB
  • --pdbName specifies the name of the source PDB that you want to clone
  • --resume resumes the previous run
  • --maxSize specifies the maximum storage size in GB for the new PDB
  • --waitForCompletion specifies false to run the operation in the background. Valid values: true or false
  • --powerLimit specifies the degree of parallelism to be used for the clone operation. Valid value is between 1 and 128
  • --primaryDBWalletTar specifies the primary database wallet tar file. This is required only for the standby database PDB operations
  • --targetPDBName specifies the name for the target PDB (new cloned PDB)
  • --maxCPU specifies the maximum number of CPUs to be allocated for the PDB
  • --sourcePDBExportedTDEKeyFile specifies the source PDB exported key file. This variable is applicable to only 12.1 database
  • --walletLocation specifies the location of the wallet
  • --executePrereqs specifies yes to run only the prereqs for this operation. Valid values: yes or no
  • --skipPrereqs specifies yes to skip prereqs for this operation. Valid values: yes or no

When promoted, you must supply the SYS user password for the source PDB. The newly cloned PDB inherits administration passwords from the source PDB. The cloned PDB is named using the following format: dbname_sourcepdbname.This command is supported only for databases that are not in a Data Guard configuration and use Oracle Database version 12.2.0.1, or later.

Example 21-30 dbaascli pdb remoteClone

dbaascli pdb remoteClone --sourceDBConnectionString test-can.dbaastoolslrgsu.dbaastoolslrgvc.oraclevcn.com:1521 --pdbName source_pdb1 --dbName db9944 --targetPDBName new_pdb1 --maxsize 5 --maxcpu 2
dbaascli pdb remoteClone --sourceDBConnectionString orcla.dbaastoolslrgsu.dbaastoolslrgvc.oraclevcn.com --pdbName source_pdb1 --dbName db9944 --targetPDBName new_pdb1 --maxsize 5 --maxcpu 2

dbaascli tde addSecondaryHsmKey

To add a secondary HSM (KMS) key to the existing HSM (KMS) configuration, use the dbaascli tde addSecondaryHsmKey command.

Prerequisite

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli tde addSecondaryHsmKey --secondaryKmsKeyOCID
[--dbname]
[--precheckOnly]
Where:
  • --secondaryKmsKeyOCID specifies the secondary KMS key to add to the existing HSM (KMS) configuration
  • --dbname specifies the name of the database
  • --precheckOnly specifies yes to run only the prechecks for this operation. Valid values: yes or no

Example 21-31 dbaascli tde addSecondaryHsmKey

dbaascli tde addSecondaryHsmKey --dbname dbname --secondaryKmsKeyOCID ocid1.key.oc1.eu-frankfurt-1.bjqnwclvaafak.abtheljsgfxa2xe5prvlzdxtygoiqpm2pu2afgta54krxwllk5uxainvvxza
dbaascli tde addSecondaryHsmKey --dbname dbname --secondaryKmsKeyOCID ocid1.key.oc1.eu-frankfurt-1.bjqnwclvaafak.abtheljsgfxa2xe5prvlzdxtygoiqpm2pu2afgta54krxwllk5uxainvvxza --precheckOnly yes

dbaascli tde enableWalletRoot

To enable wallet_root spfile parameter for the existing database, use the dbaascli tde enableWalletRoot command.

Prerequisite

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli tde enableWalletRoot
[--dbRestart]
[--dbname]
[--precheckOnly]
Where:
  • --dbrestart specifies the database restart option. Valid values are: rolling or full. Default value: rolling

    If you do not pass the dbrestart argument, then the database restarts in a rolling manner.

  • --dbname specifies the name of the Oracle Database.
  • --precheckOnly runs only the precheck for this operation. Valid values are: yes or no

Example 21-32 dbaascli tde enableWalletRoot

dbaascli tde enableWalletRoot --dbname db name --dbrestart rolling|full
dbaascli tde enableWalletRoot --dbname orcl
dbaascli tde enableWalletRoot --dbname orcl--dbrestart full

dbaascli tde encryptTablespacesInPDB

To encrypt all the tablespaces in the specified PDB, use the dbaascli tde encryptTablespacesInPDB command.

Prerequisite

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli tde encryptTablespacesInPDB --pdbName
[--dbname]
[--precheckOnly]
[--useSysdbaCredential]
Where:
  • --pdbName specifies the name of the PDB to encrypt all the tablespaces.
  • --dbname specifies the name of the Oracle Database.
  • --precheckOnly runs only the precheck for this operation. Valid values: yes or no
  • --useSysdbaCredential uses SYSDBA credentials for this operation if passed value is true. Valid values: true or false

Example 21-33 dbaascli tde encryptTablespacesInPDB

dbaascli tde encryptTablespacesInPDB --dbname dbname --pdbName pdb
dbaascli tde encryptTablespacesInPDB --dbname dbname --pdbName pdb --precheckOnly yes
dbaascli tde encryptTablespacesInPDB --dbname dbname --pdbName pdb --useSysdbaCredential true

dbaascli tde fileToHsm

To convert FILE based TDE to HSM (KMS/OKV) based TDE, use the dbaascli tde fileToHsm command.

Prerequisite

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli tde fileToHsm --kmsKeyOCID
[--resume]
[--dbname]
[--skipPatchCheck]
[--precheckOnly]
[--revert]
[--primarySuc]
Where:
  • --kmsKeyOCID specifies the KMS key OCID to use for TDE. This is applicable only if KMS is selected for TDE
  • --resume resumes the previous run
  • --dbname specifies the name of the database
  • --skipPatchCheck skips validation check for required patches if the value passed for this argument is true. Valid values: true or false
  • --precheckOnly specifies yes to run only the prechecks for this operation. Valid values: yes or no
  • --revert rolls back the previous run
  • --primarySuc specify this property in the standby database of the Data Guard environment once the command is successfully run on the primary database

Example 21-34 dbaascli tde fileToHsm --kmsKeyOCID

dbaascli tde fileToHSM --dbname dbname --kmsKeyOCID ocid1.key.oc1.eu-frankfurt-.bjqnwclvaafak.abtheljsgfxa2xe5prvlzdxtygoiqpm2pu2afgta54krxwllk5uxainvvxza
dbaascli tde fileToHSM --dbname dbname --kmsKeyOCID ocid1.key.oc1.eu-frankfurt-.bjqnwclvaafak.abtheljsgfxa2xe5prvlzdxtygoiqpm2pu2afgta54krxwllk5uxainvvxza --precheckOnly yes
dbaascli tde fileToHSM --dbname dbname --kmsKeyOCID ocid1.key.oc1.eu-frankfurt-.bjqnwclvaafak.abtheljsgfxa2xe5prvlzdxtygoiqpm2pu2afgta54krxwllk5uxainvvxza --resume

dbaascli tde getHsmKeys

To get TDE active key details, use the dbaascli tde getHsmKeys command.

Prerequisite

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli tde getHsmKeys
[--dbname]
[--infoFile]
Where:
  • --dbname specifies the name of the database
  • --infoFile specifies the file path where the list of OCIDs will be saved. The output is in JSON format

Example 21-35 dbaascli tde getHsmKeys

dbaascli tde getHsmkeys --dbname dbname
dbaascli tde getHsmkeys --dbname dbname --infoFile infoFilePath

dbaascli tde getMkidForKeyVersionOCID

To get Master Key ID associated with the KMS key version OCID, use the dbaascli tde getMkidForKeyVersionOCID command.

Prerequisite

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli tde getMkidForKeyVersionOCID --kmsKeyVersionOCID
[--dbname]
Where:
  • --kmsKeyVersionOCID specifies the KMS key version OCID to set
  • --dbname specifies the name of the database

Example 21-36 dbaascli tde getMkidForKeyVersionOCID

dbaascli tde getMkidForKeyVersionOCID --dbname dbname --kmsKeyVersionOCID ocid1.keyversion.oc1.eu-frankfurt-1.bjqnwclvaafak.bc4hmd3olgaaa.abtheljsyxtgn4vzi2bbpcej6a7abcwvylkd2lx56lu2s6iwnxwgigu23nha

dbaascli tde getPrimaryHsmKey

To get primary HSM (KMS) key from the existing HSM (KMS) configuration, use the dbaascli tde getPrimaryHsmKey command.

Prerequisite

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli tde getPrimaryHsmKey
[--dbname]
Where:
  • --dbname specifies the name of the database

Example 21-37 dbaascli tde getPrimaryHsmKey

dbaascli tde getPrimaryHsmKey --dbname dbname

dbaascli tde hsmToFile

To convert HSM (KMS/OKV) based TDE to FILE based TDE, use the dbaascli tde hsmToFile command.

Prerequisite

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli tde fileToHsm --kmsKeyOCID
[--resume]
[--dbname]
[--skipPatchCheck]
[--precheckOnly]
[--primaryDBWalletTar]
[--revert]
[--primarySuc]
Where:
  • --kmsKeyOCID specifies the KMS key OCID to use for TDE. This is applicable only if KMS is selected for TDE
  • --resume resumes the previous run
  • --dbname specifies the name of the database
  • --skipPatchCheck skips validation check for required patches if the value passed for this argument is true. Valid values: true or false
  • --precheckOnly specifies yes to run only the prechecks for this operation. Valid values: yes or no
  • --primaryDBWalletTar specifies the primary database wallet tar file. This is required only for the standby database hsm_to_file conversion
  • --revert rolls back the previous run
  • --primarySuc specify this property in the standby database of the Data Guard environment once the command is successfully run on the primary database

Example 21-38 dbaascli tde hsmToFile

dbaascli tde hsmToFile --dbname dbname
dbaascli tde hsmToFile --dbname dbname --precheckOnly yes
dbaascli tde hsmToFile --dbname dbname --resume

dbaascli tde listKeys

To list TDE master keys, use the dbaascli tde listKeys command.

Prerequisite

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli tde listKeys
[--file]
[--dbname]
Where:
  • --file specifies the file path to save the results
  • --dbname specifies the name of the database

Example 21-39 dbaascli tde listKeys

dbaascli tde listKeys --dbname dbname
dbaascli tde listKeys --dbname dbname --file infoFilePath

dbaascli tde removeSecondaryHsmKey

To remove secondary HSM (KMS) key from the existing HSM (KMS) configuration, use the dbaascli tde removeSecondaryHsmKey command.

Prerequisite

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli tde removeSecondaryHsmKey
[--force]
[--secondaryKmsKeyOCID]
[--dbname]
[--precheckOnly]
Where:
  • --force if not specified, you will be prompted while deleting all of the existing HSM (KMS) keys
  • --secondaryKmsKeyOCID specifies the secondary KMS key to add to the existing HSM (KMS) configuration
  • --dbname specifies the name of the database
  • --precheckOnly specifies yes to run only the prechecks for this operation. Valid values: yes or no

Example 21-40 dbaascli tde removeSecondaryHsmKey

dbaascli tde removeSecondaryHsmKey --dbname dbname
dbaascli tde removeSecondaryHsmKey --dbname dbname --secondaryKmsKeyOCID ocid1.key.oc1.eu-frankfurt-1.bjqnwclvaafak.abtheljsgfxa2xe5prvlzdxtygoiqpm2pu2afgta54krxwllk5uxainvvxza
dbaascli tde removeSecondaryHsmKey --dbname dbname --secondaryKmsKeyOCID ocid1.key.oc1.eu-frankfurt-1.bjqnwclvaafak.abtheljsgfxa2xe5prvlzdxtygoiqpm2pu2afgta54krxwllk5uxainvvxza --precheckOnly yes

dbaascli tde setKeyVersion

To set the version of the primary key to be used in DB/CDB or PDB., use the dbaascli tde setKeyVersion command.

Prerequisite

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli tde setKeyVersion --kmsKeyVersionOCID
[--masterKeyID]
[--dbname]
[--standbySuc]
[--precheckOnly]
[--pdbName]
Where:
  • --kmsKeyVersionOCID specifies the KMS key version OCID to set.
  • --masterKeyID specifies the master key ID of the given key version OCID. This is applicable to the Data Guard environment.
  • --dbname specifies the name of the database.
  • --standbySuc specify this property in the primary database of the Data Guard environment once the command is successfully run on the standby database.
  • --precheckOnly specifies yes to run only the prechecks for this operation. Valid values: yes or no

Example 21-41 dbaascli tde setKeyVersion

dbaascli tde setKeyVersion --dbname dbname --kmsKeyVersionOCID ocid1.keyversion.oc1.eu-frankfurt-1.bjqnwclvaafak.bc4hmd3olgaaa.abtheljsyxtgn4vzi2bbpcej6a7abcwvylkd2lx56lu2s6iwnxwgigu23nha
dbaascli tde setKeyVersion --dbname dbname --kmsKeyVersionOCID ocid1.keyversion.oc1.eu-frankfurt-1.bjqnwclvaafak.bc4hmd3olgaaa.abtheljsyxtgn4vzi2bbpcej6a7abcwvylkd2lx56lu2s6iwnxwgigu23nha --precheckOnly yes
dbaascli tde setKeyVersion --dbname dbname --pdbName pdb --kmsKeyVersionOCID ocid1.keyversion.oc1.eu-frankfurt-1.bjqnwclvaafak.bc4hmd3olgaaa.abtheljsyxtgn4vzi2bbpcej6a7abcwvylkd2lx56lu2s6iwnxwgigu23nha

dbaascli tde setPrimaryHsmKey

To change the primary HSM (KMS) key for the existing HSM (KMS) configuration, use the dbaascli tde setPrimaryHsmKey command.

Prerequisite

Run the command as the root user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli tde setPrimaryHsmKey --primaryKmsKeyOCID
[--dbname]
[--standbySuc]
[--precheckOnly]
Where:
  • --primaryKmsKeyOCID specifies the primary KMS key to set
  • --dbname specifies the name of the database
  • --standbySuc specify this property in the primary database of the Data Guard environment once the command is successfully run on the standby database
  • --precheckOnly specifies yes to run only the prechecks for this operation. Valid values: yes or no

Example 21-42 dbaascli tde setPrimaryHsmKey

dbaascli tde setPrimaryHsmKey --dbname dbname --primaryKmsKeyOCID ocid1.key.oc1.eu-frankfurt-1.bjqnwclvaafak.abtheljsgfxa2xe5prvlzdxtygoiqpm2pu2afgta54krxwllk5uxainvvxza
dbaascli tde setPrimaryHsmKey --dbname dbname --primaryKmsKeyOCID ocid1.key.oc1.eu-frankfurt-1.bjqnwclvaafak.abtheljsgfxa2xe5prvlzdxtygoiqpm2pu2afgta54krxwllk5uxainvvxza --precheckOnly yes

dbaascli tde status

To display information about the keystore for the specified database, use the dbaascli tde status command.

Prerequisite

Run the command as the oracle user.

To use the utility, you must connect to an Exadata Cloud@Customer virtual machine.

See, Connecting to a Virtual Machine with SSH.

Syntax

dbaascli tde status --dbname dbname
Where:
  • --dbname specifies the name of the database that you want to check.

Output from the command includes the type of keystore, and the status of the keystore.

Example 21-43 dbaascli tde status

dbaascli tde status --dbname dbname