Saturday, 1 September 2018

ORACLE APPS DBA INTERVIEW QUESTIONS AND ANSWERS ON 31stAug2018

Hey DBA-Mates,
We are back again with some real time interviews Questions and Answers which are asked by DBA in one of top MNC Companies.
We can’t say they will ask the same questions because interviewers always changed. This is only for some ideas and references for interviews which may useful for you all here.

Note: These questions are for experienced Oracle Apps DBAs.

1. Introduction about your experiences.

2. Application Patching steps in R12.1.3.

Click here for Steps...

3. What is DB link and how to create it.

Click here for Steps...

4. What is SRVCTL.

Work-around:
srvctl  status instance -d <DB_name> -i <instance1>, <instance2>
srvctl status database -d <DB_name>
srvctl stop database -d <DB_name> -o immediate
srvctl start instance -d <DB_name> -i <instance_name>

We tried to categorized which easy to understand.
Fore more Help Click here

5. How to recover a table from full Database backup.

Work-around:
Either from FRA if enabled or from database backup(incomplete recovery) or export / import from clone instance.

6. How to recover a dropped table.

Work-around:
Either from FRA if enabled or from database backup(incomplete recovery) or export / import from clone instance.

7. What is ora-504.

8. what to do for timeout error in OPP.

9. What is difference between R12.1.3 and R12.2 patching process.

10. What is cleanup phase.

11. Can we use adpatch in R12.2.

Answer:
We use ADOP phases in R12.2, we can't use adpatch in R12.2 even though ADOP internally call adpatch.

12. Whats are the phases in R12.2.

Main phases are PAFCC i.e 
Prepare phase, 
Apply phase, 
Finalize phase, 
Cutover phase and 
Cleanup phase.

Also FS_clone, abort etc...

13. How to import a single table  from 4 tables dump file.

14. How to compile JSP manually.

Please check here: Steps to Compile JSP manually

15. How to Apply patch in RAC.

Work-around:
We can use Rolling process. i.e. stop one instance then apply patch then start it, 2nd again stop another instance , apply patch and start instance. etc...

16. How to apply Database patch.
Using Opatch . Please check here DATABASE OPATCH...

17. What is napply option.

Answer:
Opatch napply command to apply multiple patches to an Oracle Fusion Middleware Oracle home.

18. How to check database configurations.

19. What to do for long running program in R12.1.3.

20 How can we rollback apps patches.

If it is not mentioned in Readme.html then not possible to revert back the fully applied patch. Partially we can try as per my knowledge.

21. Why we use Rman duplicate , why not restore and recover manually.

22. How check FRA is enabled or not.

sqlplus '/ as sysdba'
SQL> select flashback_on from v$database;

We will keep post or update the Answers for these Questions. Please you all also requested to update/provide answers in comment box which will be useful to all us.

Some more important links:
Regards,
ora-data Team

Wednesday, 22 August 2018

oracle apps dba interview questions and answers for experienced asked Top MNC company

Hi DBA-Mates,
Today we got these Questions which is asked in Interviews one of the top MNC.
We should not tell the company name here which may raise any concerns. Leave it, we should not worry about that all...

Here, we would like to request you all DBAs, please provide the Answers in Comment box and after reviewing we will provide below the Questions.

We can give here easily all the Answers but we want you guys to do some homework for better understanding and learning, really it work personally.

Question: Hi, How are you?
Answer: Hello, I'm doing well. How are you? [This may different, depends person to person]

Question: 1. Can you please briefly introduce about your experiences. 
Answer : [Best Answer in 10-20 lines, how to start is the main steps.]

Question: 2. How you scale yourself for APPS DBA and Core DBA.
Answer : [As per your skill and knowledge but always keep above 60% -- as per our expert and advice]

Question: 3. Suppose we are applying the patch and got failed due to some tablespace full, how you will take care?

Question: 4. what are the types of patching?
Answer: There are main 4 different types of patches
One-off patch
Mini pack Patch
Family pack patch
Maintenance pack patch
NLS Patch – For Languages patches like English, French, Japanese etc…

Note (Quick-Reference):
few one off patch = mini pack ,
few mini pack / family bundeled = family pack
all family pack fixed = Maintenance pack 

Question: 5. Have you applied HRMS patches?


Question: 7. what are the Patching options in R12.1.3?

Question: 8. why we use ADCTRL?

Answer: ADCTRL concepts and details with example



Question: 11. Can we enable maintenance mode if our Application is running?
Answer: Yes

Question: 12. What are the High level Cloning Steps?
Answer : Step by Cloning EBS with clear Steps as per real time scenario

Question: 13. What does Adpreclone on APPS Tier?

Question: 14. How Autoconfig works and why we run?

Question: 15. If customers are complaining that a program is running for Long 
time, what you need to take actions?

Question: 16. Why and when we need to run GSS?

Question: 17. Suppose customers are complaining that only one module (example - GL) forms are opening slowly, what we need to check and troubleshoot for this?

Question: 18. Suppose CRM is down then what will happen and what to do?

Question: 19. If CRM is down then who will work for CRM? Which Concurrent Manager will act like CRM?

Question: 20. If status of a program is in Pending and Standby, what it means and what you will do?

Question: 21. Have you worked on PCP? Do you know setup for PCP?

Question: 22. Have you done SSO setup?

Question: 23. What are the parameters asked during applying apps patch? [Unnecessary questions asked by them lol hhhh]

Question: 24. If the concurrent program is running for long time, can we enable trace and how?

Some more important Links:
Regards,
ora-data Team

Monday, 30 July 2018

Oracle error -29548: ORA-29548 Solution (FNDCPASS Error)

Hey DBA-Mates,
Hope you all are doing Great in success life…
Friends, we faced this issue while changing the APPS password in R12.1.3 through FNDCPASS.
We are not sure, have you guys have faced this issue or not but hope this may useful here if anyone face this issue in future. As we have searched in Google or metalink and we hit many pages but didn’t worked for us. After that we decided to share with you all.
Please find the below details as per Real scenario:

$ . ./ora-data.blogspot.com.env

$ echo $TWO_TASK
ORA-DATA

1. Changing APPS password:

$ FNDCPASS apps/<prod_apps_password> 0 Y system/dev0dba SYSTEM APPLSYS <test_apps_password>

Log filename : L2230661.log
Report filename : O2230661.out

2. Changing SYSADMIN password:

$ FNDCPASS apps/<test_apps_pass>  0 Y system/dev0dba USER SYSADMIN <sysadmin_pass>
APP-FND-01564: ORACLE error 1017 in AFPCOA
Cause: AFPCOA failed due to ORA-01017: invalid username/password; logon denied
.
The SQL statement being executed at the time of the error was:  and was executed from the file .
$

Here, above error is not the main error because it clearly says invalid username and password. It means password was not changed.

So, we checked the APPS password change log file and we found the main error below error:

$ cat L2230661.log
+---------------------------------------------------------------------------+
Application Object Library: Version : 12.1

Copyright (c) 1998, 2013, Oracle and/or its affiliates. All rights reserved.

FNDCPASS:
+---------------------------------------------------------------------------+

Current system time is 15-JUL-2018 08:42:51

+---------------------------------------------------------------------------+

Working...
Oracle error -29548: ORA-29548: Java system class reported: release of classes.bin in the database does not match that of the oracle executable - USER ( APPS ) has been detected in FND_WEB_SEC.GET_OP_VALUE.

+---------------------------------------------------------------------------+
Concurrent request completed
Current system time is 15-JUL-2018 08:42:51

+---------------------------------------------------------------------------+
$
Solution:
For this we have to run below these 2 scripts as SYSDBA:

SQL> @rmcorejvm.sql
SQL> @corejvminst.sql

$ cat rmcorejvm.sql
connect / as sysdba
set echo on
set serveroutput on
select * from v$instance;
select owner, status, count(*) from all_objects
where object_type like '%JAVA%' group by owner, status;
execute rmjvm.run(false);
shutdown immediate
set echo off
spool off
exit
$
$ cat corejvminst.sql
set serveroutput on
set echo on
startup mount
alter system set "_system_trig_enabled" = false scope=memory;
alter database open;
select owner, status, count(*) from all_objects
where object_type like '%JAVA%' group by owner, status;
create or replace java system
/
shutdown immediate
set echo off
spool off
exit

$
Hope this may useful and helpful. Please let us know for any suggestions @Contact US

Some more important links:

Regards,

Monday, 16 July 2018

FNDCPASS Command to Change APPS Password in R12.1.3

Hey DBA-Mates,Hope you all are doing great.
Recently, one of my junior team mates learned How to change APPS Password in R12.1.3. He is a junior and newly joined.

We asked him to change the APPS and SYSADMIN password after the clone.
But he was not done earlier and asked me some basics questions and its good. Even he google and checked but he was having some doubts.
He asked me some basics questions as:
1. Will we run FNDCPASS from SQL> prompt or $ prompt?
2. Apps Services should be UP or Down?

He knows the FNDCPASS uses to change the APPS user password but he have not done yet, so he got confused.
Then I thought it may be basics and easy lets share with you all guys.

Please find the below Steps:
1. FNDCPASS should be run from $ prompt.
2. Apps Services should be Down.
3. After changing Apps password through FNDCPASS, we should run autoconfig.
4. APPS and APPLSYS password will be same.

Steps to change the Apps password through FNDCPASS:
1. Run the env file.
$ . ./ora-data.blogspot.env

2. Cross check for correct server/host.
$ echo $TWO_TASK
ORA-DATA

3. Changing the APPS password through FNDCPASS:

$ FNDCPASS apps/<apps_oldpassword> 0 Y system/<system_pass> SYSTEM APPLSYS <apps_newpassword>
Log filename : L2331757.log


Report filename : O2331757.out
$

4. Always check the log because sometimes it will through error which you cannot know without checking log file.

$ cat L2331757.log
+---------------------------------------------------------------------------+
Application Object Library: Version : 12.1

Copyright (c) 1998, 2013, Oracle and/or its affiliates. All rights reserved.

FNDCPASS:
+---------------------------------------------------------------------------+

Current system time is 15-JUL-2018 10:15:50

+---------------------------------------------------------------------------+

Working...

FNDCPASS completed successfully.

+---------------------------------------------------------------------------+
Concurrent request completed successfully
Current system time is 15-JUL-2018 10:15:58

+---------------------------------------------------------------------------+
$

5. Changing the SYSADMIN password :

$ FNDCPASS apps/<apps_newpassword>  0 Y system/dev0dba USER SYSADMIN <password for sysadmin>
Log filename : L2471757.log


Report filename : O2471757.out

6. Now check the logfile.

$ cat L2471757.log
+---------------------------------------------------------------------------+
Application Object Library: Version : 12.1

Copyright (c) 1998, 2013, Oracle and/or its affiliates. All rights reserved.

FNDCPASS:
+---------------------------------------------------------------------------+

Current system time is 15-JUL-2018 10:16:42

+---------------------------------------------------------------------------+

Working...
Password is changed successfully for user SYSADMIN.
FNDCPASS completed successfully.

+---------------------------------------------------------------------------+
Concurrent request completed successfully
Current system time is 15-JUL-2018 10:16:46

+---------------------------------------------------------------------------+
$

Note: Once completed , please check and connect with APPS user with new password then start the services.

Regards,
ora-data Team

Wednesday, 11 July 2018

R12.2 Cloning Steps

Hey DBA-Mates,
Hope you all are rocking in APPS DBA because we DBAs always rock in case of work.. :D, just kidding.

Friends, when I searched in google almost people posted only for Apps tier cloning , what about DB tier which no one has mentioned. So, I thought let me cover that.

From long time, I was thinking for cloning as per real time scenario. But due to lack of time, I was not able to do so…

R12.2 CLONING STEPS:
Source: PROD
Target: TEST

1. Pre-requiste TASK AT PROD Instance PROD (Before Backup check space)
Please check the space for DB Backup, Conc Backup and App Backup as per your environment on server.

2. Preclone & Cold Backup on PROD Source                       
Prepare the source system database tier for cloning

$ cd $ORACLE_HOME/appsutil/scripts/PROD_hostname
$ perl adpreclone.pl dbTier

Prepare the Source System Application Tier for cloning
$ echo $FILE_EDITION  ==> Should return run

$ cd <INST_TOP>/admin/scripts
$ perl adpreclone.pl appsTier

Verification of adpreclone.pl done in all Tiers.
AT DBTier
Under cd $ORACLE_HOME/appsutil/clone below 2 files should be latest timestamp:
ls -lrtd jlib
ls -lrtd data
Same as above data => stage , below 2 files should be with current timestamp.
ls -lrt adcrdb.zip
ls -lrt addbhomsrc.xml

At AP(MT)
Here, we check the clone directory under $COMMON_TOP and for more confirmation we can check below two files:
cd $COMMON_TOP/clone
ls -lrtd jlib
ls -lrtd appl

As of Release 12.2, the adpreclone.pl process on the Application Tier creates a complete compressed archive of the Oracle Fusion Middleware such as:
Oracle WebLogic Server home,
Oracle Web Tier Utilities home,
Oracle Common Utilities home and
The Oracle E-Business Suite home.

Now, Shutdown PROD Completely [ because we are using cold backup]

cd $ADMIN_SCRIPTS_HOME
$./adstpall.sh

We need to take COLD Backup of PROD database and application RUN_BASE files system:

From DB Tier files need to be copied:

/u01/PROD/oradata/data
/u01/PROD/oradata/11.2.0 

From APPS Tier files need to be copied:

$RUN_BASE/EBSapps/appl
$RUN_BASE/EBSapps/comn
$RUN_BASE//EBSapps/10.1.2

Copy/Restore (unzip) to TEST by using cp command as per file structure and directory.
For Example:

$cp -R /u01/PROD/oradata/data /u01/TEST/oradata/data

Start the PROD Services because we don’t need.

3. Let’s start DB Clone:

Log on to the Target System as the ORACLE and Run the adcfgclone on the DBTier with dbTier option:

$ cd $ORACLE_HOME/appsutil/clone/bin
$ perl adcfgclone.pl dbTier

After adcfgclone.pl at DB-TIER please check whether DB services and DB listener is up and running. Then Proceed to next step.
Check DB Status and Create Temp Tablespace(if Not exists).

select count(*) from v$datafile; ==> should match as source count

Select distinct status from v$datafile;
Output as below shown:
SYSTEM
ONLINE

select file_name , tablespace_name , bytes/1024/1024 from dba_temp_files;
Example to add:
ALTER TABLESPACE TEMP ADD TEMPFILE '/u01/TEST/oradata/data/temp01.dbf' SIZE 1100M REUSE AUTOEXTEND OFF;

Clean FND_NODES table
Connect apps/<passwd>
EXEC FND_CONC_CLONE.SETUP_CLEAN;
commit;

Run Following command to close open mails:
sqlplus apps/appspwd

SQL>Update WF_NOTIFICATIONS set status = 'CLOSED', mail_status = 'SENT' where status = 'OPEN' and mail_status = 'MAIL';

Run autoconfig in DB tier and check whether the DB entry is updated in FND_NODES table.

$cd $ORACLE_HOME/appsutil/scripts/$CONTEXT_NAME
$adautocfg.sh

After Autoconfig runs successfull check following entry, it should not point to PROD :
sqlplus apps/appspwd
SQL> select node_name,support_db,last_update_date from fnd_nodes;

4. Application Tier Clone TEST

Run adcfgclone.pl on Apps Tier on "Run Edition File System".
Log on to the "Run Edition File System" in the Target System as the applmgr user:
$ cd <COMMON_TOP>/clone/bin
$ perl adcfgclone.pl appsTier

Start the application Tier using adstral.sh on RUN FILE System
cd $ADMIN_SCRIPTS_HOME
adstrtall.sh apps/appspwd

Run adpreclone on TARGET(TEST) RUN FILESYSTEM
We have to run adpreclone.pl on the "Run Edition File System" in the Target System. [New in R12.2]

Note: We are not Running Autoconfig because adcfgclone.pl will run internally autoconfig.

On TARGET (TEST) RUN FILE System
$ cd <INST_TOP>/admin/scripts
$ perl adpreclone.pl appsTier

SHUTDOWN THE APPLICATION which is running on RUN FILESYSTEM
cd $ADMIN_SCRIPTS_HOME
adstpal.sh apps/appspwd
Weblogic admin password:

COPY THE TARGET RUN FILESYSTEM to TARGET PATCH FILESYSTEM
Now, CONFIGURE TARGET PATCH FILESYSTEM

Run adcfgclone.pl on Apps Tier on "Patch Edition File System"
Log on to the "Patch Edition File System" in the Target System( as the APPLMGR user) and enter the following commands:

$ cd <COMMON_TOP>/clone/bin
$ perl adcfgclone.pl appsTier

Note-1: It will ask for Context file name, provide the fs1 (Run Fs) contetxt file name.
Note-2: Port will be different for Run and Patch FS.

Once completed: Startup the application tier services of  TEST

cd $ADMIN_SCRIPTS_HOME
adstrtal.sh apps/password
Enter WLSADMIN password:

Once above all done successfully, please perform Sanity Check.[Here, I can provide your some points or steps very soon]

5. Post Clone steps:

Update profile options and FND_CONCURRENT_REQUESTS:

sqlplus apps/passwd
UPDATE FND_CONCURRENT_REQUESTS
SQL> update fnd_concurrent_requests set status_code='C', phase_code='C'  where phase_code='P';

Change Site level Profile option.

Execute the below sql for running programs.
a) Set Terminating or Running to Completed/Terminated
SQL>UPDATE fnd_concurrent_requests
SET phase_code = 'C', status_code = 'X'
WHERE status_code ='T'
OR phase_code = 'R'
/

b) Place Pending/(Normal/Standby) to On Hold
SQL>UPDATE fnd_concurrent_requests
SET hold_flag = 'Y'
WHERE phase_code = 'P'
AND status_code in ('Q','I')
/

Then check for Health check and sanity check. Login to front end and submit the request.

Some more useful links:
Please let us know for any suggestions either in comment box or contact us @https://ora-data.blogspot.com
Regards,