Intro To Multitenant Architecture

Intro To Multitenant Architecture

January 2, 2021 1 By dianarobete

I hope all of you had a great winter break! Did you spent some time learning something new? I, personally managed to spend about 4 hours on some Oracle training labs about Multitenant Architecture and things you can do with PDBs. The online labs were a great resource, however, I realized that I needed to go back to the documentation, and read/learn about PDBs in more detail. As I was progressing through these labs, questions were popping up in my head, what is this, what would happen if I do that…how about that…
Which made me think that there must be more DBAs in the world asking the same questions. With that in mind, I thought you might enjoy a mini series on the multitenant architecture.

In the coming weeks, I will post a series of articles about the Multitenant Architecture, in short easy to read format. To get this series started…I will need to begin with the basics, with an overview of the multitenant architecture. You might be very familiar with the terminologies and the topic.

When you hear that a database is configured in a Multitenant Architecture, it means that the database is setup and functions as a Multitenant Container database, aka CDB.

A Container Database (CDB) can have zero, one or many pluggable databases, or PDBs, which are created by users or DBAs.

A Pluggable Database (PDB) is a collection of schemas, schema objects, non-schema objects, users, tablespaces, etc. You can think of the PDB as a pre-CDB database, or non-CDB database, only from the database content perspective, and not memory/background processes perspective.
Databases prior to 12c were all non-CDBs. The non-CDB architecture was deprecated since 12.1.0.2, and in 20c and up, the non-CDB database is no longer an option, meaning you cannot create a non-CDB database.

What are the components of a CDB?

Did you know that you could have 5 component types in a CDB? Not all of them must be present in the CDB! You might have CDBs with all of the components present, and you might have CDBs with only a few of these components. However, some components must be part of the CDB. Let’s find out which ones!

  • The Root Container, which is named CDB$ROOT. All the pluggable databases belong to the root container, or are plugged into the root.
    The root container has the Oracle metadata (data dictionary), and common users.
  • The Pluggable databases are a component of the CDB. Each CDB can have 0, 1 or multiple PDBs that are created by users after the CDB is created. Did you notice that you can have a CDB without a PDB. But then what would be the point of the CDB, right? The PDB is a collection of the schemas and objects that are required to run an application. Think of it as the database behind an application. There can be multiple PDBS in a CDB, in other words, the container database, can support multiple applications, the HR Application, the Finance Application, Sales application, you get the idea, each one of them contained within its own PDB. In a non-CDB world, you would have had a separate database for HR, a separate database for Finance and so on. And many times this would be required as the schema owner would be the same, and many objects would have the same name (think about public synonyms, table names).
  • The Application Container is another component of the CDB. Each CDB can have 0, 1 or multiple application containers. Application containers were introduced in 12cR2. The application container has one application root, and zero or more PDBs that are plugged into the application root container. The application root belongs to the CDB$ROOT container. A PDB can belong to an application container, but that is not necessary, however a PDB can belong to only one application container. If the PDB belongs to an application container, then it is called an Application PDB. The application container could contain an Application Seed, that would be a template for creating application PDBs within the application container. The application seed is optional.
  • The Seed PDB is another component of the CDB. Each CDB has one and only one Seed. When you create a CDB, a Seed PDB is also created. This seed is named PDB$SEED. The seed PDB is a system supplied template that is used to create PDBs within the CDB.
  • The System Container is the logical container of the whole CDB (the root container and all the other PDBs).

Now you have an understanding of the architecture! I am curious, were you familiar with all of these components? Can you see how these components could help you as a DBA?

Join me next time for more!


If you enjoyed this article, and would like to learn more about databases, please sign up to my weekly email, and you will receive my FREE guide: 7 Questions to Ask When Troubleshooting Database Performance Problems!


If you are interested in improving your Oracle Tuning skills, check out my course theultimatesqltuningformula.comFollow the link to get the best price, only $18.99 CAD available until the end of the month!