The Oracle Database version 12c which dates back to 2016 made a major architectural change, allowing Database Administrators to choose between the existing architecture or utilise a new architecte called Multitenant.
The easiest way to think of this new Multitenant architecture for the database is to relate it to how Virtual Machines are created on a single physical server. Multitenant for the Database allows a Single Oracle Database Instance to manage many databases. The Database instance represents a single set of Oracle Processes and Memory allocation shared among many databases.
In the Database Multitenant world, the Database Instance managing many database is known as the Container Database or CDB and the databases being managed are known as pluggable databases or PDBs and can also be referred to as tenants.

Oracle Database 19c will be the last Oracle version that will support the old non container architecture, so future releases such as 21c and the new 23ai will have to be created as container databases.
If a Container only manages a single pluggable database, its is known as a single tenant architecture, more than 1 pluggable databases is known as multi-tenant. The single tenant architecture will feel more familiar to the old architecture as there is a one to one relationship between the Database Instance and the Pluggable Database.
With the change to CDB architecture in mind many customers are creating databases with the new CDB setup which Oracle RDS does support. A question that will be asked is how do we handle existing databases on the legacy architecture how can we migrate those to become a container database to future proof it. This is an important question as there is no direct way to upgrade a non container database to a CDB of a higher version such as 19c non CDB to 21c CDB directly on Oracle RDS.
Luckily RDS Oracle does support migration of Non Container databases to Container databases on the same version which we detail below with a walk through.
So we can migrate a database of
- 12c nonCDB to 12c CDB
- 19c nonCDB to 19 CDB
but we can’t migrate a database
- 12c nonCDB to 19 CDB directly
- 19c nonCDB to 21 CDB directly
Database version upgrades are for the same architecture only, but once on a given architecture we can upgrade the database release.
Lets walk through how we can do this on Oracle RDS.
Navigate to RDS Console and select our database to migrate to the CDB architecture.
If you select Configuration for a non CDB database you will see: it is shown as ‘Non-multitenant’

We can also query the database v$database view logged in as admin as below:
select name, cdb from v$database;

If the admin password is managed by Secrets Manager this must be disabled as the conversion will not work with this

To change to a self managed password : Select Database select in RDS Console > click Modify and update

This can take several minutes to complete
Next Select Database select in RDS Console -> click Modify and on the wizard click on checkbox ‘Oracle multitenant architecture’


choose to Apply immediately -> click Modify DB instance
The Database will enter upgrading state in the console (even though its an architecture change rather than an upgrade)

Click on Events in the left pane to monitor the upgrade progress, using refresh icon, the upgrade will take some time allow several hours, my test on a small minimal database took just over 1 hour.
The Events Pages provides some insight into the migration to CDB architecture process in chronological order below:
- The pre-check started for the DB engine version upgrade.
- The pre-check finished for the DB engine version upgrade.
- Backing up DB instance
- Backing up DB instance
- DB instance restarted
- DB instance shutdown
- DB instance restarted
- DB instance shutdown
- DB instance restarted
- The engine version upgrade started.
- DB instance restarted
- The engine version upgrade finished.
- The post-upgrade tasks are in progress.
- Finished DB Instance backup
- Database instance patched
- Creating automated snapshot
- Backing up DB instance
- Automated snapshot created
- Finished DB Instance backup
- Performance Insights has been enabled
- Monitoring Interval changed to 60
- Updated to use DBParameterGroup default.oracle-se2-cdb-19
- Finished updating DB parameter group
- DB instance shutdown
- DB instance restarted
Once the database is available we can confirm the database is now using the new CDB architecture

Under Configuration we see:

Note the configuration is now a Single-tenant configuration, this is using the new container architecture but contains only a single pluggable database or single tenant.
Its worth noting that the container database identified by ‘SYSTEM ID (SID)’ is called RDSCDB, and our single pluggable database still has the same name of ORCL. Note we can’t connect to the CDB RDSCDB we only connect to the pluggable databases.
The connection string to the converted database remains the same as the pluggable database has inherited the same name, and we can also verify this using sqlplus as below, we can query v$database and v$pdbs to view information about the setup as below:
sqlplus admin/'<password>’@//<container database endpoint>:1521/ORCL
select name, cdb from v$database;
select name from v$pdbs;

Note we can’t easily migrate back to the old nonCDB architecture once we have migrated other than by restoring a snapshot or performing a database migration using a tool such as DMS or Datapump.
We are now in a position to add additional pluggable databases, note Oracle SE2 supports upto 3 pluggable databases at no extra cost, Oracle EE permits under RDS upto 30 depending on service levels but also needs a multi-tenant license in place. Conversion of a single-tenant CDB to the multi-tenant configuration is also irreversible.
To convert a single tenant to a multi-tenant configuration CDB the database engine must be a minimum version of 19.0.0.0.ru-2022-01.rur-2022.r1.
Also we can’t use Oracle Data Guard in the multi-tenant configuration, but it can be used it in the single-tenant CDB setup.
To add another PDB, select database in RDS Console -> Modify -> Select Multi-tenant configuration


This will take several minutes to complete, once done the RDS Console will now list the Container database with its pluggable database in a tree structure as below:

Now under Actions menu we have the ability to add new tenants (pluggable databases)

Lets add a second pluggable database called PDB02

This will take several minutes to complete, once done we see PDB02 added to our tree in the RDS console

The connection details for our new pluggable database pdb02 will use the same endpoint and port as the ORCL database/container database, but the name to pass will be PDB02.
we can test this in sqlplus as below again query v$pdbs to confirm we are connected to new pluggable database.
sqlplus pdb02_admin/'<password>’@//<container database endpoint>:1521/PDB02
select name, cdb from v$database;
select name from v$pdbs;
