Thursday, September 26, 2013

R12 Online Patching ? ADOP AD Online Patching replaces adpatch in 12.2.

Online Patching ? ADOP AD Online Patching replaces adpatch in 12.2.

Online Patching is new feature which  is major change with R12 12.2 for DBA's , as downtime would be reduced for any patching activity from hours to few minutes.

Now it is possible to apply even upgrade patches in Online Patching mode minimizing downtime to very low, But please note upgrade to 12.2 is not possible via online patching from lower versions . 

On the technology part  of online patching, It is some what similar to Stage Appl TOP, But in online patching database objects also will maintain two copies to support this method. i.e run file system and run edition of DB, patch file system and patch edition of DB.

In applications  contains two setf of file systems patch and run file system, run is where actually applications is running from and patch is used for patching the applications when it is running. in database we have edition based concept, where we contain patch edition and run edition.

Actually the base for the online patching concept came into picture with 11GR2 database version , Where there is concept called "Edition Based Redefinition", Online patching database part is based on it.

Online Patching in 12.2. is done using adop utility (No Longer adpatch), But this utility calls internally the required patching(adpatch) or other  utilities.

and all the patches need to be applied using adop only, Other methods are not supported. But we can apply the patches in hot patch mode using adop, But in this method , The online patching concept will not come into picture , It is traditional way of applying patch directly on the run file system and run edition of the database when applications and DB is running.

Online Patching (adop) runs in different phases, The below are phases and syntax of adop.


1) prepare  Phase

patch edition and run editions are synchronized in incremental synchronizations of files changed in the run file system.

patch edition is created in th database

How to run this , Syntax: $ adop phase=prepare

2)apply phase 

patches are applied to patch patch edition in the database and patch file system in the applications.

adpatch is called internally by adop to apply the patches.

production application is un effected by these changes, and multiple patches can be applied.

How to run this , Syntax: $ adop phase=apply

3)finalize phase 

Performs all the activities which can be done when applications is up & running.

example: compile invalids,generate objects,pre-compile DDL

How to run this , Syntax: $ adop phase=finalize

This stage we can stay as long as we want, until once we have downtim to move the changed in the cutover stage , 

4)cutover phase

This is a stage where where actual changes reflects and downtime is required for this stage. 

Users are logged off during this stage.

patch file system is promoted to be the run file system

patch database edition is promoted to the run database edition.

users are actually broght back on online on the patched system.

How to run this , Syntax: $ adop phase=cutover

5)cleanup phase

Cleanup happens once users online on the system

There are no cleanup on the file system , Only it happens on the database where it deletes the code objects from old editions of the database where patching happened.

How to run this , Syntax: $ adop phase=cleanup

syntax of patch application in 12.2 using adop is : $ adop phase=apply patches=123456


  1. Very good Post on patching in R12.2 ...Thanks

    Would like to know which env should be sourced while applying the patch in R12.2, will it be patch or run edition ?


  2. adop (for patch cycle) should always source the PATH_BASE environment file.
    adop (hotpatch=yes) should source the RUN_BASE environment file

  3. wat would be the env sourced for different phases

  4. Execute the run file system environment file before applying patch...adop will take care of rest.

  5. After file system swapping does the user need to change the port in home URL?
    FS1 using port 8000 and FS2 using port 8001

    before applying patch user connects home page using below URL:

    After adop cutover phase the file system swapped.
    So Do we need to conncet home page using http://myhost:8001 ??

    Please explain on the above.

  6. This comment has been removed by the author.

  7. can we run adop=finalize after adop=prepare

    example :

    if yes, what is the usage.

  8. I have installed R12.2.0 on windows 2012 R2.It is installation completed successfully without any error.Now as per oracle instruction i am applying the required patch. I have already applied patch 18860387 successfully, using hotpatch mode,I have used following adop phase=apply patches=18860387 hotpatch=yes.In the same command window,i am applying patches 17204589,21900871 by merged them.I have used following following command adop phase=apply patches=17204589,21900871 merge=yes hotpatch=yes.first time it has showed error "ERROR: The following jars failed to get generated properly. oracle\VIS\fs1\EBSapps\comn\java\classes\oracle\apps\fnd\jar\adall.jar "
    i again excecuted same command to retry but it is still running even after 16 hrs. Can you please help to detect the problem? also if i want to abort then how to abort it.I am not DBA but i am doing this install on my personal system.