Wednesday, 7 April 2021

𝐎𝐫𝐚𝐜𝐥𝐞 𝐄𝐁𝐒 𝐑𝟏𝟐.𝟐 ( 𝐄-𝐁𝐮𝐬𝐢𝐧𝐞𝐬𝐬 𝐒𝐮𝐢𝐭𝐞 ) 𝐒𝐭𝐞𝐩 𝐛𝐲 𝐒𝐭𝐞𝐩 𝐂𝐥𝐨𝐧𝐢𝐧𝐠

 



Step 1:  Run Pre-Clone on the Source Apps Tier and DB Tier

  • Application Preclone

$ /apdata/erp/fs2/inst/apps/UAT_vm3uat/admin/scripts/adpreclone.pl appsTier pwd=apps

Make tar file :

$  tar -zcPf /apdata/Binary_BKP/apps.tar.gz /apdata/erp/fs2/EBSapps

  • Database Preclone

$ /dbuat/erp/12.1.0/appsutil/scripts/UAT_vm4db/adpreclone.pl dbTier pwd=apps

Make tar file:

$ tar --exclude='/dbuat/erp/12.1.0/admin' -cvf /dbuat/archbackup/Binary/UAT_db.tar.gz /dbuat/erp/12.1.0/


Step 2:  Take Full RMAN Backup (Include current control file & Archive log) at Source Server

 

Step 3:  Copy the Application Tier binary tar file from Source to Target.

Step 4:  Copy the Database binary tar file & RMAN backup from Source to Target.



Step 5: Now, Prepare file system at target server

  • Create the following directories in Target DB server

            mkdir –p /dbdev/erp/12.1.0

            mkdir p /dbdev/erp/data

            chown -Rf  oradev:dba  /dbdev/erp/

            chmod -Rf 775 /dbdev/erp/

             ***Here ,

             RDBMS_ORACLE_HOME=/dbdev/erp/12.1.0

             ORACLE BASE=/dbdev/erp/

             DATA_TOP Directory=/dbdev/erp/data

 

·         Create the following directories in Target EBS Application server 

            mkdir p /apdata/erp/fs2/EBSapps  (Run File system)

            mkdir p /apdata/erp/fs1/   (Patch File system)

            chown -Rf  appldev:dba  /apdata/erp/

            chmod  -Rf 775 /apdata/erp/

 

·         Untar DB binary and copy to target file system

Ø  tar –xvf  UAT_db.tar.gz

Ø  cp –rf  /dbuat/erp/12.1.0/* /dbdev/erp/12.1.0

 

·         Untar Application binary and copy to target file system

Ø   tar –xvf  apps.tar.gz

Ø  cp –rf   /apdata/erp/fs2/EBSapps/* /apdata/erp/fs2/EBSapps/

  



 

Step 6: Configure the Oracle home on Target Database Server

 

[oradev@vm4db bin]$ perl adcfgclone.pl dbTechStack

 

                     Copyright (c) 2002, 2015 Oracle Corporation

                        Redwood Shores, California, USA

                        Oracle E-Business Suite Rapid Clone

                                 Version 12.2

                      adcfgclone Version 120.63.12020000.60

 

Enter the APPS password :

 

Running: Context clone...

 

Log file located at /dbdev/erp/12.1.0/appsutil/clone/bin/CloneContext_0405185655.log

 

Provide the values required for creation of the new Database Context file.

 

Target System Hostname (virtual or normal) [vm4db] : vm4db.alam.com

 

Target Instance is RAC (y/n) [n] : n

 

Target System Database SID : DEV

 

Target System Base Directory : /dbdev/erp/

 

Role separation is supported y/n [n] ? : n

 

Target System utl_file_dir Directory List : /tmp

 

Number of DATA_TOP's on the Target System [1] :

 

Target System DATA_TOP Directory 1 [/dbdev/erp/data] :

 

Target System RDBMS ORACLE_HOME Directory [/dbdev/erp/12.1.0] :

 

Do you want to preserve the Display [vm4db:0.0] (y/n)  : n

 

Target System Display [vm4db:0.0] :

 

Target System Port Pool [0-99] : 20

 



 

Step 7: Start the database in nomount mode.

Before starting check the pfile and make sure all the paths are pointing as per target

server directory structure.

 

Add below entry in InitDEV.ora (files are to be restored to a different location):

 

*.db_file_name_convert=’<source_path>’,’<target_path>’

*.db_file_name_convert='/dbuat/erp/data/','/dbdev/erp/data/' 

 

*.log_file_name_convert=’<source_path>’,’<target_path>’

*.log_file_name_convert='/dbuat/erp/data/','/dbdev/erp/data/'

SQL> startup nomount pfile='initDEV.ora';

SQL> create spfile from pfile='initDEV.ora';

SQL> shu immediate;

SQL> startup nomount;

 

Step 8. Rman backup Restoration at target DB server

 

$ rman auxiliary / log=rman_output_060421.txt

Recovery Manager: Release 12.1.0.2.0- Production on Tue Apr 05 18:10:49 2021

Copyright (c) 1991, 2014, Oracle and/or its affiliates.  All rights reserved.

connected to target database: uattest (not mounted)

 

RMAN> run{

allocate auxiliary channel C1 DEVICE TYPE DISK;

allocate auxiliary channel C2 DEVICE TYPE DISK;

allocate auxiliary channel C3 DEVICE TYPE DISK;

allocate auxiliary channel C4 DEVICE TYPE DISK;

allocate auxiliary channel C5 DEVICE TYPE DISK;

allocate auxiliary channel C6 DEVICE TYPE DISK;

allocate auxiliary channel C7 DEVICE TYPE DISK;

allocate auxiliary channel C8 DEVICE TYPE DISK;

duplicate database to 'DEV' backup location '/dbuat/BACKUP/rman05042021_BKP/databkp' nofilenamecheck;

}

 




v   Change database to Noarchivelog mode

            SQL> shut immediate;

            SQL> startup mount;

            SQL> alter database noarchivelog;

            SQL> alter database open;

 

v  Now, login to application user.

         $ sqlplus apps/apps  [Use Source apps user password]

  • Run the below command to remove the Source Instance entries.

          SQL>  EXEC FND_CONC_CLONE.SETUP_CLEAN;

          SQL> commit;

 

v  Run Autoconfig on DBTier:-

         $ cd /dbdev/erp/12.1.0/appsutil/scripts/DEV_vm4db

          [oradev@vm4db DEV_vm4db]$  adautocfg.sh

          Enter the APPS user password:

 

 



Step 9. Now login to application server, run adcfgclone on appstier.

#[RUN FILE SYSTEM]

$ cd /apdata/erp/fs2/EBSapps/comn/clone/bin

[appldev@vm2dev bin]$  perl adcfgclone.pl appsTier

 

                     Copyright (c) 2002, 2015 Oracle Corporation

                        Redwood Shores, California, USA

                        Oracle E-Business Suite Rapid Clone

                                 Version 12.2

                      adcfgclone Version 120.63.12020000.60

                ***********************************************************

                In AD-TXK Delta 7, we recommend you clone the run and patch

                file systems in a single operation using the 'dualfs' option.

                Separate cloning of the run and patch file systems will be deprecated

                ************************************************************

 

Enter the APPS password :

 

Enter the Weblogic AdminServer password :

 

Do you want to add a node (yes/no) [no] :

 

Running: Context clone...

 

Log file located at /apdata/erp/fs2/EBSapps/comn/clone/bin/CloneContext_0406034543.log

 

Target System File Edition type [run] :

 

Provide the values required for creation of the new APPL_TOP Context file.

 

Target System Hostname (virtual or normal) [vm2dev] : vm2dev.alam.com

 

Target System Database SID : DEV

 

Target System Database Server Node [vm2dev] : vm4db.alam.com

 

Target System Base Directory : /apdata/erp/

 

Target System Base Directory set to /apdata/erp

 

Target System Current File System Base set to /apdata/erp/fs2

 

Target System Other File System Base set to /apdata/erp/fs1

 

Target System Fusion Middleware Home set to /apdata/erp/fs2/FMW_Home

 

Target System Web Oracle Home set to /apdata/erp/fs2/FMW_Home/webtier

 

Target System Appl TOP set to /apdata/erp/fs2/EBSapps/appl

 

Target System COMMON TOP set to /apdata/erp/fs2/EBSapps/comn

 

Target System Instance Home Directory [/apdata/erp] :

 

Target System Instance Top set to /apdata/erp/fs2/inst/apps/DEV_vm2dev

 

Do you want to preserve the Display [vm3uat:0.0] (y/n)  : n

 

Target System Display [vm2dev:0.0] :

 

Target System Root Service [enabled] :

 

Target System Web Entry Point Services [enabled] :

 

Target System Web Application Services [enabled] :

 

Target System Batch Processing Services [enabled] :

 

Target System Other Services [disabled] :

 

Do you want the target system to have the same port values as the source system (y/n) [y] ? : n

 

Target System Port Pool [0-99] : 20

 

Checking the port pool 20

done: Port Pool 20 is free

Report file located at /apdata/erp/fs2/inst/apps/DEV_vm2dev/admin/out/portpool.lst

 

UTL_FILE_DIR on database tier consists of the following directories.

 

1. /usr/tmp

2. /tmp

3. /dbdev/erp/12.1.0/appsutil/outbound/DEV_vm4db

4. /usr/tmp

Choose a value which will be set as APPLPTMP value on the target node [1] :

 

Step 10:  (i) Start the Application tier.

                 $ cd $ADMIN_SCRIPTS_HOME

                 $ sh adstrtal.sh apps/<apps-password>

                 (ii)Run adpreclone on TARGET RUN File System

                 $ /apdata/erp/fs2/inst/apps/UAT_vm3uat/admin/scripts/adpreclone.pl appsTier pwd=apps

               (iii) Shutdown application on TARGET RUN File System

                 $ cd $ADMIN_SCRIPTS_HOME

                 $ sh adstpall.sh apps/<apps-password>

                (iv) Copy Target RUN File System to Target Patch File System

                  $ cp -rf  /apdata/erp/fs2/* /apdata/erp/fs1/

 



v Patch Edition File System cloning

Step 11:   (i) UNSET the application Enviroment. Previously we have executed env.

                 (ii) Before we run adcfgclone.pl dont run any env’s

                  

 Now, Directly go to /apdata/erp/fs1/EBSapps/comn/clone/bin/ and execute adcfgclone.pl

[appldev@vm2dev bin]$ perl adcfgclone.pl appsTier

 

                     Copyright (c) 2002, 2015 Oracle Corporation

                        Redwood Shores, California, USA

 

                        Oracle E-Business Suite Rapid Clone

 

                                 Version 12.2

 

                      adcfgclone Version 120.63.12020000.60

 

                ***********************************************************

                In AD-TXK Delta 7, we recommend you clone the run and patch

                file systems in a single operation using the 'dualfs' option.

                Separate cloning of the run and patch file systems will be deprecated

                ************************************************************

 

Enter the APPS password :

 

Enter the Weblogic AdminServer password :

 

Do you want to add a node (yes/no) [no] :

 

 

Running: Context clone...

 

Log file located at /apdata/erp/fs1/EBSapps/comn/clone/bin/CloneContext_0406115635.log

 

Target System File Edition type [run] : patch

 

Enter the full path of Run File System Context file : /apdata/erp/fs2/inst/apps/DEV_vm2dev/appl/admin/DEV_vm2dev.xml

 

Provide the values required for creation of the new APPL_TOP Context file.

 

Target System Fusion Middleware Home set to /apdata/erp/fs1/FMW_Home

 

Target System Web Oracle Home set to /apdata/erp/fs1/FMW_Home/webtier

 

Target System Appl TOP set to /apdata/erp/fs1/EBSapps/appl

 

Target System COMMON TOP set to /apdata/erp/fs1/EBSapps/comn

 

Target System Instance Top set to /apdata/erp/fs1/inst/apps/DEV_vm2dev

 

Target System Port Pool [0-99] : 21



v POST CLONING STEPS

Update the Sitename & Date:

SQL>DECLARE

stat boolean;

BEGIN

dbms_output.disable;

dbms_output.enable(100000);

stat := FND_PROFILE.SAVE('SITENAME', 'DEV(Data Till 05-APR-21)', 'SITE');

IF stat THEN

dbms_output.put_line( 'Stat = TRUE - profile updated' );

ELSE

dbms_output.put_line( 'Stat = FALSE - profile NOT updated' );

END IF;

commit;

END;

/

 

Change the profile name:

SQL> DECLARE

stat boolean;

BEGIN

dbms_output.disable;

dbms_output.enable(100000);

stat := FND_PROFILE.SAVE('FS_SVC_PREFIX', 'FNDFS_DEV_', 'SITE');

IF stat THEN

dbms_output.put_line( 'Stat = TRUE - profile updated' );

ELSE

dbms_output.put_line( 'Stat = FALSE - profile NOT updated' );

END IF;

commit;

END;

/

 

 To change color of the site:

SQL>DECLARE

stat boolean;

BEGIN

dbms_output.disable;

dbms_output.enable(100000);

stat := FND_PROFILE.SAVE('FND_COLOR_SCHEME', 'BLUE', 'SITE');

IF stat THEN

dbms_output.put_line( 'Stat = TRUE - profile updated' );

ELSE

dbms_output.put_line( 'Stat = FALSE - profile NOT updated' );

END IF;

commit;

END;

/

 

Clear the schedule concurrent program:

SQL> UPDATE  fnd_concurrent_requests

   SET phase_code = 'C', status_code = 'X'

 WHERE phase_code = 'P'

       AND request_id NOT IN

              (SELECT request_id

                 FROM fnd_conc_req_summary_v

                WHERE program IN

                         ('WIP Move Transaction Manager',

                          'Process transaction interface',

                          'Manager: Lot Move Transactions',

                        'Workflow Background Process',

                          'Cost Manager')

                      AND (phase_code = 'P' OR phase_code = 'R'));

 

 

 

SQL> UPDATE  fnd_concurrent_requests

   SET phase_code = 'C', status_code = 'X'

 WHERE phase_code = 'R' AND status_code = 'R'

       AND request_id NOT IN

              (SELECT request_id

                 FROM fnd_conc_req_summary_v

                WHERE program IN

                         ('WIP Move Transaction Manager',

                          'Process transaction interface',

                          'Manager: Lot Move Transactions',

                        'Workflow Background Process',

                          'Cost Manager')

                      AND (phase_code = 'P' OR phase_code = 'R'));

 

SQL>  COMMIT;

 

 

v Run autoconfig on dbtier and then on appstier.

 

DB tier:

           $ cd $ORACLE_HOME/appsutil/scripts/DEV_vm4db

          $  adautocfg.sh


          Apps tier:

          $  cd $ADMIN_SCRIPTS_HOME

          $  adautocfg.sh

 

 

v Start the Application tier. Check OPMN status and from front end.

           $  cd $ADMIN_SCRIPTS_HOME

           $ ./adstrtal.sh  apps/apps

             Enter the weblogic user password:

~~~~~~~~~~~~~~~~~~EBS R12.2 Cloning is completed!!~~~~~~~~~~~~~~~~~~


Sunday, 28 March 2021

𝗘𝗕𝗦 𝗥𝟭𝟮 - 𝗦𝘆𝘀𝘁𝗲𝗺 𝗱𝗼𝗲𝘀 𝗻𝗼𝘁 𝗮𝗹𝗹𝗼𝘄 𝘁𝗼 𝗼𝗽𝗲𝗻 𝗳𝗼𝗿𝗺𝘀 - 𝗥𝗲𝗰𝗲𝗶𝗽𝘁𝘀, 𝗥𝗲𝘁𝘂𝗿𝗻𝘀 & 𝗩𝗶𝗲𝘄 𝗿𝗲𝗰𝗲𝗶𝘃𝗶𝗻𝗴 𝘁𝗿𝗮𝗻𝘀𝗮𝗰𝘁𝗶𝗼𝗻𝘀 𝗮𝗳𝘁𝗲𝗿 𝗮𝗽𝗽𝗹𝘆𝗶𝗻𝗴 𝗢𝗿𝗮𝗰𝗹𝗲 𝗣𝘂𝗿𝗰𝗵𝗮𝘀𝗶𝗻𝗴 𝗖𝗼𝗻𝘀𝗼𝗹𝗶𝗱𝗮𝘁𝗶𝗼𝗻 𝗣𝗮𝘁𝗰𝗵

 

In EBS R12.1.3, After Applying Oracle Purchasing Consolidation Patch for 12.1.3 - August 2019. In order to open Forms, Receipts, Returns & View receiving transactions are showing Error as follows:

The following Oracle Forms objects did not generate successfully:

ar forms/US ARXRWRCT.fmx
po forms/US RCVRCVRC.fmx
po forms/US RCVSHESH.fmx
po forms/US RCVTXVTX.fmx
po forms/US RCVTXERE.fmx
po forms/US RCVCOFND.fmx
po forms/US RCVRCERC.fmx
po forms/US RCVTXECO.fmx
po forms/US RCVTXERT.fmx


Try to Execute the following commands to generate the forms manually:

frmcmp_batch  userid=apps/<apps_pw> module=RCVRCVRC.fmb output_file=$AU_TOP/forms/US/RCVRCVRC.fmx module_type=form batch=no compile_all=special


Not compiled with below Errors:

FRM-30064: Unable to parse statement select distinct hre.person_id, hre.full_name, nvl(hre.employee_number, hre.npw_number) employee_number from per_all_people_f hre, rcv_transactions rt where rt.employee_id = hre.person_id and (rt.transaction_type = 'UNORDERED' or rt.transaction_type = 'RECEIVE') and rt.organization_id = :po_startup_values.org_id
and hre.business_group_id in (select nvl(fsp.business_group_id,0)
from financials_system_params_all fsp where mo_global.check_access(fsp.org_id) = 'Y')
and trunc(sysdate) between hre.effective_start_date and hre.effective_end_date
and decode(hr_security.view_all ,'Y','TRUE',
HR_SECURITY.SHOW_PERSON (HRE.person_id , HRE.current_applicant_flag ,HRE.current_employee_Flag , HRE.current_npw_flag ,HRE.employee_number , HRE.applicant_number , HRE.npw_number)) = 'TRUE'
and decode(hr_general.get_xbg_profile,'Y',hre.business_group_id ,
hr_general.get_business_group_id) = hre.business_group_id
order by upper(hre.full_name)
.
ORA-01791: not a SELECTed expression
Record Group FIND_RECEIVER
Form: RCVRCVRC

FRM-30085: Unable to adjust form for output.
Form not created



































Solution:

Step 1: First, test in UAT environment or cloned instance.

Set the database parameter - _replace_virtual_columns = false

SQL> alter system set "_replace_virtual_columns"=FALSE;

 

Step 2: Stop the application service and Restart the database.

 

Then, Run adadmin to Relink / Generate Forms Library Files:

Select the "Generate Applications Files menu" option.















Then select the "Generate forms files" option.



 

 











Choose the number of workers, the default is recommended and is based off the number of CPUs in your server.




















Enter "yes" at this prompt to regenerate PL/SQL library files (.pll extension)

Enter "yes" at this prompt to regenerate Forms Menu files (.mmb -> .mmx extension)

Enter "yes" at this prompt to regenerate Forms Executable files (.fmb -> .fmx extension)

Enter the list of products, by short name as they are listed in "$APPL_TOP/". Use commas to separate the product names.




 

 

 

 

 

 

 

 


As per above steps, Recompiled all forms and form libraries and then follow step 4.


 

Step 4:  Retest the issue. Otherwise, If the issue get                 resolved, then implement the solution on PRODUCTION         Instance.



Friday, 19 February 2021

𝐀𝐮𝐭𝐨𝐧𝐨𝐦𝐨𝐮𝐬 𝐃𝐚𝐭𝐚𝐛𝐚𝐬𝐞𝐬 𝐂𝐥𝐨𝐧𝐢𝐧𝐠 𝐌𝐞𝐭𝐡𝐨𝐝𝐬

 




v   Autonomous Database Cloning

 

Use cases: 

·       Business requirements: Testing, Development or Analytics.

·       Database upgrade when a new version is available.

 

 

       Types of Clone:

·        Full clone: A full copy of the source database.

·        Refreshable clone: Changes on applied on the clone based on requests.

·        Metadata clone: A copy of the source database without user-data.













OCI CLI Clone Commands

Command

Description

 

 

ocidbautonomous-database create-from-clone

Creates a new full or metadata clone Autonomous Database.

 

 

ocidbautonomous-database create-refreshable-clone

Creates a new refreshable clone Autonomous Database.

 

 

ocidbautonomous-database list-clones

Lists the Autonomous Database clones for the specified Autonomous Database

 

 

ocidbautonomous-database manual-refresh

Initiates a data refresh for an Autonomous Database refreshable clone.


Friday, 12 February 2021

𝐎𝐫𝐚𝐜𝐥𝐞 𝐑𝐀𝐂 𝐏𝐥𝐚𝐧𝐧𝐞𝐝 𝐌𝐚𝐢𝐧𝐭𝐞𝐧𝐚𝐧𝐜𝐞 𝐀𝐜𝐭𝐢𝐯𝐢𝐭𝐲 𝐒𝐭𝐞𝐩𝐬 (𝐇𝐢𝐠𝐡-𝐀𝐯𝐚𝐢𝐥𝐚𝐛𝐢𝐥𝐢𝐭𝐲 𝐁𝐞𝐬𝐭 𝐏𝐫𝐚𝐜𝐭𝐢𝐜𝐞𝐬)

                                                      [̲̅O][̲̅R][̲̅A][̲̅C][̲̅L][̲̅E] [̲̅R][̲̅A][̲̅C]

Ø  First take “RMAN FULL Backup” of PRODUCTION RAC database.

 

Shutdown NODE-2 of ORACLE RAC Cluster

 

Step 1) IN NODE-2, Disable auto start of CRS in order to be able to perform server-OS Patching. So that CRS is not restarted after a reboot of the server.

 

Ø   crsctl disable crs

 

Step 2) Shutdown the instance running on NODE-2.

 

Ø   srvctl stop instance -d RACDB -i RACDB2 -o immediate

 

Step 3) Shutdown oracle cluster ware.

 

Ø  crsctl stop crs

 

Step 4) Check cluster ware and database instance status.

 

Ø   crsctl check crs

Ø  srvctl status database –d RACDB

 


 Handover NODE-2 to IT team for OS patching.  

                                         


After OS Patching:

Startup NODE-2 of ORACLE RAC Cluster

 

Step 1) IN NODE-2, enable auto start of CRS.

 

Ø   crsctl enable crs

 

Step 2) Start oracle cluster ware.

 

Ø  crsctl start crs

 

Step 3) Startup the RACDB2 instance on NODE-2.

 

Ø  srvctl start instance -d RACDB -i RACDB2

 

Step 4) Check cluster ware and database instance status.

 

Ø  crsctl check crs

Ø  srvctl status database –d RACDB

 


 Handover NODE-2 to  Apps team to check it functionality.

 


Note:- 

After confirmation from Apps team that everything running smoothly then only we will go for NODE-1.

 

Otherwise IT team will have to Rollback OS Patch in NODE-2 !!

 

 


 

Again we will follow the same steps as all mentioned above for Node 1  


Shutdown NODE-1 of ORACLE RAC Cluster

 

Step 1) IN NODE-1, Disable auto start of CRS in order to be able to perform server-OS Patching. So that CRS is not restarted after a reboot of the server.

 

Ø  crsctl disable crs

 

Step 2) Shutdown the instance running on NODE-1.

 

Ø  srvctl stop instance -d RACDB -i RACDB1 -o immediate

 

Step 3) Shutdown oracle cluster ware.

 

Ø  crsctl stop crs

 

Step 4) Check cluster ware and database instance status.

 

Ø  crsctl check crs

Ø  srvctl status database –d RACDB

 


Handover NODE-1 to IT team for OS patching.



After OS Patching:

Startup NODE-1 of ORACLE RAC Cluster

 

Step 1) IN NODE-1, enable auto start of CRS.

 

Ø  crsctl enable crs

 

Step 2) Start oracle cluster ware.

 

Ø crsctl start crs

 

Step 3) Startup the RACDB1 instance on NODE-1.

 

Ø  srvctl start instance -d RACDB -i RACDB1

 

Step 4) Check cluster ware and database instance status.

 

Ø  crsctl check crs

Ø  srvctl status database –d RACDB

 

 Handover NODE-1 to  Apps team to check it functionality.

 


Apps team will need to confirm that everything running smoothly from their end..!!


 ROLLBACK: If anything goes wrong then IT team will have to rollback OS patch in Node- 1 & Node- 2 accordingly. 

Else even after rollback of OS patch if it doesn't work then we can restore RAC database from latest backup which we have taken just before the activity.