APPLY Phase, Oracle Apps Online Patching

The APPLY phase is where ADOP does the actual patching. It parses the arguments and, looks if the system is ready for APPLY phase (is PREPARE run and completed successfully) and then internally invokes adpatch to apply the patches.

In a single ADOP phase, you can run as many number of APPLY phases after your PREPARE as long as you have not run finalize.

The generic command to run apply phase is

adop phase=apply patches=nnnnnnnn workers=x

If you have multiple patches, you could list them as

adop phase=apply patches=nnnnnnnn,mmmmmm,oooooooo

If you add merge =yes, the patches will be merged before they are applied

  • Parse the arguments passed
  • Verify parameters
  • Validate system setup
    • Check for required ENV setup
    • Determine Admin Node and validate node_registry.
    • Perform Database Sanity Checks
  • Acquire lock on sessions table
  • Check for pending ADOP sessions
    • Check for pending hotpatch session
    • Fetching number of incomplete cycles for the node having appltop_id=nnnn; If not 0, then phase exists
  • Check for active cleanup session
  • Detect current ADOP session ID. Continue with the same session ID
  • Check if ADOP cycle for <node> is incomplete at session_id nnn
  • Using ADOP session id from currently incompl_id
  • Check for patch context file and generate if not present
  • Check for status of phase
select count(1)
  from  ad_adop_sessions
 where  adop_session_id=100 
   and (apply_status in ('N','P')) 
   and node_name=<node_name>
  • Execute Apply Phase
    • Update ADOP session status
    • Update session process id
update ad_adop_sessions
   set status='R'
 where adop_session_id = 100 
   and appltop_id = <nnnn> 
   and node_name=<nodename>;
  • Update the input parameters to DB
  • Updating session dates
  • Check for Logon Trigger existence and enablement
  • Sourcing the Patch Edition environment
  • Value of other_adpatch_arguments
  • Apply Patch with ADPATCH utility
    • Defaults File
      • Read
      • Substitute tokens
      • Regenerate defaults file
    • Check if the patch is already applied. If not applied proceed. Else exit
adpatch  workers=4      console=no interactive=no  defaultsfile=..\..\adalldefaults.txt patchtop=$PATCH_TOP\12345678 driver=u12345678.drv
  • Generate Post Apply Reports
  • Generate log report
  • Update ADOP session status

Leave a comment

Your email address will not be published. Required fields are marked *