In this post, we are going to cover creating GoldenGate Global User in Multitenant Architecture. Oracle Database 12c introduced the Multitenant Architecture for Oracle databases. This allows for multiple pluggable databases to exist within the same container database.
If you want to install Goldengate 12c then go through our post here Oracle GoldenGate 12c Download & Installation and for troubleshooting go through Oracle GoldenGate 12c: Troubleshooting using LogDump Utility
1. Create Global User & Grant DBA Role
We need to create the Global user in Multitenant architecture for Goldengate replication. In order to segregate the tablespace for golden gate user, it is advisable to create a separate tablespace. The tablespace will be required in both containers as well as in all pluggable databases.
Note: gg_tblsp needs to be created in pluggable as well as container databases.
a) In container database:
SQL> create tablespace ggs_tblsp datafile ‘/u01/app/oracle/oradata/OGGDB1/datafile/gg_cdb.dbf’ size 2G;
b) In Pluggable database:
SQL> alter session set container=PDB1;
SQL> create tablespace ggs_tblsp datafile ‘/u01/app/oracle/oradata/OGGDB1/datafile/gg_pdb1.dbf’ size 2G;
Note: Same needs to be done individually in all PDBs if there are multiple Pluggable.
2. Create a user in container database with prefix c##.
Note: In 12c this user is common to all the pluggable present. (In 12c all common users and roles are created with prefix c##)
SQL> create user c##ggadmin identified by Welcome1 default tablespace ggs_tblsp;
SQL> grant dba to welcome1 container=all;
Note if a tablespace is not created in any of the pluggable or container, you will hit the error tablespace doesn’t exist. So below is the workaround:
- Create the tablespace in all existing containers and Pluggable
- Or create the user without defining any tablespace. However, this is not recommended in Prod environment.
This post is from our Oracle GoldenGate 12c Administration Training, in which we cover Architecture, Installation, Configuring & Preparing the Environment, DML Replication – Online Change Synchronization, Initial Load, Zero Downtime Migration & Upgrading using GoldenGate, Oracle GoldenGate Security, Performance of Oracle GoldenGate and Troubleshooting and much more.
Next Task For You
Click on the image below to download your FREE Guide, Oracle GoldenGate 12c Interview Questions, & Learn More.
Do you have any queries in Oracle GoldenGate 12c?
Have a question related to your Oracle GoldenGate Career or Training?
Post any query regarding Oracle GoldenGate below and we will be happy to answer it.