Provisioning Oracle Database Software

This use case describes how to provision an Oracle Database Software using the EM CLI commands available in Cloud Control. The first step is to filter out the database procedures running in your enterprise, from the list, select the Single Instance Database procedure and its corresponding GUID. For the SI DB procedure, a new properties file is created from scratch. Initially, the name-value pair in the template will be empty, you must edit the attributes in the properties file to update the values. Following which the procedure is submitted with the updated properties file as the input, and tracked to completion.

Note:

The following verb clones only Oracle Database 9i Release 2: emcli clone_database_home -swlib true.

Here is the step-by-step procedure with the outputs:

  1. To retrieve the GUID of the Deployment Procedure, run the following command:
    ./emcli get_procedures | grep DB_       
    
    For Example:
    ./emcli get_procedures | grep DB
    B3F.CE84B1ED96791E040578CD7810EC5, DBPROV, Prov_112_db_using_SH_1ocked_acc_without_env_shift_username1, Prov_112_db_using_SH_1ocked_acc_without_env_shift_ssubbura11, 1.0, USERNAME1, SIHA_SIDB_PROC
    B35E10B1F42AB4EEE040578CD78179DC, DB_PROV_UPGRADE, DbProvUpgradeDP, Upgrade Oracle Database, 1.0, ORACLE
    B35E10B1F427B4EEE040578CD78179DC, DBPROV, SIHA_SIDB_PROC, Provision Oracle Database, 1.0, ORACLE
    
    Select the GUID corresponding to the SIHA_SIDB_PROC , which is B35E10B1F427B4EEE040578CD78179DC
    
  2. Create the Properties File template using the following command:
    ./emcli describe_procedure_input -procedure=B35E10B1F427B4EEE040578CD78179DC > sihasidb.properties
     
  3. Use an editor to view the contents of the generated properties file sihasidb.properties file, and enter the required values.

    For example, here is a sample properties file used with the values updated in them:

    # The Procedure Configuration with name emcli_11202 has input and arguments as follows:
    # Input properties are:
    DB_COMPONENT=11<ADMIN_NAME>/Oracle Database Installation Media
    DB_HOST_NORMAL_CREDNAMES=AIME_USER1:<USERNAME>
    DB_HOST_ROOT_CREDNAMES=AIME_ROOT:<USERNAME>
    DB_ORACLE_BASE_LOC=/scratch/db11202
    DB_ORACLE_HOME_LOC=/scratch/db11202/app/product/11.2.0/db
    DB_PRODUCT_VERSION=11.2.0.2.0
    DEPLOY_MODE=DEPLOY_DB
    OINSTALL_GROUP=svrtech
    OSDBA_GROUP=dba
    OSOPER_GROUP=oper
    PAUSE_AFTER_PREREQ=false
    RAC_HOME_SHARED=false
    SOURCE_TYPE=SOFTWARE_LIBRARY
    TARGET_HOST_LIST=host.us.example.com
    WORK_DIR_LOC=/tmp
    
  4. Submit the procedure using the following command:
    ./emcli submit_procedure -input_file=data:sihasidb.properties
    -instance="emcli_db1" -procedure=B35E10B1F427B4EEE040578CD78179DC
    Verifying parameters ...
    Schedule not specified, defaults to immediate
    A8F7700333BAE9FAE040E40A45D866F1
    Deployment procedure submitted successfully