What Is a Container Database?

August 8, 2023

With the release of Oracle Database 23ai in 2024, the “container database” has been a key feature. Also, beginning with Oracle Database 23ai, a multitenant container database is the only supported architecture. Like a “pluggable database,” it essentially makes data more accessible and portable—the term pluggable indicates that it can be plugged into different containers. Container databases group multiple databases together to share common features. Specifically, “A container is a collection of schemas, objects, and related structures in a multitenant container database (CDB). Within a CDB, each container has a unique ID and name.” Thus, A CDB includes zero, one, or many customer-created pluggable databases (PDBs) and application containers.

On the inside, a CDB contains two databases, root and seed. Root contains some user information and Oracle metadata. Seed is the pluggable database inside the CDB, and it works as a sort of template to create more PDB’s. Like any regular database, a PDB contains objects, data, and schemas that allow you to connect and operate on the database using an IDE.

Why are there multiple databases within a CDB? While it may seem like added complexity, this introduces more flexibility and more efficient use of resources. By packaging these resources together, it becomes easier to move data and code to wherever it is needed, without the overhead of managing multiple databases across multiple virtual machines. As developers have found with projects like Kubernetes, there are distinct advantages to using containers in several contexts—for databases, the CDB offers similar opportunities.

Key advantages include:

  • More efficient use of resources
  • Easier duplication and access across resources
  • Portability
  • Easier to administrate, including user and admin controls

Container and pluggable databases are still accessed and utilized like any traditional database, and developers can use many familiar IDE’s, like SQL Developer, to connect and manage the CDB/PDB. Developers will largely be connecting to a pluggable database within the CDB to manage their data as needed.

For more on the database concepts introduced in Oracle Database 23ai and the differences between CDB’s and PDB’s, refer to the Oracle Database Concepts page. Oracle Database 23ai builds upon previous innovations and introduces a plethora of new features, including JSON relational duality, microservice support, and SQL enhancements.