Saturday, January 1, 2011

RMAN checksyntax worth using it



Yesterday I have started RMAN restore and recovery session of my 70 GB Oracle Apps 12.1.3 RAC database in the run block and went to sleep.

When I saw it in the morning, the script got terminated because of some syntax error in the run block. So the whole night has been wasted because of a simple syntax error.

I was checking for any tools in RMAN which can do a syntax check and fortunately I was able to locate the "checksyntax" command which is available from 10g onwards.

One of the powerful commands in RMAN which can be used to check the syntax of big rman scripts which runs for a long time, before start the script we can check the syntax of the script and run it without worrying of the termination of scripts with syntax errors.

Eg:

$ rman checksyntax

Recovery Manager: Release 10.2.0.5.0 - Production on Thu Dec 23 15:21:32 2010
Copyright (c) 1982, 2007, Oracle. All rights reserved.
RMAN>
RMAN> recover data;
RMAN-00571: ===========================================================
RMAN-00569: =======ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-00558: error encountered while parsing input commands
RMAN-01009: syntax error: found "identifier": expecting one of: "copy, clone, database, datafile, datafilecopy, device, standby, tablespace"
RMAN-01008: the bad identifier was: data
RMAN-01007: at line 1 column 9 file: standard input
RMAN-00571: ===========================================================
RMAN-00569: ============ ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-00558: error encountered while parsing input commands
RMAN-01009: syntax error: found ";": expecting one of: "allocate, alter, backup, beginline, blockrecover, catalog, change, connect, copy, convert, create, cross check, configure, duplicate, debug, delete, drop, exit, endinline, flashback, ho st, {, library, list, mount, open, print, quit, recover, register, release, replace, report, renormalize, reset, restore, resync, rman, run, rpctest, set, setlimit, sql, switch, spool, startup, shutdown, send, show, test, transport, upgrade , unregister, validate"
RMAN-01007: at line 1 column 13 file: standard input

RMAN>
RMAN> recover database
2> ;
The command has no syntax errors

Happy New Year to All

Wish You All…Great, Prosperous, Blissful, Healthy, Bright, Delightful, Mind Blowing, sweaty & Energetic, Terrific & Extremely ...happy, very HAPPY NEW YEAR 2011.

We are coming again and expecting the same support which was given earlier.

Friday, January 8, 2010

Spurious entries are seen in the concurrent manager tables

.mgr log shows the following error - CONC-SM TNS FAIL, yet all concurrent requests complete successfully without any error.Ping to FNDSM_node_sid entry is successful
No other problems are being experienced
Cause
The cause of this problem is undetermined.
Solution
To implement the solution, please execute the following steps:1. Run the CMCLEAN.sql script to safely clean up the concurrent manager tables.
N.B. The script can be obtained from Metalink
Note 134007.1 - CMCLEAN.SQL - Non Destructive Script to Clean Concurrent Manager Tables

Tuesday, January 5, 2010

Oracle Workflow Release 12 Diagnostics

Ganeric Workflow Data Collection
Run the script from
Note 275379.1 to determine your current R12/ATG version.
Spool, run and upload the output of $FND_TOP/sql/wfver.sql from your Concurrent Manager Server that is running the Workflow Services.
Workflow Mailer
The Workflow Mailer is a key component of E-Business (EBS). The ability to send emails of many types to customers notifying them of key pieces of information is highly appreciated by all stakeholders that interact with EBS. The Workflow Mailer uses SMTP, IMAP and HTTP protocols for processing notifications by email. Run the Oracle Workflow ATG Support: R12 Java Mailer Setup Diagnostic Test from
Note 748421.1 to do an initial data collection of your Workflow Mailer configuration.
Workflow has been enhanced to provide more diagnostics for EBS Administrators to use to diagnose notification mailer failures as it uses the protocols. The Mailer.class file is provided to collect diagnostic information when the Workflow Mailer uses these protocols.
Command Line Diagnostics:
Testing IMAP Connectivity
source APPS_.env

$AFJVAPRG -classpath $AF_CLASSPATH -Dprotocol=imap \ -Ddbcfile=.dbc \ -Dserver= \ -Dconnect_timeout=120 -Ddebug=Y \ -Daccount= -Dpassword= \ -DdebugMailSession=Y \ oracle.apps.fnd.wf.mailer.Mailer
Example:
Testing default IMAP Port 143:

$AFJVAPRG -classpath $AF_CLASSPATH -Dprotocol=imap \ -Ddbcfile=$FND_SECURE/VIS.dbc \ -Dserver=gggrant2.us.oracle.com \ -Dconnect_timeout=120 -Ddebug=Y \ -Daccount=orlncatst02 -Dpassword=orlncatst02 \ -DdebugMailSession=Y \ oracle.apps.fnd.wf.mailer.Mailer

Testing default IMAPSSL Port 993:

$AFJVAPRG -classpath $AF_CLASSPATH -Dprotocol=imap \ -Ddbcfile=$FND_SECURE/VIS.dbc \-Dport=993 -Dssl=Y \ -Dtruststore=/home/applmgr/.keystore \ -Dserver=gggrant2.us.oracle.com \ -Daccount=orlncatst02 -Dpassword=orlncatst02 \ -Dconnect_timeout=120 -Ddebug=Y \ -DdebugMailSession=Y oracle.apps.fnd.wf.mailer.Mailer

NOTE: Capture the output echo'd to the screen so you can upload it and upload the default "test.log" file the tests will create.
Testing SMTP Connectivity
source APPS_.env

$AFJVAPRG -classpath $AF_CLASSPATH -Dprotocol=smtp \ -Ddbcfile=.dbc \ -Dserver= \ -Dconnect_timeout=120 -Ddebug=Y \ -Daccount= \ -Dpassword= \ -DdebugMailSession=Y \ oracle.apps.fnd.wf.mailer.Mailer
Example:
Testing default SMTP Port 25:

$AFJVAPRG -classpath $AF_CLASSPATH -Dprotocol=smtp \ -Ddbcfile=$FND_SECURE/VIS.dbc \ -Dserver=rgmamersmtp.oraclecorp.com \ -Dconnect_timeout=120 -Ddebug=Y \ -Daccount=NoSmtpUser -Dpassword=NoSmtpPasswd \ -DdebugMailSession=Y \ oracle.apps.fnd.wf.mailer.Mailer

Testing SMTPSSL Port 465:

$AFJVAPRG -classpath $AF_CLASSPATH -Dprotocol=smtp \ -Ddbcfile=$FND_SECURE/aoldev-pc_vis.dbc \ -Dport=465 -Dssl=Y \ -Dtruststore=/home/applmgr/.keystore \ -Dserver=aoldev-pc.us.oracle.com \ -Daccount=NoSmtpUser -Dpassword=NoSmtpPasswd \ -Dconnect_timeout=120 -Ddebug=Y \ -DdebugMailSession=Y oracle.apps.fnd.wf.mailer.Mailer
NOTE: Capture the output echo'd to the screen so you can upload it and upload the default "test.log" file the tests will create.
Testing HTTP Connectivity for notifications with framework message attributes
Example:
NON-SSL TEST: Modify in a text editor to make sure the command is listed on one line as it is one long statement. You need to specify the notification_id (-Dnid) of the failing notification, the protocol (-Dhtp=http), and the dbc filename (-Ddbcfile).
==============Begin garymailertest.sh================= source APPS_.env

$AFJVAPRG -classpath /tmp:
${AF_CLASSPATH} -Dnid=841969 -Ddbcfile=$FND_TOP/secure/orlncatst-02_vis.dbc -Dappuser=0 -Dappresp=20420 -Dappid=1 -Durltimeout=120 -Dhtp=http -DAFLOG_FILENAME=mailerTest.log -DAFLOG_LEVEL=STATEMENT -DAFLOG_ENABLED=true oracle.apps.fnd.wf.mailer.Mailer
=============End garymailertest.sh=====================

SSL TEST:
Modify in a text editor to make sure the command is listed on one line as it is one long statement. You need to specify the notification_id (-Dnid) of the failing notification, the protocol (-Dhtp=https), the name of your and the dbc filename (-Ddbcfile).
==============Begin garymailertestSSL.sh===============


source APPS_.env export LD_LIBRARY_PATH=${AF_LD_LIBRARY_PATH} $AFJVAPRG -classpath $AF_CLASSPATH -Dnid=841969 -Ddbcfile=$FND_TOP/secure/aoldev-pc_vis.dbc -Dappuser=0 -Dappresp=20420 -Dappid=1 -Durltimeout=120 -Dhtp=https -DAFLOG_FILENAME=mailerTest.log -DAFLOG_LEVEL=STATEMENT -DAFLOG_ENABLED=true oracle.apps.fnd.wf.mailer.Mailer
============End garymailertestSSL.sh===============

Java Mailer Diagnostics for HTTP Framework Region Screen Output: Mailer : oracle.apps.fnd.cp.gsc.Logger.Logger(String, int) : Logging to System.out until necessary parameters are retrieved for Logger to be properly started. URL {https://aoldev-pc.us.oracle.com:8443/OA_HTML/OA.jsp?page=/oracle/apps/fnd/wf/worklist/webui/NotifMailerPG&WFRegion=NtfDetail&NtfId=841969&dbc=aoldev-pc_vis&OALAF=blaf&OARF=email} Connection to application server was successful and retrieved 3392 characters plus 4 referenced objects. Time taken to establish the connection and obtain the content was 31.627 seconds Content ID File name and Content Type
========== ========================== 24537094 /OA_HTML/cabo/images/errorl.gif image/gif 5612344 /OA_HTML/cabo/images/cache/cmbte-1.gif image/gif 8344960 /OA_HTML/cabo/images/t.gif image/gif 16625677 /OA_HTML/cabo/images/cache/cmbbn-1.gif image/gif

NOTE: Upload the information echoed to your session and the -DAFLOG_FILENAME=mailerTest.log and "test.log" which contains quite a bit of Statement log level data.

Additional Diagnostics:
Increase the Workflow Mailer's Log Level to Statement in order to get additional diagnostic information for the Workflow Mailer whenever you see issues sending (SMTP) notifications by email and processing (IMAP) responses from the dedicated inbox assigned to the Workflow Mailer.


Changing the Workflow Mailer Log Level:
Login to E-Business as a user assigned the System Administrator responsibility and navigate:
System Administrator > Oracle Applications Manager > Workflow > Notification Mailers > Edit > Advanced
Reproduce the issue and review the Workflow Mailer Service log which is now being written to with the Log Level set to Statement. The log can be viewed in multiple locations from within E-Business and from the file system.
E-Business:
Login to E-Business as a user assigned the System Administrator responsibility and navigate: System Administrator > Oracle Applications Manager > Workflow > Notification Mailers > View Log
OR
System Administrator > Concurrent: Manager > Administer
Select Workflow Mailer Service > Processes > Manager Log
File System:
The Workflow Mailer Service (WFMLRSVC) is a java concurrent manager; therefore, the log is stored in the same location as the other concurrent manager logs on the Concurrent Manager Server node assigned to the Workflow Mailer Service.

$APPLCSF/$APPLLOG is default location. FNDCPGSC.txt is the naming convention of the Workflow Service logs. You can find the concurrent_process_id for the currently active Workflow Mailer Service log using the following query:

set linesize 155;
set pagesize 200;
set verify off;
column MANAGER format a15;
column MEANING format a15; SELECT concurrent_queue_name manager, fcp.last_update_date, fcp.concurrent_process_id pid, meaning, fcp.logfile_name FROM fnd_concurrent_queues fcq, fnd_concurrent_processes fcp, fnd_lookups flkup WHERE concurrent_queue_name in ('WFMLRSVC', 'WFALSNRSVC') AND fcq.concurrent_queue_id = fcp.concurrent_queue_id AND fcq.application_id = fcp.queue_application_id AND flkup.lookup_code=fcp.process_status_code AND lookup_type ='CP_PROCESS_STATUS_CODE' AND meaning='Active';
Currently the Retention Time is set to 0 on the WF_ERROR queue. This causes all events on the queue to be removed by the Advanced Queue Time Manager (aq_tm_process) as soon as all events on the WF_ERROR queue is processed. Set the Retention Time to 1 day so you can easily determine if your notification issue is due to a workflow error.
declare l_wf_schema varchar2(200); lagent sys.aq$_agent; l_new_queue varchar2(30); begin l_wf_schema := wf_core.translate('WF_SCHEMA'); l_new_queue := l_wf_schema'.WF_ERROR'; lagent := sys.aq$_agent('WF_ERROR',null,0); dbms_aqadm.alter_queue(queue_name=> l_new_queue, retention_time => 60*60*24 /* one day in seconds */);

end;
/
commit;

Run $FND_TOP/sql/wfmlrdbg.sql to collect information about a particular notification based on its notification_id (NID). It will spool a wfmlrdbg.html file that can be reviewed for any issues that is preventing a notification from being sent or its response from being processed.
sqlplus apps/ @$FND_TOP/sql/wfmlrdbg.sql
Run $FND_TOP/sql/wfsmrdbg.sql to collect information about sending Summary notifications based on the user which have his notification_preference set to receive a summary of his open notifications. It will spool a wfsmrdbg.html file that can be reviewed for issues preventing the summary notification from being emailed.
sqlplus apps/ @$FND_TOP/sql/wfsmrdbg.sql
Example:
sqlplus apps/apps @$FND_TOP/sql/wfsmrdbg.sql SYSADMIN
Workflow Agent Listeners

Oracle E-Business has evolved to use the latest components of the Oracle Database. One of these components that are used extensively in R12 is Advanced Queuing (AQ) as a core component of Oracle Workflow's Business Event System (BES). Many events loaded into the BES provide core functionality such as for processing notifications by email, XML Gateway transactions, User Maintenance/Administration, and other product specific business logic. These events are processed through our AQ by seeded listeners or by custom listeners. A listener simply pings the queue it is configured to check periodically to see if there are any events enqueued on it that need to be processed or in the case of the mailer for inbound processing, it will check the IMAP user account for any responses in the inbox and enqueue proper responses on the Notification Inbound queue. An event is only raised if there is a subscription assigned to it and the queue used is based on the agent that is assigned to the subscription. Events can be enqueued on our default WF_DEFERRED AQ if the phase on the subscription is greater than 99 for asynchronous processing with or without an agent assigned to the subscription. If the phase is less than or equal to 99, the event is processed synchronously by the agent to which is is assigned. The exception this rule is for Java subscriptions used for middle tier java processing. When a java subscription is assigned to an event, all deferred subscriptions and java subscription are enqueued on the WF_JAVA_DEFERRED queue for asynchronous processing by the Workflow Java Deferred Agent Listener.
Run $FND_TOP/sql/wfbesdbg.sql to collect information about the processing of an event based on the event_name and event_key used when it is raised. It will spool a wfevtdbg.html output file. You may need to rename the in order to be able to review the output in a browser.
Due to the complexity of the naming convention of event keys you must run this diagnostics in this manner to avoid failures.
sqlplus apps/ @$FND_TOP/sql/wfbesdbg.sql
Enter value for 1: Enter value for 2:
Example:
sqlplus apps/apps @$FND_TOP/sql/wfbesdbg.sql Enter value for 1: oracle.apps.fnd.wf.ds.userRole.updated Enter value for 2: PER:25FND_RESP:216672454484:54394

Workflow Directory Services (WFDS)
The Workflow Directory Services infrastructure is used to store workflow user and roles. This has been enhanced to directly store E-Business users and their responsibility assignments. Each Product group store their own data in WFDS table range partitions that is based on the origination of the data. As the providers of the infrastructure used by the product groups, Workflow Support and Development investigate the following potential failure points when determining if the reported issue can be addressed as a workflow infrastructure issue.
User/responsibility assignments are maintained by the business event system. The events are linked to subscriptions that are either synchronous or asynchronous. Asynchronous subscriptions will be enqueued on either the Workflow Deferred (WF_DEFERRED) or on Workflow Java Deferred (WF_JAVA_DEFERRED) AQ.
Run the Workflow Directory Services (WFDS) Data Collection Script in
Note 742062.1 to collect information about an EBS user and their responsibility assignments.
sqlplus apps/
/
$FND_TOP/sql/wfdirchk.sql to obtain a report of potential directory services data problems. Be sure to spool the file to obtain an output for review.
sqlplus apps/
spool wfdirchk.LST
Workflow Purging (WF_PURGE)
WF_PURGE is a workflow server package used to maintain the workflow infrastructure tables containing obsolete runtime data (data generated at the time a workflow process runs) and design time data (workflow design data that is now obsolete due to the workflow design being changed). The Purge Obsolete Workflow Runtime Data concurrent request calls this package to maintain these tables by periodically deleting completed workflow processes from all the tables used to store the meta-data.
Run the WF Purge Data Collection Script in
Note 750497.1 to collect information about the size of the workflow runtime tables and the condition of the workflow processes.
sqlplus apps/

Monday, December 28, 2009

How do you manually regenerate a form in Release 12?

1. Check the FORMS_PATH env variable. Assuming these are US forms the FORMS_PATH should include
$AU_TOP/resource and $AU_TOP/forms/US.

2. To compile a form manually from the command line try either of these two command line arguments (replace FNDFBMAS.fmb with the form of your choice.):

frmcmp.sh module=FNDFBMAS.fmb userid=apps/ module_type=form batch=yes compile_all=yes

frmcmp_batch module=FNDFBMAS.fmb userid=apps/ module_type=form batch=yes compile_all=yes

Tuesday, December 22, 2009

The Function Is Not Available Under The Responsibility

After applying the ATG RUP 7 When attempting to navigate to a function which has been newly added to a menu the following error occurs:

ERROR
The Function Is Not Available Under The Responsibility

STEPS
The issue can be reproduced at will with the following steps:
1. Query menu:

2. Add function: and Save.
3. Verify that the menu compilation request (FNDSCMPI module: Compile Security) completed successfully.
4. Log into e-Business Suite and try to navigate to function: .
5. The error occurs.

This issue is caused by launching the menu item before the Compile Security has completed.

When a function is added to a menu , a concurrent program 'Compile Security' is submitted which loads the data in Fnd_Compiled_Menu_Functions table.

Whenever a function is accessed, security code checks Fnd_Compiled_Menu_Functions table to determine whether that function is accessible under the given security context or not. So if this function is accessed before the 'Compile Security' program is finished, the function cache gets loaded with stale data and the reported error message is thrown.

So after modifying the 2 menu definitions associated with 'System Administrator' and 'Application Developer' make sure that 2 concurrent requests submitted for the above 2 modifications completed normally and then try to access the functions.

Further once this error occurs, it will be cached which means that even after the menu item has been flagged as available, it the error will be returned from the cache.

Solution
-- To implement the solution, please execute the following steps::
1) Manually run the 'Compile Security' concurrent program, set the parameter to YES.
2) Shut down Middle Tier (Apache)
3) Delete the contents of $OA_HTML/_pages directory (11.5.10 only).
4) Restart Middle tier
5) Test the menu item


Wednesday, December 16, 2009

How to recover from a corruption of an object in system tablespace

Table IDL_UB2$ who's owner is SYS got corrupted. This was noticed while trying to compile a package EAM_PROCESS_WO_PVT.

=================================================
SQL> alter package EAM_PROCESS_WO_PVT compile package;
Warning: Package altered with compilation errors.
SQL> show errors;
No errors.
SQL> alter package EAM_PROCESS_WO_PVT compile body;

Warning: Package Body altered with compilation errors.
SQL> show errors;
Errors for PACKAGE BODY EAM_PROCESS_WO_PVT:
LINE/COL ERROR
-------- -----------------------------------------------------------------
0/0 PLS-00801: internal error [phdite:node kind]
9361/5 PL/SQL: SQL Statement ignored
9362/32 PL/SQL: ORA-00604: error occurred at recursive SQL level 1
ORA-01578: ORACLE data block corrupted (file # 2, block # 40099)
ORA-01110: data file 2:
'/u01/oracle/PROD/db/apps_st/data/system02.dbf'
9366/46 PL/SQL: Statement ignored

=================================================

As a first step. we found the object that was in question and its type.

=================================================
SQL> SELECT OWNER, SEGMENT_NAME, SEGMENT_TYPE FROM DBA_EXTENTS
WHERE FILE_ID = 2
AND 40099 BETWEEN BLOCK_ID AND (BLOCK_ID + BLOCKS -1); 2 3
OWNER
------------------------------
SEGMENT_NAME
-------------------------
SEGMENT_TYPE
------------------
SYS
IDL_UB2$
TABLE

=================================================

then performed the following steps:

=================================================
SQL> shutdown immediate
SQL> startup upgrade
SQL> truncate table idl_ub1$;
SQL> truncate table idl_char$;
SQL> truncate table idl_ub2$;
SQL> truncate table idl_sb4$;
SQL> @?/rdbms/admin/utlirp
SQL> shutdown immediate
SQL> startup upgrade
processes to connect to dbs
SQL> @?/javavm/install/rmjvm
SQL> shutdown immediate
SQL> exit <-- important!<<<<<<<<<<<<<<<<SQL> startup upgrade
processes to connect to dbs
SQL> alter system set "_system_trig_enabled"=false scope=memory;
SQL> @?/javavm/install/initjvm.sql
SQL> shutdown immediate
SQL> exit <-- important! <-- important!<<<<<<<<<<<<<<<<SQL> startup upgrade
processes to connect to dbs
SQL> @?/rdbms/admin/utlrp
SQL> shutdown immediate
SQL> startup

=============================================

The corruption was fixed.

Tuesday, December 15, 2009

RMAN cloning using duplicate command

1) Make a copy of the following TARGET directories under
DB Tier:
Archive log backup
Control file backuup
Database full backup
Apps Tier:Apps tech


2) Configure the Oracle Home
Target – Apps/DB

Overwrite the dbs, appsutil, network/admin directories with the previously copied directories.
Rename the $ORACLE_HOME/admin/ PROD_perp to DBA_mperp.


3) Copy the Apps file system to target.
Target-Apps
This can be done along with copying the database Oracle Home files.

4) Edit the init_SID.ora
Add a parameter remote_login_passwordfile=EXCLUSIVE
Add following parameters:db_file_name_convert=('/u02/oracle/PROD/db/apps_st/data','/u02/oracle/DBA/db/apps_st/data') log_file_name_convert=('/u02/oracle/PROD/db/apps_st/data','/u02/oracle/DBA/db/apps_st/data')


5) Create the password file
Target –DB
orapwd file=orapwPROD password=oracle entries=3

6) Target –DB
cd $ORACLE_HOME/appsutil/clone/binperl adcfgclone.pl dbTechStack

7) Startup the target instance in NOMOUNT state.
Target –DB
Startup nomount.

8) Connect to source database in target machine
Source-DB
rman tee restore.log
CONNECT TARGET
rman/****@PROD;

9) Connect to RMAN in the target machine
Target-DB
CONNECT AUXILIARY /;

10) Run the duplicate command
Note: If we don’t use set until then we need to make sure PROD doesn’t generate any archive logs after the restore if it’s generated then it’ll look for it also which is not available with us.

Target-DB
run {
duplicate target database to “DBA”;
}


11) Update the libraries (for both)
Target-DB
cd $ORACLE_HOME/appsutil/install/Context_namesqlplus / as sysdba @adupdlib.sql so

12) Configure the database
Target-DB
cd ora_home/appsutil/clone/binperl adcfgclone.pl dbconfig

13) Once the db tiers are up, clone the apps tier
Target-Apps
cd common_top/clone/binperl adcfgclone appsTier

14) Remove the old $COMMON_TOP/admin/log and out directories to clear out space.
Truncate fnd_concurrent_requests tables

Target-Apps

Is DBVERIFY Detects Corrupt Blocks With Redolog Files or Control Files ?

1)You ran DBVIERY utility on the redo log files or control files
2) DBVERITY is reporting every page as corrupt

Example :
You ran
dbv file=/usr/oracle/redo/logfile1.dbf log blocksize=512
and got following error message

DBVERIFY: Release 9.2.0.3.0 - Production on Thu Jun 10 21:24:25 2004Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.
DBVERIFY - Verification starting :
FILE = /usr/oracle/redo/logfile1.dbf
Page 1 is marked corrupt
***
Corrupt block relative dba: 0x00000001 (file 0, block 1)
Bad header found during dbv:
Data in bad block -
type: 0 format: 0 rdba: 0x00000001
last change scn: 0x0000.1f7fda67 seq: 0x22 flg: 0xcc
consistency value in tail: 0x00000000
check value in block header: 0x920, computed block checksum: 0x0
spare1: 0x2f, spare2: 0x11, spare3: 0x0

DBVERIFY checks are limited to cache-managed blocks (that is, data blocks). Because DBVERIFY is ONLY for use with datafiles, it will NOT work against control files or redo logs

No fix. It is expected behavior with redo log and control files.


How To Run Dbv In Parallel On A Single data file.

To run dbv in parallel on a single datafile. Steps -----
1) Identify the file# and name of the datafile.
2) Identify the number of blocks in the datafile.

3) Determine how many parallel sessions has to be used.
4) Start Parallel dbv sessions.

1) I dentify the file# and name of the datafile.
select * from v$dbfile where name like '%datafile_name%'; (OR) select * from v$dbfile ;
2) Identify the number of blocks in the datafile.

1.A Find Data Block Size
eg: SQL>show parameter db_block_size
NAME TYPE VALUE
----------------------------------- ------- ------
db_block_size integer 8192
1.B Calculate the the number of blocks.
SQL> select BYTES/8192 from v$datafile where FILE#=5;
BYTES/8192
----------
5120
So the file# 5 contains 5120 blocks

3) Determine how many parallel sessions has to be used.
This example shows three parallel sessions.
4) Start Parallel dbv sessions.
$dbv FILE=filename START=1 END=2000
$dbv FILE=filename START=2001 END=3500 $dbv FILE=filename START=3501 (Note:-END defaults to the last block of the file)

How to check to see if a specific Forms patch is applied to your Oracle Applications?

For Oracle Applications 11i forms version 6.0.8.xCheck the readme of the patch. The patch readme will have instructions similar to the following: Backup the Forms class files, %cp -r $ORACLE_HOME/forms60/java/oracle/forms/handler/UICommon.class $ORACLE_HOME/forms60/java/oracle/forms/handler/UICommon.class.PRE_BUG6643292

Look in the directory for something like : PRE_BUG##### to determine if the forms patch has been applied.

For Oracle Applications R12 forms version 10g
Look in the opatch inventory for the patch number. cd $ORACLE_HOME/OPatch export $PATH=`pwd`:${PATH} opatch lsinventory -detail > 1012_inventory.txt check if patch ###### is listed Or you can review the patch readme for similar information as documented above for the 6.0.8.x forms patchsets.

R12: Patch(es) , conflict with the patch currently being installed (PATCH)

You are applying a technologies patch to the R12 Ebusiness Suite 10.1.2.X.X or 10.1.3.X.X home and receive the following message during opatch application. These steps are also relevant for non Ebusiness suite technologies patches as the theory is the same. Conflicting patches: ,
Patch(es) , conflict with the patch currently being installed (PATCH BEING APPLIED).
If you continue, patch(es) , will be rolled back and the new patch (PATCH BEING APPLIED) will be installed.
Note: If the patch currently being installed (PATCH BEING APPLIED) is rolled back, it is recommended that the fixes being rolled back here (, ) are reinstalled.
If a merge of the new patch (PATCH BEING APPLIED) and the conflicting patch(es) , is required, contact Oracle Support Services and request

You are unsure on whether to proceed or quit the patch.
How does one determine if the patch being applied can safely override the existing patch?

When there is such a conflict between and existing patch and the patch being applied you should compare the bugs fixed in both the patches. The conflict arises when a patch being applied contains a file that is also included in another patch manually applied on top of the current installed patchset. As there is no version information the conflicting patch message appears.
Obtain a copy of each patch and compare the 'inventory' file or the 'readme' file. These files contain a list of bugs fixed by each patch. These files exist within the patch zip file. Extract the patch zip to view either of these files
Compare the bugs listed. What you are looking for is to make sure that the patch being applied has all the bugs mentioned that are fixed in the existing patch. In other words, before rolling back the existing patch you want to make sure the bugs it fixes are included in the new patch being applied.
If all the patches listed in the existing patch are included in the patch being applied you can safely continue the patch.
In some cases the patch being applied may not contain all the bug fixes that are included with the existing patch. If you do not require the missing patches you can safely continue patch application.
If you do require the patches then you should stop the patch application and log a service request with Oracle Support requesting a "Merge Label Request, MLR" of the existing patch and the patch being applied.

Where To Download The BI Publisher Desktop for Windows? (Template Builder)

The latest version of BI Publisher Desktop for Windowsis available here: http://www.oracle.com/technology/software/products/publishing/index.html

How to start the Output Post Processor (OPP)?

The OPP is not started by default.It needs to be activated when BI Publisher is setup.

To activate the OPP please do this:
The Profile Option "Concurrent: GSM Enabled" must be set to Y
Then:
1. Login to Apps with sysadmin responsibility
2. Navigate to: Concurrent -> Managers -> Define
3. Query for Manager = 'Output Post Processor'or Short Name = FNDCPOPP
4. Check the checkbox "Enable" .
5. Click on 'Work Shifts button
6. see Work Shift of the OPP and
Set
Processes = 1
and
Parameters = oracle.apps.fnd.cp.opp.OPPServiceThread:2:0:max_threads=5
and
Sleep Second = 30
7. Save
8. Navigate to:_ Concurrent -> Managers -> Administer
9. Make sure the Output Post Processor Status is not 'Deactivate'Set Status to 'Activate' if necessary.
10. Stop and Start the Concurrent Managers using
adcmctl.sh

Friday, December 11, 2009

Gather Schema errors out with ORA-20005:

When running gather schema statistics, the following error occurs.
Error #1: ERROR: While GATHER_TABLE_STATS: object_name=APPLSYS.AQ$_WF_CONTROL_P***ORA-20005: object statistics are locked (stattype = ALL)***
Error #2: ERROR: While GATHER_TABLE_STATS: object_name=APPLSYS.FND_CP_GSM_IPC_AQTBL***ORA-20005: object statistics are locked (stattype = ALL)***
Error #3: ERROR: While GATHER_TABLE_STATS: object_name=APPLSYS.FND_CP_GSM_OPP_AQTBL***ORA-20005: object statistics are locked (stattype = ALL)***
Error #4: ERROR: While GATHER_TABLE_STATS: object_name=APPLSYS.FND_CP_TM_AQTBL***ORA-20005: object statistics are locked (stattype = ALL)***
Error #5: ERROR: While GATHER_TABLE_STATS: object_name=APPLSYS.FND_CP_TM_RET_AQTBL***ORA-20005: object statistics are locked (stattype = ALL)***
Error #6: ERROR: While GATHER_TABLE_STATS: object_name=APPLSYS.WF_SMTP_O_1_TABLE***ORA-20005: object statistics are locked (stattype = ALL)***

This can happen with Advance Queue tables.
In 10g, if a queue is created or recreated during the upgrade, automatic statistics gather is locked (disabled) on these queue.


The following statement can be used to check the tables which have statistics locked:

select owner, table_name, stattype_locked from dba_tab_statistics where stattype_locked is not null;

Unlock statistics gathering on those queues running the commands below.
- To unlock all the tables in a schema at once:

exec dbms_stats.unlock_schema_stats('schema_owner');
OR
To unlock individual tables (need to run for all tables individually):
exec dbms_stats.unlock_table_stats('table_owner','table_name');

Examples:
SQL> exec dbms_stats.unlock_schema_stats ('AR');

SQL> exec dbms_stats.unlock_table_stats('AR', 'AR_REV_REC_QT');

Friday, November 6, 2009

How to relink all binaries after a OS Upgrade to ensure that everything is working as expected on a Release 11i or a Release 12 Installation on Unix ?

To get everything relinked and to ensure that the adadmin Utility was relinked before it is used, follow these steps :

Release 11i (Autoconfig enabled) :

Technology Stack Binaries inclusive Database :

Source the RDBMS ORACLE_HOME Environment
Execute the script $ORACLE_HOME/appsutil/install/adlnkoh.sh
Source the iAS ORACLE_HOME Envrionment
Execute the script $ORACLE_HOME/bin/adlnkiAS.sh
Source the APPS Environment
Execute the script $ORACLE_HOME/bin/adlnk806.sh


Oracle E-Business-Suite Binaries :
1. Source the APPS Environment

2. Execute following command :
adrelink.sh force=y "ad adadmin"
If you are using the command
adrelink.sh force=y "ad all"you are relinking all binaries under the $AD_TOP/bin - otherwise the AD Utilities are relinked via the adadmin Utility.


3. Execute adadmin
select --> '2. Maintain Applications Files menu'

select --> '1. Relink Applications programs'
--> select all modules to relink

Before starting the Instance, please open a new shell and source the Environment.
Release 12 :


Technology Stack Binaries inclusive Database :

Source the RDBMS ORACLE_HOME Environment
Execute the script $ORACLE_HOME/appsutil/clone/adlnkoh.sh
Source the APPS Envrionment
Execute the script $IAS_ORACLE_HOME/appsutil/clone/adlnkweboh.sh
Source the APPS Environment
Execute the script $ORACLE_HOME/appsutil/clone/adlnktools.sh


Oracle E-Business-Suite Binaries :

1. Source the APPS Environment

2. Execute following command
adrelink.sh force=y "ad adadmin"


If you are using the command
adrelink.sh force=y "ad all"


you are relinking all binaries under the $AD_TOP/bin - otherwise the AD Utilities are relinked via the adadmin Utility.

3. Execute adadmin
select --> '2. Maintain Applications Files menu'

select --> '1. Relink Applications programs'
--> select all modules to relink

Before starting the Instance, please open a new shell and source the Environment.

Tuesday, October 27, 2009

Requests Stuck with Inactive No Manager - Routine AFPESA Cannot Construct the Name of an Executable File

All the Concurrent Requests are showing up with Phase Inactive and Status No Manager.
The Standard Manager is not able to process any request because each manager process dies immediately after starting up. The log file of the manager process shows the following error:

List of errors encountered:
.............................................................................
_ 1 _Routine AFPESA cannot construct the name of an executable file foryour concurrent request 2181143.

Check that the file name components are correct and valid on yoursystem. Check that the environment for the person who started the conc
.............................................................................

The problem typically occurs on a cloned environment that has been created.

Cause

The problem is due to an incorrect environment setup. The custom PROD_TOP is not defined in the environment files.
Solution

Any custom product_top needs to be defined correctly in the Context File. The following extract describes how to add a custom product_top to the Context File by using Oracle Applications Manager:

Creating a customer owned AutoConfig template file
You can create an AutoConfig template file of your own. This will enable you to develop custom applications that AutoConfig configures and maintains.
Perform the following tasks in the order listed:

Define a product_top

Use the Oracle Applications Manager Context Editor to add your custom product_top to the context file. Refer to the Help pages available on your Oracle Applications Manager site. The relevant information for adding custom context variables is located in the "System Configuration" -> "AutoConfig" -> "Custom Parameters" section. Choose the variable type "PRODUCT_TOP" when adding the product_top variable.

For example, define "MY_TOP" as your product_top as follows:

OA_VAR = MY_TOP
Default Value = %s_at%/my/11.5.0
Title = My Product top
Description = This is my product top
OA_TYPE = PROD_TOP

Note: You must have Oracle Applications Manager (OAM) H or higher installed to manage custom variables. Refer to Oracle Applications Manager 11i Availability for instructions on installing OAM.
AutoConfig needs be run after adding the custom product_top to the Context File.
Alternatively, a product_top can added manually to the environment file instead of defining it in the Context File.

Wednesday, October 21, 2009

RMAN does not display the output

If you specify the LOG option at the command line, then RMAN displays command input but does not display the RMAN output.
The easiest way to send RMAN output both to a log file and to standard output is to use the UNIX tee command or its equivalent on another operating system.
For example:
% rman tee rman.log
RMAN>


SQL> select * from dual where 1=0;
no rows selected
SQL>

I found a good one by using NOT EXISTS clause

SQL> select * from dual where 1=0
UNION
select 'no data found' from dual where not exists (select * from dual where 1=0);
DUMMY
no data found
1 row selected.
SQL>


In this way, both input and output are visible within the RMAN command-line interface.

Tuesday, October 6, 2009

Quick Pay Fails With Error Assertion failure detected at location py3vntsetup:1a

The Quick Pay process errors with 'Assertion failure detected at location py3vntsetup:1a'. Additional errors in the log file show "Library error: libqutil.so: cannot open shared object file: No such file or directory".

cause:
The parameter LD_LIBRARY_PATH is not setup correctly.

-- To implement the solution, please execute the following steps::

1.Modify the file $APPL_TOP/admin/adovars.env to include the complete pathof $PAY_TOP/vendor/quantum/lib as the first entry for LD_LIBRARY_PATH.If PY_LIB_PATH is set in the adovars.env file, Payroll application will no longer use LD_LIBRARY_PATH if PY_LIB_PATH is defined in the instance. Therefore, ensure that the PY_LIB_PATH path should always have the LD_LIBRARY_PATH included in it.

2. Bounce the concurrent managers.

3. Test Quick Pay.

Thursday, September 24, 2009

Configuring smtp in Linux

Configuring smtp in Linux

1. Ask mail administrator to add the linux server from which we need to send mail to mail server

2. comment out following line in /etc/mail/sendmail.mc

dnl This changes sendmail to only listen on the loopback device 127.0.0.1
dnl and not on any other network devices. Comment this out if you want
dnl to accept email over the network.

dnl DAEMON_OPTIONS(`Port=smtp,Addr=127.0.0.1, Name=MTA')

3. Compile the changes we made,

m4 /etc/mail/sendmail.mc > /etc/mail/sendmail.cf

4. Start the sendmail service

service sendmail start

5. Test the mail using the following,

echo "Hello World" mail -s "Test from NG Monitor"
jayakumar@newgenusa.com

6. The mail status can be checked through the following command
mail queue