Monday, April 27, 2015

Datapatch: Database 12c Post Patch SQL Automation (Doc ID 1585822.1)

Datapatch in a Multitenant Environment:

When datapatch is run to invoke any SQL actions in a Multitenant environment, datapatch only applies the changes to the ROOT, SEED and any open PDBs based on the pending actions.  For any PDB that is not currently open, the SQL patch will not be applied.  When such a PDB is reopened, it will be opened in restricted mode as there will be a patch level mismatch between the PDB and the ROOT.

Call DBMS_PDB.CHECK_PLUG_COMPATIBILITY on 12.1.0.1. PDB xml file will return these two violations, which are expected.
  SQL Patch              ERROR
 
SQL patch bug # mismatch: Installed in the PDB but not in the CDB.   Install the SQL patch in the PDB or the CDB

This error can be cleared by running datapatch again and closing and reopening the affected PDB(s)
1)    Invoke datapatch:
% cd $ORACLE_HOME/OPatch
% datapatch
2)    Close and reopen the affected PDB
Connect as SYS
alter pluggable database <PDB Name> close instances =all;
alter pluggable database <PDB Name> open read write instances =all;
3) Check again for plugin violations (by querying pdb_plug_in_violations in cdb$root), there should be none and the pluggable database should be opened in normal mode

No comments:

Post a Comment