Database field guide · 14
Oracle Multitenant Internals
CDB roots, PDB dictionaries, and object links
A physical and dictionary-level model of Oracle containers, common metadata, object links, DDL replay, and plug-in compatibility.
Franck Pachot7 chaptersOracle · CDB · PDB · dictionary internals
Build the mental model before choosing the mechanism.
This minibook was AI-generated from Franck Pachot's archived blog posts. Links to the original articles are included for source context and verification.
01
One instance, many containers
A CDB shares an instance and root dictionary while each PDB presents an application-facing database boundary with local data and metadata.
- CON_ID is part of multitenant identity.
- CDB$ROOT and PDB$SEED have special lifecycle roles.
- Services, not container names alone, route applications.
02
The dictionary is selectively shared
Oracle consolidates some dictionary state in the root while preserving container-local rows elsewhere. CONTAINERS() views and internal metadata project the correct scope.
- CDB_ views are not simple UNION ALL wrappers.
- Common objects may have metadata-linked definitions.
- Always preserve container context in diagnostics.
03
Object links cross the boundary
Metadata links and data links let a PDB resolve common objects whose definition or rows live in the root. Parsing and execution can therefore operate in different container contexts.
- Object links are an internal sharing mechanism.
- Fixed tables require specialized links.
- Execution context explains surprising recursive SQL.
04
Common DDL must be replayable
A common-user or system-package change initiated from one container may need root execution and replay into PDB context. Oracle records enough state to keep common metadata coherent.
- Common and local users obey different naming and scope rules.
- Package compilation can cross container boundaries.
- DDL replay failures surface as compatibility violations.
05
Plug-in is a compatibility check
Unplug and plug operations compare options, patches, character sets, common objects, and encryption keys. PDB_PLUG_IN_VIOLATIONS is the primary explanation surface.
- Warnings and errors have different open consequences.
- Run compatibility checks before moving files.
- Resolve root/PDB patch drift deliberately.
06
Isolation extends to operations
File destinations, resource plans, save state, services, lockdown profiles, and standby behavior determine whether the logical tenant boundary survives routine operations.
- Place files through container-aware defaults.
- Resource plans limit noisy neighbors.
- Test startup, clone, switchover, and recovery per service.
07
Field manual
Concrete mechanics, diagnostic evidence, and executable patterns to carry into a real system.
01
Anchor every observation to a container
SYS_CONTEXT and V$CONTAINERS establish where a session executes. Never compare dictionary rows from different containers without retaining CON_ID.
SELECT sys_context('USERENV','CON_NAME') con_name,
sys_context('USERENV','CON_ID') con_id FROM dual;
SELECT con_id, name, open_mode FROM v$containers ORDER BY con_id;
02
Inspect plug-in violations
Violations persist by PDB, type, status, and message. ERROR entries can prevent normal open; resolved entries remain useful migration history.
SELECT name, cause, type, status, message, action
FROM pdb_plug_in_violations
WHERE status <> 'RESOLVED'
ORDER BY time;
03
Query across containers deliberately
CONTAINERS() executes a container-aware query and adds CON_ID. The common user needs suitable container data privileges; it is not an unrestricted cross-PDB shortcut.
ALTER SESSION SET CONTAINER = CDB$ROOT;
SELECT con_id, owner, object_name
FROM containers(dba_objects)
WHERE object_name = 'ORDERS';
04
Verify services and save state
PDB open mode and application service placement must survive restart and role change. Save state records desired open mode but does not replace service configuration.
ALTER PLUGGABLE DATABASE sales OPEN;
ALTER PLUGGABLE DATABASE sales SAVE STATE;
SELECT con_id, name, open_mode, restricted FROM v$pdbs;
08
Source articles
Optional deep dives with the complete experiments and product-version context behind this guide.