スナップショット・プロファイルを使用してプラガブル・データベースをプロビジョニングする手順

スナップショット・プロファイルを使用してPDBをプロビジョニングするには、次のステップに従います。

  1. OMSホストで次のコマンドを実行して、EM CLIにログインします。
    $<OMS_HOME>/bin/emcli login -username=<name_of_user> -password=<password>
    
  2. 次のコマンドを実行して、動詞create_pluggable_databaseのヘルプ・ファイルを表示します。
    $<OMS_HOME>/bin/emcli help create_pluggable_database
    
  3. 動詞create_pluggable_databaseを実行して、ソースPDBのスナップ・クローンとスナップショット・プロファイルを作成します(この際、-sourceTypeパラメータをCLONEとして指定し、-sourcePDBName、-sourceCDBCreds、-useSnapClone、-sourceCDBHostCreds、-mountPointPrefix、-writableSpace、-privHostCreds、-saveProfile、-profileNameおよび-profileLocationの各パラメータを指定します)。
    $<OMS_HOME>/bin/emcli create_pluggable_database
    -cdbTargetName=<Specify the CDB target name for creating new PDB>
    -cdbTargetType=<Specify the CDB target type - oracle_database, rac_database>
    -cdbHostCreds=<Specify the host credentials on which the CDB target is located>
    -pdbName=<Specify a name for the new PDB>
    -sourceType=CLONE
    -sourcePDBName=<Specify the name of the existing PDB that you want to clone>
    -sourceCDBCreds=<Specify the credentials of the CDB within which the source PDB is present>
    -useSnapClone
    -sourceCDBHostCreds=<Specify the host credentials for the source CDB.>
    -mountPointPrefix=<Specify the mount point prefix for the cloned volumes.>
    -writableSpace=<Specify the writable space, in GB, for the cloned volumes.>
    -privHostCreds=<Specify the privileged host credentials required to mount the cloned volumes at the specified locations.>
    -saveProfile
    -profileName=<The name of the profile that you want to create>
    -profileLocation=<The location in software library where you want to create the profile>
    [-cdbTargetCreds=<Specify the credentials of container database on which the new PDB will be created.>]
    [-numOfPdbs=<Specify the number of PDBs to be created>]
    [-pdbAdminCreds=<Specify the PDB credentials having the admin role>]
    [-useOMF=<Specifies that the datafiles can be stored in OMF location>]
    [-sameAsSource=<Specifies that the datafiles of new PDB can be stored in the same location as that of source CDB>]
    [-newPDBFileLocation=<Specify the storage location for datafiles of the created PDB.>]
    [-noUserTablespace=<Specifies that the new DEFAULT PDB will not be created with USERS tablespace.>]
    
    

    このコマンドは、スナップ・クローン機能を使用してソースPDBをクローニングし、ソースPDBのスナップショット・プロファイルを作成します。スナップショット・プロファイルは、ソフトウェア・ライブラリの指定した場所に格納されます。

  4. -nameパラメータおよび-show_entity_rev_idパラメータを指定して動詞list_swlib_entitiesを実行し、作成したスナップショット・プロファイルのUniform Resource Name (URN)を取得します。
    $<OMS_HOME>/bin/emcli list_swlib_entities
                          -name="<The name of the snapshot profile>"
                          -show_entity_rev_id 
    
    
  5. 動詞create_pluggable_databaseを実行し、作成したスナップショット・プロファイルを使用してPDBをプロビジョニングします。この際、-sourceTypeパラメータをPROFILEとして指定し、-profileURNパラメータを指定します。
    $<OMS_HOME>/bin/emcli create_pluggable_database
    -cdbTargetName=<Specify the CDB target name for creating new PDB>
    -cdbTargetType=<Specify the CDB target type - oracle_database, rac_database>
    -cdbHostCreds=<Specify the host credentials on which the CDB target is located>
    -pdbName=<Specify a name for the new PDB>
    -sourceType=PROFILE
    -profileURN=<URN of the snapshot profile that you want to use to provision PDBs>
    [-cdbTargetCreds=<Specify the credentials of container database on which the new PDB will be created.>]
    [-numOfPdbs=<Specify the number of PDBs to be created>]
    [-pdbAdminCreds=<Name of pdb credentials with admin role>]
    [-useOMF=<Specifies that the datafiles can be stored in OMF location>]
    [-sameAsSource=<Specifies that the datafiles of new PDB can be stored in the same location as that of source CDB>]
    [-newPDBFileLocation=<Specify the storage location for datafiles of the created PDB.>]
    [-noUserTablespace=<Specifies that the new DEFAULT PDB will not be created with USERS tablespace.>]