2. Create Key store on CDB database and generate encryption key for CDB
1 2 3
ADMINISTER KEY MANAGEMENT CREATE KEYSTORE '/cdbrdbms/etc/MTc12c1' IDENTIFIED BY "welcome1"; ADMINISTER KEY MANAGEMENT SET KEYSTORE OPEN IDENTIFIED BY "welcome1"; ADMINISTER KEY MANAGEMENT SET KEY IDENTIFIED BY "welcome1" WITH BACKUP;
3. Verify the wallet has been opened in CDB database
1 2 3 4 5 6 7 8 9 10 11 12 13 14
select * from v$encryption_wallet;
WRL_TYPE -------------------- WRL_PARAMETER -------------------------------------------------------------------------------- STATUS WALLET_TYPE WALLET_OR FULLY_BAC ------------------------------ -------------------- --------- --------- CON_ID ---------- FILE /cdbrdbms/etc/MTc12c1/ OPEN PASSWORD SINGLE NO 0
4. Open the respective PDB and set the PDB as current database
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
SQL> show pdbs
CON_ID CON_NAME OPEN MODE RESTRICTED ---------- ------------------------------ ---------- ---------- 2 PDB$SEED READ ONLY NO 3 MTC12P1 MOUNTED 4 MTC12P2 MOUNTED
SQL> alter pluggable database MTC12P2 open;
Pluggable database altered.
SQL> show pdbs
CON_ID CON_NAME OPEN MODE RESTRICTED ---------- ------------------------------ ---------- ---------- 2 PDB$SEED READ ONLY NO 3 MTC12P1 MOUNTED 4 MTC12P2 READ WRITE NO
1 2 3 4 5 6 7 8 9
SQL> alter session set container=MTC12P2;
Session altered.
SQL> show con_name
CON_NAME ------------------------------ MTC12P2
5. Open the keystore in that PDB and generate encryption key for the PDB