버전 비교

  • 이 줄이 추가되었습니다.
  • 이 줄이 삭제되었습니다.
  • 서식이 변경되었습니다.

...

코드 블럭
languagesql
titlesys 계정으로 수행
linenumberstrue
startup upgrade
alter pluggable database all open upgrade;
select status from v$instance;
select open_mode from v$pdbs;
quit
펼치기

 

datapatch 수행

서식 미적용
[oracle@orcl ~]$ sqlplus /nolog

SQL*Plus: Release 18.0.0.0.0 - Production on Fri Feb 22 18:07:44 2019
Version 18.5.0.0.0

Copyright (c) 1982, 2018, Oracle.  All rights reserved.

SQL> connect / as sysdba
Connected to an idle instance.

SQL> startup upgrade
ORACLE instance started.

Total System Global Area 1660940400 bytes
Fixed Size		    8896624 bytes
Variable Size		 1056964608 bytes
Database Buffers	  587202560 bytes
Redo Buffers		    7876608 bytes
Database mounted.
Database opened.

SQL> alter pluggable database all open upgrade;

Pluggable database altered.

SQL> select status from v$instance;

STATUS
------------
OPEN MIGRATE

SQL> select open_mode from v$pdbs;

OPEN_MODE
----------
MIGRATE
MIGRATE

SQL> quit
Disconnected from Oracle Database 18c Enterprise Edition Release 18.0.0.0.0 - Production
Version 18.5.0.0.0

datapatch 수행

코드 블럭
languagebash
titleoracle 유저로 수행
linenumberstrue
cd $ORACLE_HOME/OPatch
./datapatch -verbose

 

펼치기
서식 미적용
[oracle@orcl ~]$ cd $ORACLE_HOME/OPatch

[oracle@orcl OPatch]$ ./datapatch -verbose
SQL Patching tool version 18.0.0.0.0 Production on Fri Feb 22 18:10:27 2019
Copyright (c) 2012, 2018, Oracle.  All rights reserved.

Log file for this invocation: /u01/app/oracle/cfgtoollogs/sqlpatch/sqlpatch_12744_2019_02_22_18_10_27/sqlpatch_invocation.log

Connecting to database...OK
Gathering database info...done

Note:  Datapatch will only apply or rollback SQL fixes for PDBs
       that are in an open state, no patches will be applied to closed PDBs.
       Please refer to Note: Datapatch: Database 12c Post Patch SQL Automation
       (Doc ID 1585822.1)

Bootstrapping registry and package to current versions...done
Determining current state...done

Current state of interim SQL patches:
Interim patch 27923415 (OJVM RELEASE UPDATE: 18.3.0.0.180717 (27923415)):
  Binary registry: Not installed
  PDB CDB$ROOT: Applied successfully on 19/02/22 17:46:17.235883
  PDB PDB: Applied successfully on 19/02/22 17:53:34.456168
  PDB PDB$SEED: Applied successfully on 19/02/22 17:53:34.456168
Interim patch 28790647 (OJVM RELEASE UPDATE: 18.5.0.0.190115 (28790647)):
  Binary registry: Installed
  PDB CDB$ROOT: Not installed
  PDB PDB: Not installed
  PDB PDB$SEED: Not installed

Current state of release update SQL patches:
  Binary registry:
    18.5.0.0.0 Release_Update 1812161059: Installed
  PDB CDB$ROOT:
    Applied 18.3.0.0.0 Release_Update 1806280943 successfully on 19/02/22 17:46:17.223094
  PDB PDB:
    Applied 18.3.0.0.0 Release_Update 1806280943 successfully on 19/02/22 17:53:34.449405
  PDB PDB$SEED:
    Applied 18.3.0.0.0 Release_Update 1806280943 successfully on 19/02/22 17:53:34.449405

Adding patches to installation queue and performing prereq checks...done
Installation queue:
  For the following PDBs: CDB$ROOT PDB$SEED PDB
    The following interim patches will be rolled back:
      27923415 (OJVM RELEASE UPDATE: 18.3.0.0.180717 (27923415))
    Patch 28822489 (Database Release Update : 18.5.0.0.190115 (28822489)):
      Apply from 18.3.0.0.0 Release_Update 1806280943 to 18.5.0.0.0 Release_Update 1812161059
    The following interim patches will be applied:
      28790647 (OJVM RELEASE UPDATE: 18.5.0.0.190115 (28790647))

Installing patches...
Patch installation complete.  Total patches installed: 9

Validating logfiles...done
Patch 27923415 rollback (pdb CDB$ROOT): SUCCESS
  logfile: /u01/app/oracle/cfgtoollogs/sqlpatch/27923415/22239273/27923415_rollback_ORCL_CDBROOT_2019Feb22_18_11_29.log (no errors)
Patch 28822489 apply (pdb CDB$ROOT): SUCCESS
  logfile: /u01/app/oracle/cfgtoollogs/sqlpatch/28822489/22669539/28822489_apply_ORCL_CDBROOT_2019Feb22_18_12_41.log (no errors)
Patch 28790647 apply (pdb CDB$ROOT): SUCCESS
  logfile: /u01/app/oracle/cfgtoollogs/sqlpatch/28790647/22592236/28790647_apply_ORCL_CDBROOT_2019Feb22_18_13_46.log (no errors)
Patch 27923415 rollback (pdb PDB$SEED): SUCCESS
  logfile: /u01/app/oracle/cfgtoollogs/sqlpatch/27923415/22239273/27923415_rollback_ORCL_PDBSEED_2019Feb22_18_13_50.log (no errors)
Patch 28822489 apply (pdb PDB$SEED): SUCCESS
  logfile: /u01/app/oracle/cfgtoollogs/sqlpatch/28822489/22669539/28822489_apply_ORCL_PDBSEED_2019Feb22_18_14_45.log (no errors)
Patch 28790647 apply (pdb PDB$SEED): SUCCESS
  logfile: /u01/app/oracle/cfgtoollogs/sqlpatch/28790647/22592236/28790647_apply_ORCL_PDBSEED_2019Feb22_18_16_04.log (no errors)
Patch 27923415 rollback (pdb PDB): SUCCESS
  logfile: /u01/app/oracle/cfgtoollogs/sqlpatch/27923415/22239273/27923415_rollback_ORCL_PDB_2019Feb22_18_13_50.log (no errors)
Patch 28822489 apply (pdb PDB): SUCCESS
  logfile: /u01/app/oracle/cfgtoollogs/sqlpatch/28822489/22669539/28822489_apply_ORCL_PDB_2019Feb22_18_14_45.log (no errors)
Patch 28790647 apply (pdb PDB): SUCCESS
  logfile: /u01/app/oracle/cfgtoollogs/sqlpatch/28790647/22592236/28790647_apply_ORCL_PDB_2019Feb22_18_16_07.log (no errors)
SQL Patching tool complete on Fri Feb 22 18:16:15 2019

Database 재기동 

코드 블럭
languagebash
titleoracle 유저로 수행
linenumberstrue
cd $ORACLE_HOME/OPatch
./datapatch -verbose

 

펼치기

 

Database 재기동 

수행
linenumberstrue
sqlplus /nolog
connect / as sysdba
코드 블럭
titlesys 계정으로 수행
linenumberstrue
shutdown
startup
alter pluggable database all open;
펼치기
서식 미적용
[oracle@orcl ~]$ sqlplus /nolog

SQL*Plus: Release 18.0.0.0.0 - Production on Fri Feb 22 18:17:22 2019
Version 18.5.0.0.0

Copyright (c) 1982, 2018, Oracle.  All rights reserved.

SQL> 
코드 블럭
languagebash
titleoracle 유저로 수행
linenumberstrue
sqlplus /nolog
connect / as sysdba
코드 블럭
titlesys 계정으로 수행
linenumberstrue
shutdown startup

Connected.

SQL> shutdown
Database closed.
Database dismounted.
ORACLE instance shut down.

SQL> startup
ORACLE instance started.

Total System Global Area 1660940400 bytes
Fixed Size		    8896624 bytes
Variable Size		 1056964608 bytes
Database Buffers	  587202560 bytes
Redo Buffers		    7876608 bytes
Database mounted.
Database opened.

SQL> alter pluggable database all open;
펼치기
 


Pluggable database altered.