Thursday 29 May 2014

REP-0501: Unable to connect to the specified database


Issue:












As found from log file:
REP-0501: Unable to connect to the specified database.
ORA-01017: invalid username/password; logon denied

Root Cause:  issue after attempting to re-install Object Migrator on EBS instance and sometimes for some patches like 12964564 ,13855823 oracle application patch.

Solution: 
solution was to apply patch 16946854.
because , patch describes as below details,
=========================================
This patch only affects customer who are using data groups with custom schemas
attached to a responsibility for request submission.

In this case, the patch is necessary to successfully decrypt the password for
the oracle id associated with the custom schema.

Please restart the managers after applying this patch.
=============================================
Bugs Fixed
The following bugs are fixed by this patch:

16946854 - REQUEST SUBMITTED BY CUSTOM RESP AND CUSTOM DATA GROUP CAUSES FNDLIBR TO COREDUM
and moreover below bugs being fixed by this patch,

Bugs Resolved by This Patch
10010001POSSIBLE FND IMPACT FOR MIXED CASE APPLSYSPUB OR GWYUID PASSWORD
1013898611G PASSWORD CASE SENSITIVITY PROJECT CONSOLIDATION BUG
1293767010138986: 11G PASSWORD CASE SENSITIVITY PROJECT CONSOLIDATION BUG
12960628QRE1220.11:GSI:FAILED - LOGIN PAGE NOT LAUNCHING AFTER 12.2 UPGRADE
1296456412937670: 10138986: 11G PASSWORD CASE SENSITIVITY PROJECT CONSOLIDATION BUG
13407954FNDCPASS: REGRESSION OF PASSWORD PROMPTING FEATURE
16946854REQUEST SUBMITTED BY CUSTOM RESP AND CUSTOM DATA GROUP CAUSES FNDLIBR TO COREDUM
2850079SYSTEM HOLD FOR SERVICE PROCESSES.
7595328R:ICM IS DOWN IN ATG121D7.PLEASE BRING IT UP
9505793ACTIVE DATA GUARD SUPPORT: CONCURRENT MANAGER
Try it hopefully it will take you ahead ..... :)















WebLogic Startup fails with Unable to obtain lock on Server may already be running

Issue : When weblogic server starting showing error "Unable to obtain lock" .
Root Cause: previous session has not been terminated cause <servername>.lok file exists

Solution:
-Go to>> $DOMAIN_HOME/servers/<servername>/tmp/
  Check <servername>.lok file exists in this location.
-Delete this <servername>.lok file and start admin server ,it will overcome the error ...

Note-this solution applicable for all managed server as well..

Thursday 22 May 2014

weblogic domain target configuration in OEM 12c

Middleware target configuration  in OEM 12c
In OEM console go to>>setup >>add target>>configure auto discovery






sql server plugin deployment on OEM 12c

Sql server plugin deployment :

Go to setup>>extensibility >>plug-in>>database>>sql server>>rightclick on plugin for optiondeploy then screen will come  as cited below,





















Clone Oracle Apps R12 Short Steps

Clone Oracle Apps R12 Short Steps



Pre-Clone Steps:
On the DB server:
· cd $ORACLE_HOME/appsutil/scripts/
· perl adpreclone.pl dbTier
· Check the log file under
· $ORACLE_HOME/appsutil/log//StageDBTier_06201503.log
On the apps tier server:
· cd $ADMIN_SCRIPTS_HOME
· perl adpreclone.pl appsTier
· Check the log file $APPL_TOP/admin/log/
Clone Steps:
Copy the source apps tier file system to the target system.
· APPL_TOP.
· COMMON_TOP
· ORACLEAS_10.1.2_ORACLE_HOME
· ORACLEAS_10.1.3_ORACLE_HOME
Copy source system database tier file system to the target system. As user oracle:
· Shutdown normal the source system database.
· Copy the database (.dbf) files plus ORACLE_HOME to the target system.
On the target Database system
· cd $ORACLE_HOME/appsutil/clone/bin
· perl adcfgclone.pl dbTier
· Verify errors the log $ORACLE_HOME/appsutil/log/
On the target apps system
· $cd $COMMON_TOP/clone/bin
· $perl adcfgclone.pl appsTier
· Verify the errors the log. $APPL_TOP/admin//log

· Once clone is finished. If you have customized environment then change post clone profile options, utl_file_dir etc.

database target configuration on OEM

Inorder to add new Db hosts and instance to OEM follow the below steps:

And keep agent as source OEM agent , in my case it was 164 machine (hostname:optimebs64.estuate) and agent is residing on same machine and we just have to add database instance which will be monitoring by OEM on OEM installed machine.
                                                                                                                                                                    
    

















        















select agent it will add database instance as database target on OEM console ...        



OEM server reconfiguration after statis IP change

OEM_server_issue _ after static IP change:

Step-1 Changes  ip address in /etc/hosts file as root user
Step-2 restarted oms from backend with command :
./emctl stop oms
And again ./emctl start oms
Step-3 restart agent with command :
./emctl stop agent

And again ./emctl start agent

target status is pending on OEM CONSOLE

Issue: FROM oeM CONSOLE  target status is pending .
Solution:increased job_queue_process to 20 in target db and restarted OMS services and restarted agent .
OMS and agent in  machine1 and  DB in machine2.
Sol:
SQL> alter system set job_queue_processes=20;

System altered.

SQL> sho parameter job_queue_processes;

NAME                                 TYPE        VALUE
------------------------------------ ----------- ------------------------------
job_queue_processes                  integer     20
SQL>
Then come to OMS installed machine and restart oms on $OMS_HOME/bin
./emctl  stop oms
Ans then
./emctl  start oms.
And then restart agent  go to >$AGENT_HOME/bin
./emctl  stop agent
Then

./emctl  start agent

ORA-03113_endof_file_in_communication



















Microsoft Windows 2000 [Version 5.00.2195]
(C) Copyright 1985-2000 Microsoft Corp.

C:\Documents and Settings\SADMIN>set ORACLE_SID=siebeldb

C:\Documents and Settings\SADMIN>sqlplus

SQL*Plus: Release 10.2.0.1.0 - Production on Wed May 15 06:46:44 2013

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

Enter user-name: / as sysdba
Connected to an idle instance.

SQL> startup
ORA-03113: end-of-file on communication channel
SQL> startup pfile='D:\ora10\dbs\initSIEBELDB.ora'
ORA-24324: service handle not initialized
ORA-01041: internal error. hostdef extension doesn't exist
SQL> exit
Disconnected

IT happened because of background process not being started because in initSIEBELDB.ora file the path fore udump,adump,cdump mismatched .
So changed in that file and started database with this file.

C:\Documents and Settings\SADMIN>echo %ORACLE_HOME%
D:\ora10

C:\Documents and Settings\SADMIN>echo %PATH%
d:\ora10\BIN;D:\ora10\NETWORK\tools;D:\ora10\jre\1.4.2\bin\client;D:\ora10\jre\1
.4.2\bin;D:\ora10\NETWORK\ADMIN;C:\WINNT\system32;C:\WINNT;C:\WINNT\System32\Wbe
m;C:\Program Files\Executive Software\DiskeeperLite\

C:\Documents and Settings\SADMIN>set ORACLE_SID=siebeldb

C:\Documents and Settings\SADMIN>sqlplus

SQL*Plus: Release 10.2.0.1.0 - Production on Wed May 15 06:49:05 2013

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

Enter user-name: / as sysdba
Connected to an idle instance.


SQL> startup pfile='D:\ora10\database\initSIEBELDB.ora'
ORACLE instance started.

Total System Global Area 1073741824 bytes
Fixed Size                  1253096 bytes
Variable Size             264241432 bytes
Database Buffers          805306368 bytes
Redo Buffers                2940928 bytes
Database mounted.
Database opened.



SQL> create spfile='D:\ora10\database\SPFILESIEBELDB.ora' from pfile='D:\ora10\database\in
itSIEBELDB.ora'
  2  ;

File created.

SQL> startup
ORA-01081: cannot start already-running ORACLE - shut it down first
SQL> shutdown immediate
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL> startup
ORACLE instance started.

Total System Global Area 1073741824 bytes
Fixed Size                  1253096 bytes
Variable Size             264241432 bytes
Database Buffers          805306368 bytes
Redo Buffers                2940928 bytes
Database mounted.
Database opened.

SQL>

internal manager and all manager shows actual=1 and target=1 AND OTHER ARE ACTUAL=0 TARGET=0

REF:MOS  ID 555081.1






















Issue: when internal manager and all manager shows actual=1 and target=1 AND OTHER ARE ACTUAL=0 TARGET=0

 SOLUTION FOR THIS ISSUE:
Step1:stop application services  ./adstpall.sh apps/apps
step2: sqlplus apps/apps
update apps.fnd_concurrent_queues set node_name = 'OPTIMEBS26' where node_name is NULL;
           update fnd_concurrent_queues set TARGET_NODE='OPTIMEBS26' where TARGET_NODE is NULL;

step3:  EXEC FND_CONC_CLONE.SETUP_CLEAN;
             COMMIT;
            EXIT;
          commit;
step4: Ran cmclean.sql by loging database with apps/apps user.

Step5: LAST STEP: RUN AUTO CONFIG ON APPLICATION TIER
If still not resolving then try below:
Stop application services again and run below command as DB user as “apps”.
UPDATE fnd_concurrent_queues set target_node = 'OPTIMEBS64';
UPDATE fnd_concurrent_queues set node_name = 'OPTIMEBS64';
Check all target and node with below commands :
select control_code,target_node,node_name,CONCURRENT_QUEUE_NAME from fnd_concurrent_queues;
EXEC FND_CONC_CLONE.SETUP_CLEAN;
             COMMIT;
            EXIT;
          commit;
and start application services .

Steps in Applying a Patch - Oracle Apps 11i

Steps in Applying a Patch - Oracle Apps 11i


.
Here are basic steps that are performed in patching :

STEP 1 :Before applying a patch you must check whether the patch is already there or not. For this we query the database:
*sqlplus apps/<apps password>@<tnsalias>   then
select * from AD_BUGS where bug_number=’<patch number>’

STEP 2 : Download the patch.
*login to oracle metalink.(www.metalink.oracle.com)
*Select the patches option then select the search type.
*Query for patch by writing the patch no. & platform on which you want to download the patch.
*Click download .
If you have downloaded the patch at desktop then move it to directory where you want it to unzip.
mv <patch.zip> <destination patch directory>
eg:  mv p4003579_linux.zip /u1/apps/patch

STEP 3 :Unzip the patch. For this
*log in as application tier user.
*Go to the directory where you have your patch directory & type command-
unzip patch.zip
This will unzip the patch in current directory & will make the required patch directories & sub directories.

STEP 4 :Enable the Maintenance Mode.For This:
*Set the environment file located in APPL_TOP.
*Run the ad administration utility by typing adadmin on unix/linux console. It will ask questions related to admin utility with default answers in brackets.Then it shows following options & ask for the choice:

1.Generate applications file menu.
2.Maintain applications file menu.
3.Compile/Reload Applications Database Entities Menu.
4.Maintain Applications Database Entities Menu.
5.Change Maintenance Mode.
6.Exit ad Administration.
Select option 5. The status of maintenance mode is displayed at the top of change maintenance mode menu.Again it will show following options & ask for choice:
1.Enable Maintenance mode.
2.Disable Maintenance mode.
3.Return to Main Menu.
Select option 1. Then return to console.

STEP 5: Run autopatch from the patch directory by entering the following command:

$ adpatch

After this answer the questions of autopatch. As autopatch finishes its tasks, it writes timing information to the AD timing report for jobs running in parallel (if any ) and reminds you to run the log files for any errors.
If you don’t see the “autopatch is complete” message at the end of the Autopatch log file, Autopatch did not complete successfully.
The most important step after autopatch completes is to check the log files for any errors that may occurred during the patching process. Check the main Autopatch log file first,then additional log files as necessary.
The default name of main autopatch log file is adpatch.log .The file is located in

$APPL_TOP/admin/<SID>/logQuestion for readers :
What is lgi file in log location (above directory)

STEP 6: Enable the Maintenance Mode.For This:
*Set the environment file located in APPL_TOP.
*Run the ad administration utility by typing adadmin on unix/linux console. It will ask questions related to admin utility with default answers in brackets.Then it shows following options & ask for the choice:

1.Generate applications file menu.
2.Maintain applications file menu.
3.Compile/Reload Applications Database Entities Menu.
4.Maintain Applications Database Entities Menu.
5.Change Maintenance Mode.
6.Exit ad Administration.
Select option 5. The status of maintenance mode is displayed at the top of change maintenance mode menu.Again it will show following options & ask for choice:
1.Enable Maintenance mode.
2.Disable Maintenance mode.
3.Return to Main Menu.
Select option 2. Then return to console.

STEP 7: start all application service

HOw to apply patch without putting maintenance mode:
APPS - how to apply patch HOT (without enabling maintenance mode)

Use the following option when calling adpatch:

   options=hotpatch

EXAMPLE:

   adpatch defaultsfile=/u02/app/applmgr/11.5/admin/SIDNAME/def.txt \
        logfile=all_5162862.log \
        patchtop=/copy/APPS_PATCHES/2006/002/5162862 \
        driver=u5162862.drv \
        workers=4 \
        interactive=yes \
        options=novalidate,hotpatch

In the above example we will:
   apply patch# 5162862
   using u5162862.drv driver
   using 4 workers
   in interactive mode
   without validating pre-reqs
   without enabling maintenance mode (hotpatch)

Oracle Application Login/Logout Flow

Oracle Application Login/Logout Flow. Basic Understanding.

Login Flow - Things happen once user submits URL in browser to login to Oracle Applications

1) User enters a URL in web browser say http:\\localhost.localdomainhttp://www.reachdba.com/images/smilies/tongue.pngor(WebServer Listener port) and clicks Go.
i) These request are recorded into access_logs under Apache Web Server ($IAS_ORACLE_HOME/Apache/Apache/logs/access_%)

2) Webserver checks that with http header request if there is a cookie attached (Cookie is message given by WebServer to Web Browser to identify that if user is logging in first time.

3) Apache Server then Displays the Oracle Applications Rapid Install Portal Page.
- User clicks on Oracle Apps Login Links > E-Business suite Home Page.
- This request is forwarded by Apache to Jserv.
- Jserv sends it to AppsLogin servlet.
- AppsLogin servlet detects the login mode by reading the "Applications SSO type" profile option for current E-Business suite Release 11i instance and
redirects it to the appropriate login page.(SSO, SSWA or any others).

4) User enters the Username/Password in login page and clicks submit button.

5) WebServer needs to check if the username and passwords is authenticated against database FND_USER table.
For this it needs a user to check the client's Username password in database. So GUEST/ORACLE is the user it uses to
authenticate the client's username/password against FND_USERS table.

6) Once user is authenticated its check against FND_RESPONSBILITY% for authorization about users responsibilities & all the assigned
responsibilities are populated to user. and from here onwards user has entered into the application to perform his routine operations.

How choice of responsibility catered?

- Responsibilities are of two type
(1) Self Services (served by Jserv/Servlets)
(2)Core Applications (Server by Forms Server)


- If this is Core responsibility , Apache transfers request to Forms Listener. From here request is on Sockets or forms servlets depending
on forms config. from here onwards Client talks directly with Forms Server in forms session and if Client requests some data, forms server makes database connection using dbc (Database Connector file) in FND_SECURE_TOP.

- But if User Selects Self Service Responsibility like iProcurement, iRecruitement then Apache forwards request to mod_jserv and request
is catered by jserv_component.


If anybody know more on this please share your views. I'll post Logout flow in next post. 

adpatch apply Patch: 9335882:R12.INV.B

APPLYING Patch: 9335882
[Document ID: 1478830.1]
[Patch: 9335882:R12.INV.B]
THIS PATCH PROVIDES AN API TO CREATE UOM CONVERSION introduces this functionality.
Step-1: Login to EBS server using putty as applmgr user
Step-2: Move to patch directory by executing
cd /u01/PATCH_TOP
Step-3: Unzip the zip folder “p9335882_R12.INV.B_R12_GENERIC” by executing
                unzip p9335882_R12.INV.B_R12_GENERIC
 It will create one directory “9335882” which will be used as default directory of patch.
Step-4: Export the patch directory path by executing
                export PATCH_TOP=/u01/PATCH_TOP
Step-5: Move to APPL_TOP directory by executing :
cd /u01/applmgr/ESTSOA/apps/apps_st/appl
Step-6: Source that application environmental file(.env file) by executing:
. APPSESTSOA_soaebs131.env
Step-7: Bounce the EBS server, move to $ADMIN_SCRIPTS_HOME , by executing 
cd $ADMIN_SCRIPTS_HOME and execute the below command to stop the services :
adstpall.sh apps/apps
Step-8: Enable Maintenance mode by below command,
$>adadmin
 And follow the prompt.
a.       Is this the correct APPL_TOP [Yes] à Yes
b.      Filename [adadmin.log]:  adadmin.log
c.       Do you wish to activate this feature [No] ? Yes
d.      Please enter the email id(s) (separated by a space) that notifications should be
e.      sent to [applmgr] : xyz@abcd.com
f.        Please enter the batch size [1000] : 1000
g.       Is this the correct database [Yes]? Yes
h.      Enter the password for your 'SYSTEM' ORACLE schema: manager
i.         Enter the ORACLE password of Application Object Library [APPS] : apps
j.        Enter your choice [6] : 5
Note: - 5 is for Change Maintenance Mode
k.       Enter your choice [3] : 1
Note: - 1 is for Enable Maintenance Mode
Press enter
l.         Enter your choice [3] : 3
Note: - 3 for Return to Main Menu
m.    Enter your choice [6] : 6
Note: - 6 for Exit AD Administration
Step-9: Move to patch directory by executing   
cd /u01/PATCH_TOP/9335882
Step-10: Put adpatch command to apply patch,
Follow the prompts and provide the values as detailed above in step(8) a-i
Again it will ask for some prompt values, provide as shown below.
Default directory: /u01/PATCH_TOP/9335882
Worker=4
Driver=u9335882.drv

After giving above values the Patch completion will show u as cited below,













Step -11: When patch apply finished up disable server maintenance mode  by executing
adadmin
It will again prompt for certain values such as:
a.       Is this the correct APPL_TOP [Yes] à Yes
b.      Filename [adadmin.log]:  adadmin.log
c.       Do you wish to activate this feature [No] ? Yes
d.      Please enter the email id(s) (separated by a space) that notifications should be
e.      sent to [applmgr] : xyz@abcd.com
f.        Please enter the batch size [1000] : 1000
g.       Is this the correct database [Yes]? Yes
h.      Enter the password for your 'SYSTEM' ORACLE schema: manager
i.         Enter the ORACLE password of Application Object Library [APPS] : apps
j.        Enter your choice [6] : 5
Note: - 5 is for Change Maintenance Mode
k.       Enter your choice [3] : 2
Note: - 1 is for Disable Maintenance Mode
Press enter
l.         Enter your choice [3] : 3
Note: - 3 for Return to Main Menu
m.    Enter your choice [6] : 6
Note: - 6 for Exit AD Administration

Step-12: Move to  ADMIN_SCRIPTS_HOME directory by executing:
cd $ADMIN_SCRIPTS_HOME
Step-12:  Restart the EBS services by executing 
./adstrtal.sh apps/apps