Ad control

9
AD Control Manages parallel workers in AD Administration and AutoPatch. The administrative tool used to manage patch workers is AD Control, or adctrl. Frequently workers will fail or hang, which will require the Oracle Applications DBA to interface with adctrl. AD Control menu options will vary depending upon the AD patch version applied to the instance. When logged in as the application owner on the Admin Node, execute adctrl to display the menu options shown in AD Controller Menu To execute an adctrl menu option, simply type the menu option and press Enter. If options 2–6 are chosen, either specify the number of the worker that requires action, or press Enter for the action to be executed for all workers. The “Skip Worker” menu option is a hidden adctrl menu option. If a worker needs to be skipped, start adctrl, enter 8, and then enter the worker number. Only use this option if advised by Oracle Support.

description

 

Transcript of Ad control

Page 1: Ad control

AD ControlManages parallel workers in AD Administration and AutoPatch.

The administrative tool used to manage patch workers is AD Control, or adctrl. Frequently workers will fail or hang, which will require the Oracle Applications DBA to interface with adctrl.

AD Control menu options will vary depending upon the AD patch version applied to the instance. When logged in as the application owner on the Admin Node, execute adctrl to display the menu options shown in

AD Controller Menu

To execute an adctrl menu option, simply type the menu option and press Enter. If options 2–6 are chosen, either specify the number of the worker that requires action, or press Enter for the action to be executed forall workers.The “Skip Worker” menu option is a hidden adctrl menu option. If a worker needs to be skipped, start adctrl, enter 8, and then enter the worker number. Only use this option if advised by Oracle Support.

■Oracle Aplication DBA Portal Tip:With AD.I, adctrl may be used in noninteractive mode. Using adctrl noninteractively can expedite patch problem resolution.

Resolving AD Patch Worker FailureIf a worker has failed, the adpatch session will normally display a failedworker

Page 2: Ad control

message. The status of the worker may also be determined using adctrl. If a worker has failed, the worker error can be obtained by viewing the worker log file. Once the worker issue has been resolved, use adctrl torestart the worker.

If a worker has failed, and it is determined that the step the worker wastrying to execute may be skipped, the hidden option 8 of the adctrl menu, “Skip Worker,” may be used to skip the worker. It is only advisable to do thisif the step is not critical to the environment being patched.

■Oracle Aplication DBA Portal Tip:It may be necessary to research MetaLink or open an SR to resolve issues with failed workers. For additional information on MetaLink and the SR process, seeThe following are common worker failures that will be seen by the Applications DBA during patching. The error messages will be displayed by the adpatch session or in the worker log file:Error message: ORA-01013: user requested cancel of current operation Resolution to error: If this error occurs, simply use adctrl to restart the worker on the current machine.

Error message: Patch not applied successfully, adpatch did not cleanup its restart files (*rf9).

Resolution to error: If this error occurs, execute the following as theinstance owner:$cd $APPL_TOP/admin/$CONTEXT_NAME$mv restart restart_old$mkdir restart

After cleaning up the restart files, you may then restart the adpatch session using adpatch.

Then, use adctrl to restart the failed worker.

Page 3: Ad control

Error message: No error message is displayed; rather the worker log file states that the worker is complete, yet adctrl indicates that the worker is still running.

Resolution to error: This patching problem occurs when the worker is complete, but did not update patching tables correctly to notify the adpatch session that it has finished. In this scenario, the adpatch session is still waiting for the finish return code from the worker. When this occurs, use adctrl to fail the worker, then restart the worker.

■Oracle Aplication DBA Portal Tip:Any form, library, or report that fails to generate during the patch process can be regenerated manually after all patching and post-patching steps have completed. If the object still fails to compile, open an SR.

Page 4: Ad control

SOLUTION 1 : ADCTRL workers remain assigned

The error meant some AD patch was applied wrongly. The adpatchcode is not compatible with the adworker code. Hence the restart filediscrepancy in the worker log files. The solution as it worked outthrough SR was:

1. Stop the adpatch session through ADCTRL and take copies of thecurrent versions of adpatch and adworker executables.2. Relink AD executables:A. Run %APPL_TOP%\relinkenv.cmdB. In the command window that results, change directory to %APPL_TOP% and run apps.sh to set up all required environment variables. . ./apps.shC. Run command sh adrelink.sh force=y "ad all" 3. Recreate grants$ cd $ORACLE_HOME\appsutil\sql$ sqlplus /nologSQL> connect / as sysdbaSQL> @adgrants_nt.sql APPLSYS4. Run adpatch and resume the previous session.

SOLUTION 2 : ADCTRL workers remain assignedYou can also try to edit"d:\oracle\<SID>appl\admin\<SID>\restart\adpinit.rf9" and replce 'Promptfor mailto' with 'Apply mode Setting' in line 4. Try applying the patchwith restart=yes. if it still fails comment out line 4. Note, Oracle Support does not support editing restart files.

Error: The FND_INSTALL_PROCESSES table does not exist.

I run adctrl to show the worker status I get the below error;

Is that a problem?How can solve this?What does that mean?

Enter your choice [1] : 1

Error: The FND_INSTALL_PROCESSES table does not exist.This table is used for communication with theworker processes, and if it does not exist, it

Page 5: Ad control

means that the workers are not running,becausethe ad utility has not started them yet.

The FND_INSTALL_PROCESSES table is created at the beginning of an adpatch run and dropped after the patch completes successfully. adctrl is a utility that monitors and fixes patch issues. If no patch is currently running, then this is a normal error that adctrl will return.

If the patch was applied successfully on the TEST instance (check the patch log file and query AD_BUGS table to verify), then you can proceed and apply it on your PROD instance. Again, if you still want to monitor the workers status please do so while the patch is running.

Regarding ICXDLTMP.sql, this program is used to clean out ICX tables, and it should be regularly run to avoid huge tables. If this program is run on a regular basis this job should not run more than a few minutes.

Page 6: Ad control

Undocumented Option 8:

This will allow you to continue processing a job and kill the adworker that failed.

Back at the main adctrl menu choose option 8:

Enter your choice [1] : 8

Enter the worker number(s)/range(s) or 'all' for all workers,or press [Return] to go back to the menu :

To select the "Skip worker" option, type the number 8 andpress Return.

This can be useful in testing a patch and you need to let the patch or job run to completion.

ADWORKER LOGFILES for R12 EBS

How to find the log files for these workers? It is confusing to the newbie.

cd $APPL_TOP/admin/{ORACLE_SID}

adctrl interactive=n defaultsfile=$TOP/admin/prod/ctrldefs.txtmenu_option=SHOW_STATUS

$ adctrl interactive=n defaults_file=$APPL_TOP/admin/prod/ctrldefs.txt \logfile=adctr.log menu_option=SHOW_STATUS

Page 7: Ad control

ACKNOWLEDGE_QUIT Tell manager that a worker acknowledges quit

INFORM_FAILURE Tell manager that a worker failed its job

RESTART_JOB Tell worker to restart a failed job

SHOW_STATUS Show worker status

SHUTDOWN_WORKER Tell worker to quit

START_WORKER Restart a worker on the current machine