Enhance Skills Daily

October 03, 2026  ·   · 

Oracle DBA Lesson 52 Part 1 — Where Proxy PDB Work Runs

A proxy gives a local PDB context for work against a referenced PDB. In the remote design here, application tables and ordinary SQL execution stay in the remote database. Design availability and grants around that dependency.

Oracle DBA Lesson 52 Part 1 — Where Proxy PDB Work Runs

Understand the two locations

Local CDBRemote CDB
APP_PROXY, the proxy containerAPP_PDB, the referenced container
Local proxy administration and its filesApplication tables and ordinary SQL execution
Client access through a service for the proxyListener endpoint reachable from the proxy environment

Oracle copies the SYSTEM and SYSAUX tablespace files when creating the proxy. Plan physical storage for those files. In this design the local proxy files use the Oracle Managed Files destination. The proxy is not an independent full application-data clone. A proxy's local files do not replace a referenced-database recovery copy.

The local PDB name tells you which context a client enters. It does not provide an isolation boundary for application writes against the referenced database. Follow the data owner, grants and actual execution path.

See the 19c architecture overview.

Create and identify the proxy

In the local CDB root, the root is open read/write and the account has the common CREATE PLUGGABLE DATABASE privilege. PROXY_SRC is a private link in that root and reaches the remote root or the referenced PDB. A remote-root link uses a common account. A direct referenced-PDB link account needs CREATE PLUGGABLE DATABASE. The referenced CDB uses local undo and ARCHIVELOG, and the referenced PDB is open READ WRITE at creation. The PDB and service names are distinct. Oracle 19c proxy sessions support password authentication.

CREATE PLUGGABLE DATABASE app_proxy
  AS PROXY FROM app_pdb@proxy_src;

ALTER PLUGGABLE DATABASE app_proxy OPEN READ WRITE;

SELECT pdb_name, is_proxy_pdb
FROM dba_pdbs
WHERE pdb_name = 'APP_PROXY';

AS PROXY chooses a reference to the named PDB. APP_PDB identifies the referenced container and PROXY_SRC establishes the creation connection. The new proxy starts mounted/NEW; its first read/write opening completes integration. Inspect creation/open errors before continuing.

Application-container synchronization is another proxy use case. It adds application name, version, and link-scope requirements. It is outside this ordinary remote PDB.

Expected local catalog row:

PDB_NAMEIS_PROXY_PDB
APP_PROXYYES

The flag classifies the container. It does not test application connectivity or approve a particular update. Query the view from the local root. See CREATE PLUGGABLE DATABASE, DBA_PDBS, and creating a proxy PDB.

Separate creation from ongoing communication

Creation: local root -- PROXY_SRC link --> referenced database
Ongoing:  local proxy -- direct connection --> referenced listener/PDB

After creation the proxy communicates directly with the referenced PDB, using its listener endpoint. A successful creation-link test does not test every later connection requirement. Include name resolution, routing/firewall reachability, the actual listener endpoint, and the referenced PDB's availability. A plain database-link query explicitly uses its link for that statement's remote access.

If the referenced listener has a different host name or a nondefault port, use its documented proxy-related host/port configuration. These are referenced-side settings:

-- Referenced CDB root; only after verifying APP_PDB and its real listener:
ALTER PLUGGABLE DATABASE app_pdb
  CONTAINERS HOST = 'remote-db.example.com';
ALTER PLUGGABLE DATABASE app_pdb
  CONTAINERS PORT = 1599;

They do not start a listener or change its own configured listening port.

See ALTER PLUGGABLE DATABASE — CONTAINERS HOST and PORT and creating a proxy PDB.

Follow one ticket through a query and a write

The referenced application schema has a SUPPORT_TICKET table, with ticket 811 initially OPEN. The session connects through a service for APP_PROXY and uses password authentication. These statements address the table through that proxy context:

SELECT status FROM support_ticket
WHERE ticket_id = 811;

Expected result:

STATUS
OPEN

The request reaches the referenced PDB; its result returns through the proxy. The table remains remote. The diagram represents direction and ownership, not packet timing or transfer size.

A new query fails if the referenced PDB or the required network path is unavailable. The local open state does not supply the rows. Check the remote PDB state, endpoint and reachability, authentication, and grants. An error does not automatically call for a database restore.

If closing the ticket is the intended work, the session has the necessary privileges, and the referenced PDB is writable:

UPDATE support_ticket SET status = 'CLOSED'
WHERE ticket_id = 811;
COMMIT;

Check that exactly the intended row was affected. A later query in another session on the referenced PDB can observe the committed change:

SELECT ticket_id, status FROM support_ticket
WHERE ticket_id = 811;

Expected result:

TICKET_IDSTATUS
811CLOSED

UPDATE changes an existing row; COMMIT makes the transaction permanent and visible to subsequent statements in other sessions. Use a full clone when the work requires a separate copy that may be changed independently. An update through a proxy can affect the referenced application's actual table.

See UPDATE privilege requirements and COMMIT semantics.

Keep administration scoped correctly

Ordinary queries and DML execute in the referenced PDB. In proxy context, ALTER PLUGGABLE DATABASE and ALTER DATABASE affect the proxy locally. An administrative statement in the owning root that opens or closes APP_PROXY likewise targets the proxy.

From the local root:

ALTER PLUGGABLE DATABASE app_proxy CLOSE IMMEDIATE;

This closes the local proxy and affects its sessions. The referenced APP_PDB retains its own open state. A later reopening of the local proxy still depends on the remote path and appropriate access.

Choose the required outcome

RequirementSuitable starting choiceDependency to plan
Separate data for independent workOrdinary full cloneNew copy, capacity, commissioning and isolation
Move the PDB to a new CDBRelocationPlanned handover, clients and recovery readiness
Local PDB context while data stays referencedProxyReferenced PDB, its listener/network and permissions

This comparison means an ordinary full clone, not a snapshot-dependent or continually refreshed variant.

See cloning and relocation.

Recap

A proxy is a local PDB context for a referenced PDB. Application tables and ordinary SQL stay in the referenced database. Oracle copies SYSTEM and SYSAUX locally. Those files are not an independent application copy, and they do not replace a recovery copy of the referenced database.

Creation uses the PROXY_SRC link. After that, the proxy communicates directly with the referenced listener and PDB. IS_PROXY_PDB = YES classifies the container. A query or a committed update through the proxy runs against the referenced table. Closing APP_PROXY affects the local proxy and its sessions. APP_PDB keeps its own open state.

Choose an ordinary full clone for separate data, relocation to move the PDB to a new CDB, or a proxy when the data stays in the referenced database.

Quiz

1. Where does the ticket query normally execute when submitted through the proxy?

2. What does IS_PROXY_PDB = YES establish?

3. Which path is used after proxy creation?

4. The local proxy is open but the referenced PDB is unavailable. Can a new query retrieve the ticket rows?

5. You need separate data for testing updates independently. Which choice fits?

No comments:

Post a Comment

Vocabulary Revision 6 — Lessons 21 to 24

Lessons 21–24 · 16 words Watch on YouTube Contents https://www.apps-dba.com/ https://www.youtube.com/@EnhanceSkillsDaily Open ...