Tuesday, June 30, 2015

ASM Setup, Configuration, Steps to create disk groups and commands used.

1. What is ASM  Oracle ASM is a volume manager which provides a special file system designed especially for oracle db.  Replaces conventional file systems and volume managers  Capacity on demand  Add/drop disks online  Automatic I/O load balancing  Stripes data across disks to balance load  Automatic mirroring  Easy to set up and use  Works with SAN, NAS or file systems 2. What ASM does  Stripe & mirror data across multiple disks  Reduces management overhead  Provides 0, 2 or 3-way mirroring  Can store almost all types of database related files* 3. What ASM does not do.  Not an I/O broker or controller – I/O is still managed by the individual instances  Not a database – INSTANCE_TYPE=‘asm’  Acts as the mediator and definer  Not foolproof, luns can be removed out from under ASM! 4. ASM Setup  Install in own Oracle Home  Determine redundancy/mirroring  Determine LUN/Disk size  Partition devices  Install ASM software and start the “mini-cluster” 5. The “mini-cluster”  The Oracle Cluster Synchronization Services Daemon is required for ASM – even for a single (non-RAC) database  Used for communication between ASM and database instances  Root.sh will create an entry in /etc/inittab to respawn cssd  Only one ASM instance per node 6. init+ASM.ora *.asm_diskgroups=‘DATA' *.asm_diskstring='ORCL:*‘ -- linux *.asm_diskstring=‘/dev/asm_disk*’ -- unix *.asm_diskstring=‘/dev/c0t1d1*’ – unix *.asm_diskstring=‘/dev/sda1’ *.instance_type='asm' *.processes=500 - Set to minimum of 25 + 15 * number of databases uses ASM for storage 7. Diskgroups  Diskgroups are the logical storage units for ASM  One or more for all databases on a server or cluster  Often, two diskgroups are created, one for tablespace and another for FRA  Diskgroups may also be created by SAN speed (fast, middle, slow) 8. Redundancy ASM supports three types of redundancy  External – no mirroring within ASM, all at the OS level  Normal – the default – two way mirroring, each stripe is written to two extents  High – three way mirroring – each stripe written to one primary and two mirrored extents 9. Failgroups  Failgroups cannot be removed without recreating the diskgroup.  If one failgroup is lost or offline for a period of time, it will be re-synced when available again  Fail groups should be across different controllers or SANs\ 10. Tools to Manage ASM  SQL*Plus  ASMCMD  Grid Control / Database Control  SRVCTL – RAC only 11. Basic ASM Commands  Create a diskgroup: CREATE DISKGROUP dgroup1 DISK ’orcl:vol001’,’orcl:vol002’;  Drop a diskgroup DROP DISKGROUP dgroup1;  To drop a diskgroup which still contains data: DROP DISKGROUP dgroup1 INCLUDING CONTENTS;  Add luns to a diskgroup: ALTER DISKGROUP dgroup1 ADD DISK ‘orcl:vol006’;  Remove luns from a diskgroup: ALTER DISKGROUP dgroup1 REMOVE DISK ‘vol006’;  Do both at the same time: ALTER DISKGROUP dgroup1 ADD DISK 'ORCL:VOL003','ORCL:VOL004' DROP DISK 'VOL005' REBALANCE POWER 6; 12. Rebalancing  Redistribution only occurs when adding or dropping disk  Change the asm_power_limit, default 1, 0 up to 11  To modify the power limit for a disk group: alter diskgroup dgroup1 rebalance power 11;  Check on the status via V$ASM_OPERATION 13. Basic ASM Commands – Database level  Set for default diskgroup db_create_file_dest=‘+DGROUP1’  Create tablespaces without names using OMF CREATE TABLESPACE testts DATAFILE SIZE 5g; ALTER TABLESPACE testts ADD DATAFILE SIZE 10g;  Set for default diskgroup for logfiles: db_create_online_log_dest_1=‘+DGROUP1’ db_create_online_log_dest_2=‘+DGROUP1’  Create redo logs without names using OMF ALTER SYSTEM ADD LOGFILE SIZE 200m; 14. ASM Limitations  If ASM goes down, all instance that use ASM will immediately crash.  Normal or high redundancy may not show the actual disk use  Databases can remain unnoticed if not dropped  Loss of a disk (when using external redundancy) will result in the loss of the diskgroup 15. New ASM Features in 11gR2  ASM part of the clusterware  ACFS  ASMCA, ASMCMD  RAC - OCR/Voting disks in ASM  Diskgroup rename 16. How ASM Improves performance When you enter COMMIT, the information/data is written to REDOLOG files from REDOBUFFER. If redolog files is removed and then if we enter commit, as per oracle test it should not get completed but practically It will get completed ,coz commit goes through file system buffer ,also it depends on the operating system Read ahead and write delay is the basic concept of information technology architecture by itself. When you try to read the information from dba files to buffer cache….bunch of blocks will get pulled I to buffer cache..multi block read count is the parameter which is influencing how to read from block mechanism .. And when you save it, it goes to file system buffer to buffer cache. File system buffer will work like a shock absorber. It will work in there…till the file system buffer gets full; once the buffer is full the information will be written back to the appropriate files. File system buffer works great if the size of the amount is small like redo log file and control log files...for huge amount of data file system buffer may not be the solution.. For big size data. RAW partition is the solution. In case of raw partition .you keep the datafile on raw partition…raw partition will not use file system buffer, because it is not formatted as file system, operating system has no clue on managing raw partition. Oracle can manage raw partition .Information directly comes from raw partition to buffer cache and when you write it directly goes to raw partition. Because the amount of data I huge in size. Reading and writing directly from the raw partition will boost the IO performance than any other file system Note: CRD files much be in the shared storage. ASM is the replacement for volume manager. What volume manager can do, can be done by ASM without any extra cost…volume manager crated volume group in case of ASM we create disk group. ASM will use raw partition only. You can say a combination of raw disk and omf. Performance of raw disk and ease of use of omf. CRD FILES can be stored in (control files, redo log files and data files) 1. Cooked file system 2. Oracle managed files. (ease to use) 3. RAW Partitions (will boost the IO performance by 10 to 15 % by default ) Oracle files can be stored either in a file system, raw device, asm or in ocfs Earlier oracle had to use either a filer system or a raw device. Things might become a little slow when it is using file system as it has to go through its file system buffering. On the other hand oracle was not able l to keep multiple files in the raw device like a file system would allow. The solution: Write your own volume manager and your own file system, ORACLE created its own storage solution called ASM 17. Steps to create disk group for database using ASM Step 1: export ORACLE_SID = +ASM Step 2: vi init+ASM.ora Add the below variables. instance_type=asm Step 3: mkdir c:/asmdisks Step 4: asmtool -create /u01d/asmdisks/asmdisks1.asm 300 asmtool -create /u01d/asmdisks/asmdisks2.asm 300 Step 5: asmtool -create /u01d/asmdisks/asmdisks3.asm 300 Step 6: Add the below valu es init+ASM.ora ASM_DISKSTRING = ‘C:\asmdisk\*’ _ASM_ALLOW_ONLY_RAW_DISKS=FALSE Now we have to add two parameter in init+ASM.ora ASM_DISKSTRING = ‘C:\asmdisk\*’ //WHEN ASM START this parameter says to use the files which are in this directory .,to store the db that you manages. _ASM_ALLOW_ONLY_RAW_DISKS=FALSE // UNDOCUMENTED PARAMETER ..SHOULD BE USED ALONG WITH ORACLE SUPPORT ..ALL UNDOCUMENTED PROCEDURE HAS UNDERSCORE . by default asm uses only raw logical volume disk for storage ..by giving this parameter we are tricking asm …to tell asm to use files that we created . Step 7: export ORACLE_SID=+ASM Step 8: qlplus / as sysdba Step 9: startup now you can see no diskgroups mounted, It says no disk group mounted… coz we did not tell asm which disk group to be used. before oracle can manages the asm ..it need be in a disk group . Disk partition should belong to a disk group . Step 10: SQL> select path,mount_status from v$asm_disk; The staus of .asm file will be closed, this is they are not mounted. Step 11 : create diskgroup dgroup1 normal redundancy disk '/u01d/asmdisk/asmdisk1.asm', '/u01d/asmdisks/amsdisk2.asm'; Step 12: shutdown; Step 13: startup; AGain you can see no disk group mounted. Step 14: vi init+ASM.ora Add the below value. ASM_DISKGROUS='dgroup1' Step 15: sqlplus / as sysdsba startup; you can see ASM diskgroup mounted. Step 16: select name,state,total_mb from v$asm_diskgroup; Step 17: select name,state,path from v$asm_disk; 18. ORACLE ASM Instance. ORACLE has its own LVM now called ASM Which is nothing but an instance called ASM instance .which runs on the same server or operating system where db run.bascially it creates disk groups. It doesn’t matter where it comes from …you have to just choose the disk and create the disk groups in ASM .and use it for your db. Oracle asm has performance benefits. Will allow you to spread the load out and mirror data. Below are the other options to store your data file, control file, online redo log files Normal File Systems like Windows ntfs Aix jfs 2 Unix ufs Solaris zfs Hp veritise Linux ext3 ext4 Etc .this is easier to mange. Other options is to create datafiles etc inraw logical volume with out any file system on them (with out any cooked file system) This is more difficult to maintain …but possible 2nd option if you are not using ASM

Thursday, June 25, 2015

Oracle Database Online Documentation 11g Release 2 (11.2) Installing and Upgrading all Platforms

Oracle Database Online Documentation 11g Release 2 (11.2) Installing and Upgrading http://docs.oracle.com/cd/E11882_01/nav/portal_11.htm Oracle Database Online Documentation 11g Release 2 (11.2) Installing and Upgrading Installation guides for Oracle Database 11g and accompanying products on various platforms are collected here. Full Installation Guides describe a wider variety of scenarios with more detail. Client Installation Guides describe installing Oracle database client software on hosts where the database server is not installed. Supplementary Installation Guides describe installing products that are included with the database but installed separately. Essentials Licensing Information Click to show summary. Click to show download options. Readme Click to show summary. Click to show download options. Universal Installer and OPatch User's Guide for Windows and UNIX Click to show summary. Click to show download options. Upgrade Guide Click to show summary. Click to show download options. Linux Installation Guides Release Notes for Linux Click to show summary. Click to show download options. Database Quick Installation Guide for Linux x86 Click to show summary. Click to show download options. Database Quick Installation Guide for Linux x86-64 Click to show summary. Click to show download options. Database Installation Guide for Linux Click to show summary. Click to show download options. Database Client Quick Installation Guide for Linux x86 Click to show summary. Click to show download options. Database Client Quick Installation Guide for Linux x86-64 Click to show summary. Click to show download options. Database Client Installation Guide for Linux Click to show summary. Click to show download options. Database Quick Installation Guide for IBM: Linux on System z Click to show summary. Click to show download options. Database Client Quick Installation Guide for IBM: Linux on System z Click to show summary. Click to show download options. Grid Infrastructure Installation Guide for Linux Click to show summary. Click to show download options. Real Application Clusters Installation Guide for Linux and UNIX Click to show summary. Click to show download options. Database Client Release Notes for IBM: Linux on POWER Systems No summary available. Click to show download options. Database Client Installation Guide for IBM: Linux on POWER Systems No summary available. Click to show download options. Microsoft Windows Installation Guides Release Notes for Microsoft Windows Click to show summary. Click to show download options. Database Quick Installation Guide for Microsoft Windows (32-Bit) Click to show summary. Click to show download options. Database Quick Installation Guide for Microsoft Windows x64 (64-Bit) Click to show summary. Click to show download options. Database Installation Guide for Microsoft Windows Click to show summary. Click to show download options. Database Client Quick Installation Guide for Microsoft Windows (32-Bit) Click to show summary. Click to show download options. Database Client Quick Installation Guide for Microsoft Windows x64 (64-Bit) Click to show summary. Click to show download options. Database Client Installation Guide for Microsoft Windows Click to show summary. Click to show download options. Grid Infrastructure Installation Guide for Microsoft Windows x64 (64-Bit) Click to show summary. Click to show download options. Real Application Clusters Installation Guide for Microsoft Windows x64 (64-Bit) Click to show summary. Click to show download options. Solaris Installation Guides Release Notes for Oracle Solaris Click to show summary. Click to show download options. Database Quick Installation Guide for Oracle Solaris on SPARC (64-Bit) Click to show summary. Click to show download options. Database Quick Installation Guide for Oracle Solaris on x86-64 (64-Bit) Click to show summary. Click to show download options. Database Installation Guide for Oracle Solaris Click to show summary. Click to show download options. Database Client Quick Installation Guide for Oracle Solaris on SPARC (64-Bit) Click to show summary. Click to show download options. Database Client Quick Installation Guide for Oracle Solaris on x86-64 (64-Bit) Click to show summary. Click to show download options. Database Client Installation Guide for Oracle Solaris Click to show summary. Click to show download options. Grid Infrastructure Installation Guide for Oracle Solaris Click to show summary. Click to show download options. Real Application Clusters Installation Guide for Linux and UNIX Click to show summary. Click to show download options. HP-UX Installation Guides Release Notes for HP-UX Click to show summary. Click to show download options. Database Quick Installation Guide for HP-UX Itanium Click to show summary. Click to show download options. Database Quick Installation Guide for HP-UX PA-RISC (64-Bit) Click to show summary. Click to show download options. Database Installation Guide for HP-UX Click to show summary. Click to show download options. Database Client Installation Guide for HP-UX Click to show summary. Click to show download options. Database Client Quick Installation Guide for HP-UX Itanium Click to show summary. Click to show download options. Database Client Quick Installation Guide for HP-UX PA-RISC (64-Bit) Click to show summary. Click to show download options. Grid Infrastructure Installation Guide for HP-UX Itanium Click to show summary. Click to show download options. Real Application Clusters Installation Guide for Linux and UNIX Click to show summary. Click to show download options. AIX Installation Guides Release Notes for IBM AIX on POWER Systems (64-Bit) Click to show summary. Click to show download options. Database Quick Installation Guide for IBM AIX on POWER Systems (64-Bit) Click to show summary. Click to show download options. Database Installation Guide for IBM AIX on POWER Systems (64-Bit) Click to show summary. Click to show download options. Database Client Quick Installation Guide for IBM AIX on POWER Systems (64-Bit) Click to show summary. Click to show download options. Database Client Installation Guide for IBM AIX on POWER Systems (64-Bit) Click to show summary. Click to show download options. Grid Infrastructure Installation Guide for IBM AIX on POWER Systems (64-Bit) Click to show summary. Click to show download options. Real Application Clusters Installation Guide for Linux and UNIX Click to show summary. Click to show download options. Fujitsu BS2000/OSD Installation Guides Database Installation and Administration Guide for Fujitsu BS2000/OSD No summary available. Click to show download options. User's Guide for Fujitsu BS2000/OSD No summary available. Click to show download options. Apple Mac OS X Client Release Notes for Apple Mac OS X No summary available. Click to show download options. Database Client Installation Guide for Apple Mac OS X No summary available. Click to show download options. Supplementary Installation Guides Products installed separately from the database. Database Gateway for APPC Installation and Configuration Guide for AIX 5L Based Systems (64-Bit), HP-UX Itanium, Solaris Operating System (SPARC 64-Bit), Linux x86, and Linux x86-64 Click to show summary. Click to show download options. Database Gateway for APPC Installation and Configuration Guide for Microsoft Windows Click to show summary. Click to show download options. Database Gateway for IMS, VSAM, and Adabas Installation and Configuration Guide for AIX 5L Based Systems (64-Bit), HP-UX Itanium, Solaris Operating System (SPARC 64-Bit), Linux x86, and Linux x86-64 Click to show summary. Click to show download options. Database Gateway for IMS, VSAM, and Adabas Installation and Configuration Guide for Microsoft Windows Click to show summary. Click to show download options. Database Gateway Installation and Configuration Guide for AIX 5L Based Systems (64-Bit), HP-UX Itanium, Solaris Operating System (SPARC 64-Bit), Linux x86, and Linux x86-64 Click to show summary. Click to show download options. Database Gateway Installation and Configuration Guide for Microsoft Windows Click to show summary. Click to show download options. Warehouse Builder Installation and Administration Guide Click to show summary. Click to show download options. Database Examples Installation Guide Click to show summary. Click to show download options.

Tuesday, June 23, 2015

Oracle Database 11g RMAN BACKUP & RESTORE STEPS

RMAN BACKUP & RESTORE STEPS Contents Overview 2 1. View Current RMAN Configuration 2 2. Change Few RMAN Configuration Parameters 3 3. Backup Oracle Database 4 4. Assign Backup TAG Name for Quick Identification 5 5. Change Oracle RMAN Backup File Name Format 6 6. Compress a RMAN Backup 7 7. View all RMAN Backups 8 8. RMAN Restore Operations 9 Overview Using Oracle RMAN, you can take a hot backup for your database, which will take a consistent backup even when your DB is up and running. RMAN executable will be in ORACLE_HOME/bin location. RMAN provides you a way to backup, restore and recover oracle database. RMAN is server managed backup and recovery. RMAN works like sqlplus. Just like sqlplus is the client program and the oracle database is the server program Similarly RMAN is the client program and the oracle database is the server program . To connect to the db using RMAN ,First we have to export ORACLE_SID= cd $ORACLE_HOME/bin $rman target / RMAN > Note: Just like we give sqlplus sys as sysdba , here we don’t have to give sys as sysdba because RMAN can connect only as sys user) 1. View Current RMAN Configuration Before we take the backup, we have to configure certain RMAN parameters. For example, how long you want to retain the RMAN backup, etc. Before we modify any configuration, execute the following command to view all current RMAN configuration settings. To connect to RMAN, do the following from command line. This will take you to RMAN> command prompt, from here you can execute all RMAN commands. $ rman target / Recovery Manager: Release 10.2.0.3.0 - Production on Sat Aug 10 11:21:29 2013 Copyright (c) 1982, 2005, Oracle. All rights reserved. connected to target database: DEVDB (DBID=821773) RMAN> To view current RMAN configurations, execute “show all”. RMAN> SHOW ALL; using target database control file instead of recovery catalog RMAN configuration parameters are: CONFIGURE RETENTION POLICY TO RECOVERY WINDOW OF 2 DAYS; CONFIGURE BACKUP OPTIMIZATION ON; CONFIGURE DEFAULT DEVICE TYPE TO DISK; CONFIGURE CONTROLFILE AUTOBACKUP ON; CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO "/backup/rman/ctl_%F"; CONFIGURE DEVICE TYPE DISK BACKUP TYPE TO COMPRESSED BACKUPSET PARALLELISM 2; CONFIGURE DATAFILE BACKUP COPIES FOR DEVICE TYPE DISK TO 1; CONFIGURE ARCHIVELOG BACKUP COPIES FOR DEVICE TYPE DISK TO 1; CONFIGURE CHANNEL DEVICE TYPE DISK FORMAT "/backup/rman/full_%u_%s_%p" MAXPIECESIZE 2048 M; CONFIGURE MAXSETSIZE TO UNLIMITED; CONFIGURE ENCRYPTION FOR DATABASE OFF; CONFIGURE ENCRYPTION ALGORITHM 'AES128'; CONFIGURE ARCHIVELOG DELETION POLICY TO NONE; CONFIGURE SNAPSHOT CONTROLFILE NAME TO '/u01/app/oracle/product/10.2.0/dbs/snapcf_devdb.f'; # default As you see above, it displays various RMAN parameters and their current values. 2. Change Few RMAN Configuration Parameters Location: One of the important configuration parameters to set will be, where you want to save the RMAN backup. In the following example, I’m settting the RMAN backup loacation as “/backup/rman/” RMAN> CONFIGURE CHANNEL DEVICE TYPE DISK FORMAT '/backup/rman/full_%u_%s_%p'; Retention Period: Next, you should specify how long you want to retain the backup for. When RMAN takes a backup, it automatically deletes all the old backups that are older than the retention period. In the following example, I’m setting the retention period as 7 days, which will keep the DB backup for a week. RMAN> CONFIGURE RETENTION POLICY TO RECOVERY WINDOW OF 7 DAYS; Verify that the above two changes are done. RMAN> SHOW ALL; .. CONFIGURE CHANNEL DEVICE TYPE DISK FORMAT '/backup/rman/full_%u_%s_%p'; CONFIGURE RETENTION POLICY TO RECOVERY WINDOW OF 7 DAYS; Clear a Parameter: If you want to clear a parameter and set its value to default, use CLEAR at the end of the configuration as shown below. RMAN> CONFIGURE RETENTION POLICY CLEAR; In this example, since we cleared the retention policy’s value, it was set to the default value, which is 1. So, the retention policy is set to 1 day as shown below. RMAN> SHOW ALL; CONFIGURE RETENTION POLICY TO REDUNDANCY 1; # default 3. Backup Oracle Database Make sure the directory mentioned in the CHANNEK DEVICE TYPE DISK FORMAT is created. i.e /backup/rman/ $ mkdir -p /backup/rman Currently this directory is empty. We’ll see what this has after the backup is taken. $ ls -l /backup/rman total 0 We can take a backup using image copy or in backup set. It is strongly recommended to use RMAN backup sets to backup the database. RMAN stores the backup in backup sets, which are nothing but whole bunch of files which contains the backed-up data. Only RMAN understands the format of these files. So, if you backup an Oracle DB using RMAN, only RMAN knows how to read the backup and restore it. Typically we’ll use “BACKUP AS BACKUPSET” to backup a database. So, to take a full backup of the database without the archive logs, do the following. RMAN> BACKUP AS BACKUPSET DATABASE To take a full backup of the database with the archive logs, do the following: RMAN> BACKUP AS BACKUPSET DATABASE PLUS ARCHIVELOG; You can also take a backup of only a specific table space. The following example takes backup of only PRD01 tablespace. RMAN> BACKUP AS BACKUPSET TABLESPACE PRD01; The RMAN backup output will be something similar to the following: RMAN> BACKUP AS BACKUPSET DATABASE Starting backup at 10-AUG-13 using target database control file instead of recovery catalog allocated channel: ORA_DISK_1 channel ORA_DISK_1: sid=193 devtype=DISK allocated channel: ORA_DISK_2 channel ORA_DISK_2: sid=192 devtype=DISK channel ORA_DISK_1: starting full datafile backupset channel ORA_DISK_1: specifying datafile(s) in backupset input datafile fno=00025 name=/u03/oradata/devdb/devuser07.dbf input datafile fno=00003 name=/u02/oradata/devdb/temp01.dbf channel ORA_DISK_1: starting piece 1 at 10-AUG-13 channel ORA_DISK_2: starting full datafile backupset channel ORA_DISK_2: specifying datafile(s) in backupset input datafile fno=00008 name=/u03/oradata/devdb/devusers05.dbf channel ORA_DISK_2: starting piece 1 at 10-AUG-13 ... .. piece handle=/backup/rman/full_4dogpd0u_4237_1 tag=TAG20130808T114846 comment=NONE channel ORA_DISK_1: backup set complete, elapsed time: 00:00:03 Finished backup at 10-AUG-13 ... Starting Control File and SPFILE Autobackup at 10-AUG-13 piece handle=/backup/rman/ctl_c-758818131-20130808-00 comment=NONE Finished Control File and SPFILE Autobackup at 10-AUG-13 Once the backup is completed, do an ls on the /backup/rman directory, you’ll now see RMAN backup files. $ ls -l /backup/rman total 14588 -rw-r----- 1 oracle dba 14585856 Aug 8 11:48 ctl_c-758818131-20130808-00 -rw-r----- 1 oracle dba 327680 Aug 8 11:48 full_4dogpd0u_4237_1 Note: Once a backup is taken, to view all available database backups from RMAN, you need to use “list” command that is shown further down in one of the examples. While this may be obvious, it is worth repeating again: Since we are taking hotbackup, the Oracle database can be up and running. Make sure your Oracle database is running before you execute any of the above RMAN backup commands. 4. Assign Backup TAG Name for Quick Identification If you are taking lot of backups, it will be easier to assign a tag to a particular backup, which we’ll later use during Oracle recovery (or while using list command to view it). The following example assign a backup tag called “WEEEKLY_PRD01_TBLS_BK_ONLY” to this particular backup. RMAN> BACKUP AS BACKUPSET TAG 'WEEEKLY_PRD01_TBLS_BK_ONLY' TABLESPACE PRD01; Starting backup at 10-AUG-13 using channel ORA_DISK_1 using channel ORA_DISK_2 channel ORA_DISK_1: starting full datafile backupset channel ORA_DISK_1: specifying datafile(s) in backupset input datafile fno=00002 name=/u03/oradata/devdb/PRD01_1.dbf channel ORA_DISK_1: starting piece 1 at 10-AUG-13 channel ORA_DISK_1: finished piece 1 at 10-AUG-13 piece handle=/backup/rman/full_4fogpdb3_4239_1 tag=WEEEKLY_PRD01_TBLS_BK_ONLY comment=NONE channel ORA_DISK_1: backup set complete, elapsed time: 00:00:01 Finished backup at 10-AUG-13 Starting Control File and SPFILE Autobackup at 10-AUG-13 piece handle=/backup/rman/ctl_c-758818131-20130808-01 comment=NONE Finished Control File and SPFILE Autobackup at 10-AUG-13 Once the backup is finished, if you view the files from rman directory, you’ll not see the tag name here. Tag name is used only from RMAN repositories to view and restore backups. So, now you see there are more files in this directory, as we’ve taken couple of backups. $ ls -l /backup/rman/ total 29176 -rw-r----- 1 oracle dba 14585856 Aug 8 11:48 ctl_c-758818131-20130808-00 -rw-r----- 1 oracle dba 14585856 Aug 8 11:54 ctl_c-758818131-20130808-01 -rw-r----- 1 oracle dba 327680 Aug 8 11:48 full_4dogpd0u_4237_1 -rw-r----- 1 oracle dba 327680 Aug 8 11:54 full_4fogpdb3_4239_1 5. Change Oracle RMAN Backup File Name Format If you want the backup files itself will be in a specific format, you need to change the format in the RMAN configuration as shown below. In this example, we’ve appended the tag “full_devdb_bk_” prefix to all our backup files. RMAN> CONFIGURE CHANNEL DEVICE TYPE DISK FORMAT "/backup/rman/full_devdb_bk_%u_%s_%p" MAXPIECESIZE 2048 M; Now, let us take another backup with this modified configuration. RMAN> BACKUP AS BACKUPSET TAG 'WEEEKLY_PRD01_TBLS_BK_ONLY' TABLESPACE PRD01; RMAN> BACKUP AS BACKUPSET TAG 'WEEEKLY_PRD01_TBLS_BK_ONLY' TABLESPACE PRD01; Now when you view the RMAN files, you’ll see the new RMAN backup file has this new file name format for the files. This is easier to identify certain information about the backup just by looking at the file names. $ ls -l /backup/rman/ total 43764 -rw-r----- 1 oracle dba 14585856 Aug 8 11:48 ctl_c-758818131-20130808-00 -rw-r----- 1 oracle dba 14585856 Aug 8 11:54 ctl_c-758818131-20130808-01 -rw-r----- 1 oracle dba 14585856 Aug 8 11:56 ctl_c-758818131-20130808-02 -rw-r----- 1 oracle dba 327680 Aug 8 11:48 full_4dogpd0u_4237_1 -rw-r----- 1 oracle dba 327680 Aug 8 11:54 full_4fogpdb3_4239_1 -rw-r----- 1 oracle dba 327680 Aug 8 11:55 full_devdb_bk_4hogpdef_4241_1 6. Compress a RMAN Backup If you are taking a backup of a big database, you’ll notice that the RMAN backup files are bigger (almost same size as the database itself). So, for most situation, you should always tak ea compressed backup of the database. The following example take a compressed backup of the tablepsace PRD01. RMAN> BACKUP AS COMPRESSED BACKUPSET TAG 'WEEEKLY_PRD01_TBLS_BK_ONLY' TABLESPACE PRD01; When you view the backup files from the file system level, you will not see any .gz (or .zip, or .bz2) to indicate that the RMAN has taken a compressed backup. The file naming convention will still follow the same as a non-compressed backup. $ ls -l /backup/rman/ total 58352 -rw-r----- 1 oracle dba 14585856 Aug 8 11:48 ctl_c-758818131-20130808-00 -rw-r----- 1 oracle dba 14585856 Aug 8 11:54 ctl_c-758818131-20130808-01 -rw-r----- 1 oracle dba 14585856 Aug 8 11:56 ctl_c-758818131-20130808-02 -rw-r----- 1 oracle dba 14585856 Aug 8 11:59 ctl_c-758818131-20130808-03 -rw-r----- 1 oracle dba 327680 Aug 8 11:48 full_4dogpd0u_4237_1 -rw-r----- 1 oracle dba 327680 Aug 8 11:54 full_4fogpdb3_4239_1 -rw-r----- 1 oracle dba 327680 Aug 8 11:55 full_devdb_bk_4hogpdef_4241_1 -rw-r----- 1 oracle dba 127680 Aug 8 11:59 full_devdb_bk_4jogpdl0_4243_1 Note: The way to tell whether RMAN has take a compressed backup or not, it by looking at the size, and by looking at the output of the RMAN “list” command which is shown in one of the section below. 7. View all RMAN Backups To view all the RMAN backups, execute “list backup summary” as shown below. RMAN> LIST BACKUP SUMMARY; Using target database control file instead of recovery catalog List of Backups =============== Key TY LV S Device Type Completion Time #Pieces #Copies Compressed Tag ------- -- -- - ----------- --------------- ------- ------- ---------- --- .. 4215 B F A DISK 10-AUG-13 1 1 NO TAG20130808T114846 4216 B F A DISK 10-AUG-13 1 1 NO TAG20130808T114849 4217 B F A DISK 10-AUG-13 1 1 NO WEEEKLY_PRD01_TBLS_BK_ONLY 4218 B F A DISK 10-AUG-13 1 1 NO TAG20130808T115413 4219 B F A DISK 10-AUG-13 1 1 NO WEEEKLY_PRD01_TBLS_BK_ONLY 4220 B F A DISK 10-AUG-13 1 1 NO TAG20130808T115600 4221 B F A DISK 10-AUG-13 1 1 YES WEEEKLY_PRD01_TBLS_BK_ONLY As you see above, it displays various information about the backups. In the above output, it show 7 RMAN backups. The last column shows the “Tag” that we specified when we took a backup. If we didn’t specify any TAG, RMAN creates a default tag with the prefix “TAG” followed by some numbers. You can also see that under the column “Compressed”, the last RMAN backup shows “YES”, which indicates that out of all the 7 RMAN backups, only the last one was compressed. Also, when the RMAN backup is running, if you want to see the process, you can query the V$RMAN_STATUS table from sql*plus as shown below. SQL> SELECT OPERATION, STATUS, MBYTES_PROCESSED, START_TIME, END_TIME from V$RMAN_STATUS; OPERATION STATUS MBYTES_PROCESSED START_TIM END_TIME --------------------------------- ----------------------- ---------------- --------- --------- CONTROL FILE AND SPFILE AUTOBACK COMPLETED 14 07-NOV-12 07-NOV-12 RMAN COMPLETED 0 07-NOV-12 07-NOV-12 RESTORE VALIDATE COMPLETED 0 07-NOV-12 07-NOV-12 RMAN COMPLETED WITH ERRORS 0 07-NOV-12 07-NOV-12 DELETE COMPLETED 0 08-NOV-12 08-NOV-12 BACKUP COMPLETED 0 10-AUG-13 10-AUG-13 CONTROL FILE AND SPFILE AUTOBACK COMPLETED 14 10-AUG-13 10-AUG-13 RMAN COMPLETED WITH ERRORS 1832 10-AUG-13 10-AUG-13 RMAN COMPLETED 0 10-AUG-13 10-AUG-13 ... 8. RMAN Restore Operations In an RMAN restore operation, you select files to be restored and then run the RESTORE command. Typically, you restore files in preparation for media recovery. You can restore the following types of files: ■ Database (all datafiles) ■ Tablespaces ■ Control files ■ Archived redo logs ■ Server parameter files Follow the steps given below to RESTORE DATABASE FROM BACKUP USING RMAN. 1. rman target / 2. startup nomount; Note : As we don’t have control file we cannot start the db in mount mode and also as we don’t have the data files we can not start the database in open mode. so now we have to restore the control files and data files from the backup. 3. RMAN > restore controlfile from '/ you can see the control files restored. 4. RMAN> alter database mount; (you don’t have to go to sqlplus prompt ,you can alter the db from RMAN prompt) 5. RMAN > restore database; (this will restore the database from the backup) (The backup should be available where the RMAN expect it to be) 6. RMAN > recover database (to recover database) 7. RMAN > alter database open resetlogs; database opened. 8. sqlplus / as sysdba 9. select name from v$database; NAME --- FIN 10. Select open_mode from v$databse; OPEN_MODE ------- READD WRITE 11. select tablespace_name from dba_tablespaces; This completes the steps to perform the backup and restore using RMAN.

Sunday, June 21, 2015

Solaris User Password Management

Forcing Users to Change Passwords There are two ways to force a user to change passwords the next time the user logs in: Force change keeping password aging rules in effect passwd -f username Force change and turn off password aging rules passwd -x 0 username Setting a Password Age Limit The -max argument to the passwd command sets an age limit for the current password. In other words, it specifies the number of days that a password remains valid. After that number of days, a new password must be chosen by the user. Once the maximum number of days have passed, the next time the user tries to login with the old password a Your password has been expired for too long message is displayed and the user is forced to choose a new password in order to finish logging in to the system. The max argument uses the following format: passwd -x max username Where: username is the login ID of the user max is one of the following values: Greater than zero. Any number greater than zero sets that number of days before the password must be changed. Zero (0). A value of zero (0) forces the user to change passwords the next time the user logs in, and it then turns off password aging. Minus one (-1). A value of minus one (-1) turns off password aging. In other words, entering passwd -x -1 username cancels any previous password aging applied to that user. For example, to force the user schweik to change passwords every 45 days, you would type the command: station1% passwd -x 45 schweik Setting Minimum Password Life The min argument to the passwd command specifies the number of days that must pass before a user can change passwords. If a user tries to change passwords before the minimum number of days has passed, a Sorry less than N days since the last change message is displayed. The min argument uses the following format: passwd -x max -n min username Where: username is the login ID of the user max is the maximum number of days a password is valid as described in the section above min is the minimum number of days that must pass before the password can be changed. For example, to force the user eponine to change passwords every 45 days, and prevent him from changing it for the first 7 days you would type the command: station1% passwd -x 45 -n 7 eponine The following rules apply to the min argument: You do not have to use a min argument or specify a minimum number of days before a password can be changed. If you do use the min argument, it must always be used in conjunction with the -max argument. In other words, in order to set a minimum value you must also set a maximum value. If you set min to be greater than max, the user is unable to change passwords at all. For example, the command passwd -x 7 -n 8 prevents the user from changing passwords. If the user tries to change passwords, the You may not change this password message is displayed. Setting the min value greater than the max value has two effects: The user is unable to change password. In this case, only someone with administer privileges could change the password. For example, in situations where multiple users share a common group password, setting the min value for that password greater than the max value would prevent any individual user from changing the group password. The password is only valid for the length of time set by the max value, but the user cannot change it because the min value is greater than the max value. Thus, there is no way for the user to prevent the password from becoming invalid at the expiration of the max time period. In effect, this prevents the user from logging in after the max time period unless an administrator intervenes. Establishing a Warning Period The warn argument to the passwd command specifies the number of days before a password reaches its age limit that users will start to seeing a Your password will expire in N days message (where N is the number of days) when they log in. For example, if a user's password has a maximum life of 30 days (set with the -max argument) and the warn value is set to 7 days, when the user logs in on the 24th day (one day past the warn value) the warning message Your password will expire in 7 days is displayed. When the user logs in on the 25th day the warning message Your password will expire in 6 days is displayed. Keep in mind that the warning message is not sent by Email or displayed in a user's console window. It is displayed only when the user logs in. If the user does not log in during this period, no warning message is given. Keep in mind that the warn value is relative to the max value. In other words, it is figured backwards from the deadline set by the max value. Thus, if the warn value is set to 14 days, the Your password will expire in N days message will begin to be displayed two weeks before the password reaches its age limit and must be changed. Because the warn value is figured relative to the max value, it only works if a max value is in place. If there is no max value, warn values are meaningless and are ignored by the system. The warn argument uses the following format: passwd -x max -w warn username Where: username is the login ID of the user. max is the maximum number of days a password is valid as described on "Setting a Password Age Limit". warn is the number of days before the password reaches its age limit that the warning message will begin to be displayed. For example, to force the user nilovna to change passwords every 45 days, and display a warning message 5 days before the password reaches its age limit you would type the command: station1% passwd -x 45 -w 5 nilovna The following rules apply to the warn argument: You do not have to use the warn argument or specify a warning message. If no warn value is set, no warning message is displayed prior to a password reaching its age limit. If you do use the warn argument, it must always be used in conjunction with the max argument. In other words, in order to set a warning value you must also set a maximum value. Note - You can also use Solstice AdminSuiteTM to set a warn value for a user's password. Turning Off Password Aging There are two ways to turn off password aging for a given user: Turn off aging while allowing user to retain current password passwd -x -1 username Force user to change password at next login, and then turn off aging passwd -x 0 username This sets the max value to either zero or -1 (see "Setting a Password Age Limit" for more information on this value). For example, to force the user mendez to change passwords the next time he logs in and then turn off password aging you would type the command: station% passwd -x 0 mendez Note - You can also use Solstice AdminSuiteTM to set this parameter for a user's password. You can also use the nistbladm command to set this value. For example, to turn off password aging for the user otsu and allow her to continue using her current password, you would type: station1% nistbladm -m `shadow=0:0:-1:0:0:0:0' [name=otsu],passwd.org_dir For additional information on using the nistbladm command, see "The nistbladm Command". Password Privilege Expiration You can set a specific date on which a user's password privileges expires. When a user's password privilege expires, that user can no longer have a valid password at all. In effect, this locks the user out of the system after the given date because after that date the user can no longer log in. For example, if you specify an expire date of December 31, 1997, for a user named pete, on January 1, 1998 he will not be able to log in under that user ID regardless of what password he uses. After each login attempt he will receive a Login incorrect message. Password Aging Versus Expiration Expiration of a user's password privilege is not the same as password aging. Password aging. A password that has not been changed for longer than the aging time limit is sometimes referred to as an expired password. But that password can still be used to log in one more time. As part of that last login process the user is forced to choose a new password. Expiration of password privilege. When a user's password privilege expires, the user cannot log in at all with any password.) In other words, it is the user's permission to log in to the network that has expired. Setting an Expiration Date Password privilege expiration dates only take effect when the user logs in. If a user is already logged in, the expiration date has no affect until the user logs out or tries to use rlogin or telnet to connect to another machine at which time the user will not be able to log in again. Thus, if you are going to implement password privilege expiration dates, you should require your users to log out at the end of each day's work session. Note - If you have Solstice AdminSuiteTM tools available, do not use nistbladm to set an expiration date. Use Solstice AdminSuiteTM tools because they are easier to use and provide less chance for error. To set an expiration date with the nistbladm command: nistbladm -m `shadow=n:n:n:n:n:n6:n' [name=login],passwd.org_dir Where: login is the user's login ID n indicates the values in the other fields of the shadow column. n6 is the date on which the user's password privilege expires. This date is entered as a number of days since January 1, 1970 (see Table 11-2). n6 can be one of the following values: Minus one (-1). A value of minus one (-1) turns off the expiration feature. If a user's password has already expired, changing this value to -1 restores (un-expires) it. If you do not want to set any expiration date, type -1 in this field. Greater than zero. A value greater than zero sets the expiration date to that number of days since 1/1/70. If you enter today's date or earlier, you immediately expire the user's password. For example, to specify an expiration date for the user pete of December 31, 1995 you would type: station1% nistbladm -m `shadow=n:n:n:n:n:9493:n' [name=pete],passwd.org_dir

Thursday, June 18, 2015

Start / Stop services in Oracle Applications R12 ( Application / Database Tier)

This post covers step by step instructions of How to Start/Stop services in Oracle Applications R12. These steps are from Online Oracle Apps DBA (11i /R12) training here (This is interactive online course over weekend with hands on exercises on installation, patching, cloning during weekdays) Assumptions Application Tier O.S. User : avisr12 (usually applmgr) Database Tier O.S. User : ovisr12 (usually oracle) R12 install base : /oracle/apps/r12/visr12 Database SID : visr12 Database Version : 11.1.0 Hostname : focusthreadr12 Operating System : Unix/Linux Apps Schema Password : apps (apps is default password) . Start-Up/Shutdown order If you are starting services then first start Database Tier services and then Application Tier Services. If you are shutting down services then first stop Application Tier services and then Database Tier Services. 1. Startup 1.1 Start Database Tier 1.1.1 Login as database tier user (ovisr12) 1.1.2 Set environment variable by running $SID_hostname.envfrom $INSTALL_BASE/db/tech_st/11.1.0 —- cd /oracle/apps/r12/visr12/db/tech_st/11.1.0 —- . visr12_focusthreadr12.com (note: dot in front) 1.1.3 Start database —- sqlplus “/as sysdba” —- SQL> startup 1.1.4 Start Database Listener (lsnrctl start $SID) —- lsnrctl start visr12 . 1.2 Start Application Tier 1.2.1 Login as application tier user (avisr12) 1.2.2 Set environment variable by running $SID_hostname.envfrom $INSTALL_BASE/apps/apps_st/appl —- cd /oracle/apps/r12/visr12/apps/apps_st/appl —- . visr12_focusthreadr12.com (note: dot in front) 1.2.3 Start Application Tier (adstrtal.sh apps/$apps_password) —- cd $ADMIN_SCRIPTS_HOME —- ./adstrtal.sh apps/apps 2. Shutdown Services 2.1 Shutdown Application Tier 2.1.1 Login as application tier user (avisr12) 2.1.2 Set environment variable by running $SID_hostname.env from $INSTALL_BASE/apps/apps_st/appl —- cd /oracle/apps/r12/visr12/apps/apps_st/appl —- . visr12_focusthreadr12.com (note: dot in front) 2.1.3 Stop Application Tier (adstpall.sh apps/$apps_password) —- cd $ADMIN_SCRIPTS_HOME —- ./adstpall.sh apps/apps . 2.2 Shutdown Database Tier 2.2.1 Login as database tier user (ovisr12) 2.2.2 Set environment variable by running $SID_hostname.env from $INSTALL_BASE/db/tech_st/11.1.0 —- cd /oracle/apps/r12/visr12/db/tech_st/11.1.0 —- . visr12_focusthreadr12.com (note: dot in front) 2.2.3 Stop database —- sqlplus “/as sysdba” —- SQL> shutdown immediate 2.2.4 Stop Database Listener (lsnrctl start $SID) —- lsnrctl stop visr12 Reference : http://onlineappsdba.com/index.php/2010/03/16/how-to-start-stop-services-in-oracle-applications-r12-application-database-tier/

Changing Maintanence Windows in R12 for Patching

How to Enable Maintance Mode In R12 APPS? E-Business Suite 11i & R12, During a patch application the recommended option is to Enable Maintenance node.When adsetmmd.sql runs, it sets the Profile Option ‘Applications Maintenance Mode’ (APPS_MAINTENANCE_MODE) to ‘MAINT’ to Enable ‘Maintenance Mode’ and to ‘NORMAL’ to Disable it.When you Enable or Disable ‘Maintenance Mode’, adadmin will execute the script. sqlplus -S apps/***** @$AD_TOP/patch/115/sql/adsetmmd.sql DISABLE sqlplus -S apps/***** @$AD_TOP/patch/115/sql/adsetmmd.sql ENABLE Determining if Maintenance Mode is Running: A quick way to verify if the Environment is on Maintenance Mode or not, is by checking the value of this Profile Option as follows: sqlplus apps/apps SQL>select fnd_profile.value('APPS_MAINTENANCE_MODE') from dual; If the query returns ‘MAINT’, then Maintenance Mode has been Enabled and the Users will not be able to Login. If the query returns ‘NORMAL’ then Maintenance Mode has been De-Activated and the Users will be able to use the application.
Reference Link http://myappsdba.com/how-to-enable-maintance-mode-in-r12-apps/ http://khurramlogix.blogspot.com/2012/01/ebs-r12-maintenance-mode-adadmin-by.html

Monday, June 15, 2015

Initialization Parameter files: PFILEs vs. SPFILEs

http://www.orafaq.com/node/5 Initialization Parameter files: PFILEs vs. SPFILEs Submitted by admin on Sun, 2003-08-03 19:29 RDBMS Server When an Oracle Instance is started, the characteristics of the Instance are established by parameters specified within the initialization parameter file. These initialization parameters are either stored in a PFILE or SPFILE. SPFILEs are available in Oracle 9i and above. All prior releases of Oracle are using PFILEs. SPFILEs provide the following advantages over PFILEs: An SPFILE can be backed-up with RMAN (RMAN cannot backup PFILEs) Reduce human errors. The SPFILE is maintained by the server. Parameters are checked before changes are accepted. Eliminate configuration problems (no need to have a local PFILE if you want to start Oracle from a remote machine) Easy to find - stored in a central location What is the difference between a PFILE and SPFILE: A PFILE is a static, client-side text file that must be updated with a standard text editor like "notepad" or "vi". This file normally reside on the server, however, you need a local copy if you want to start Oracle from a remote machine. DBA's commonly refer to this file as the INIT.ORA file. An SPFILE (Server Parameter File), on the other hand, is a persistent server-side binary file that can only be modified with the "ALTER SYSTEM SET" command. This means you no longer need a local copy of the pfile to start the database from a remote machine. Editing an SPFILE will corrupt it, and you will not be able to start your database anymore. How will I know if my database is using a PFILE or SPFILE: Execute the following query to see if your database was started with a PFILE or SPFILE: SQL> SELECT DECODE(value, NULL, 'PFILE', 'SPFILE') "Init File Type" FROM sys.v_$parameter WHERE name = 'spfile'; You can also use the V$SPPARAMETER view to check if you are using a PFILE or not: if the "value" column is NULL for all parameters, you are using a PFILE. Viewing Parameters Settings: One can view parameter values using one of the following methods (regardless if they were set via PFILE or SPFILE): The "SHOW PARAMETERS" command from SQL*Plus (i.e.: SHOW PARAMETERS timed_statistics) V$PARAMETER view - display the currently in effect parameter values V$PARAMETER2 view - display the currently in effect parameter values, but "List Values" are shown in multiple rows V$SPPARAMETER view - display the current contents of the server parameter file. Starting a database with a PFILE or SPFILE: Oracle searches for a suitable initialization parameter file in the following order: Try to use the spfile${ORACLE_SID}.ora file in $ORACLE_HOME/dbs (Unix) or ORACLE_HOME/database (Windows) Try to use the spfile.ora file in $ORACLE_HOME/dbs (Unix) or ORACLE_HOME/database (Windows) Try to use the init${ORACLE_SID}.ora file in $ORACLE_HOME/dbs (Unix) or ORACLE_HOME/database (Windows) One can override the default location by specifying the PFILE parameter at database startup: SQL> STARTUP PFILE='/oradata/spfileORCL.ora' Note that there is not an equivalent "STARTUP SPFILE=" command. One can only use the above option with SPFILE's if the PFILE you point to (in the example above), contains a single 'SPFILE=' parameter pointing to the SPFILE that should be used. Example: SPFILE=/path/to/spfile Changing SPFILE parameter values: While a PFILE can be edited with any text editor, the SPFILE is a binary file. The "ALTER SYSTEM SET" and "ALTER SYSTEM RESET" commands can be used to change parameter values in an SPFILE. Look at these examples: SQL> ALTER SYSTEM SET open_cursors=300 SCOPE=SPFILE; SQL> ALTER SYSTEM SET timed_statistics=TRUE COMMENT='Changed by Frank on 1 June 2003' SCOPE=BOTH SID='*'; The SCOPE parameter can be set to SPFILE, MEMORY or BOTH: - MEMORY: Set for the current instance only. This is the default behaviour if a PFILE was used at STARTUP. - SPFILE: update the SPFILE, the parameter will take effect with next database startup - BOTH: affect the current instance and persist to the SPFILE. This is the default behaviour if an SPFILE was used at STARTUP. The COMMENT parameter (optional) specifies a user remark. The SID parameter (optional; only used with RAC) indicates the instance for which the parameter applies (Default is *: all Instances). Use the following syntax to set parameters that take multiple (a list of) values: SQL> ALTER SYSTEM SET utl_file_dir='/tmp/','/oradata','/home/' SCOPE=SPFILE; Use this syntax to set unsupported initialization parameters (obviously only when Oracle Support instructs you to set it): SQL> ALTER SYSTEM SET "_allow_read_only_corruption"=TRUE SCOPE=SPFILE; Execute one of the following command to remove a parameter from the SPFILE: SQL> ALTER SYSTEM RESET timed_statistics SCOPE=SPFILE SID=‘*’; SQL> ALTER SYSTEM SET timed_statistics = '' SCOPE=SPFILE; Converting between PFILES and SPFILES: One can easily migrate from a PFILE to SPFILE or vice versa. Execute the following commands from a user with SYSDBA or SYSOPER privileges: SQL> CREATE PFILE FROM SPFILE; SQL> CREATE SPFILE FROM PFILE; One can also specify a non-default location for either (or both) the PFILE and SPFILE parameters. Look at this example: SQL> CREATE SPFILE='/oradata/spfileORCL.ora' from PFILE='/oradata/initORCL.ora'; Here is an alternative procedure for changing SPFILE parameter values using the above method: Export the SPFILE with: CREATE PFILE=‘pfilename’ FROM SPFILE = ‘spfilename’; Edit the resulting PFILE with a text editor Shutdown and startup the database with the PFILE option: STARTUP PFILE=filename Recreate the SPFILE with: CREATE SPFILE=‘spfilename’ FROM PFILE=‘pfilename’; On the next startup, use STARTUP without the PFILE parameter and the new SPFILE will be used. Parameter File Backups: RMAN (Oracle's Recovery Manager) will backup the SPFILE with the database control file if setting "CONFIGURE CONTROLFILE AUTOBACKUP" is ON (the default is OFF). PFILEs cannot be backed-up with RMAN. Look at this example: RMAN> CONFIGURE CONTROLFILE AUTOBACKUP ON; Use the following RMAN command to restore an SPFILE: RMAN> RESTORE CONTROLFILE FROM AUTOBACKUP;

How to run autoconfig R12 - Steps Doc ID 387859.1

Using AutoConfig to Manage System Configurations in Oracle E-Business Suite Release 12 (Doc ID 387859.1) Ref :http://swaroopdba.blogspot.com/2012/03/how-to-run-autoconfig-r12-steps.html How to run autoconfig R12 - Steps A) Running Autoconfig on R12 environment Application Tier 1. Login as user owning application tier for R12 (usually applmgr) 2. Set environment variable by executing env file $INSTALL_BASE/ apps/ apps_st/ appl/ APPL[$SID]_[$hostname].env 3. cd $ADMIN_SCRIPTS_HOME (or $INSTALL_BASE/apps/$CONTEXT_NAME/ admin/ scripts) 4. run adautocfg.sh (Autoconfig script) ./adautocfg.sh 5. Supply apps password when prompted. B) Running Autoconfig on R12 environment Database Tier 1.Login as user owning database tier for R12 (usually oracle) 2. Set environment variable by executing env file $INSTALL_BASE/ db/ tech_st/ [11.1.0 or 10.2.0]/ [$SID]_[$hostname].env 3. cd $ORACLE_HOME/ appsutil/ scripts/ $CONTEXT_NAME 4. run adautocfg.sh (Autoconfig script) ./adautocfg.sh 5. Supply apps password when prompted . . Things good to know about Autoconfig in R12 1. Autoconfig logs for R12 application tier are at $INSTALL_BASE/inst/apps/$CONTEXT_NAME/admin/log/$MMDDHHMM/adconfig.log ($INST_TOP/admin/log/[$MMDDhhmm]) 2. Autoconfig logs for R12 Database tier are at [$RDBMS_ORACLE_HOME]/appsutil/log/[$CONTEXT_NAME]/[$MMDDhhmm]/adconfig.log 3. R12 system is autoconfig enabled and uses context file stored in [INST_TOP]/appl/admin/[CONTEXT_NAME].xml (Application Tier) and [$DATABASE_ORACLE_HOME]/appsutil/[$CONTEXT_NAME].xml (Database Tier) . Related 387859.1 Using AutoConfig to Manage System Configurations in Oracle E-Business Suite Release 12 Posted by Swaroop at 05:44

Migrate Oracle E-Business Suite Release 12.2 on a Single Database Instance to a RAC Database.(Doc ID 1453213.1

Using Oracle 11g Release 2 Real Application Clusters and Automatic storage management with Oracle E-Business Suite Release 12.2 (Doc ID 1453213.1) Using Oracle 11g Release 2 Real Application Clusters and Automatic storage management with Oracle E-Business Suite Release 12.2 (Doc ID 1453213.1) To BottomTo Bottom Oracle E-Business Suite Release 12.2 has numerous configuration options that can be chosen to suit particular business scenarios, uptime requirements, hardware capability, and availability requirements. This document describes how to migrate Oracle E-Business Suite Release 12.2 to an Oracle Real Application Clusters (Oracle RAC) environment running Oracle Database 11g Release 2 (11.2.0.3 or higher). It also describes how to to use Rapid Install to install an Oracle RAC-configured Oracle E-Business Suite Release 12.2 system. Note: At present, this document applies to UNIX and Linux platforms only. If you are using Windows and want to migrate to Oracle RAC or ASM, you must follow the procedures described in the Oracle Real Application Clusters Administration and Deployment Guide 11g Release 2 (11.2) and the Oracle Database Administrator's Guide 11g Release 2 (11.2). The most current version of this document can be obtained in My Oracle Support Knowledge (MOS) Document 1453213.1. There is a change log at the end of this document. Note: Most documentation links are to the generic Oracle 11gR2 documentation. As installation documentation is platform-specific, the links provided are for Linux. You should refer to the installation documentation for your platform. A number of conventions are used in describing the Oracle E-Business Suite architecture: Convention Meaning Application tier Machines (nodes) running Forms, Web, and other services (servers). Sometimes called middle tier. Database tier Machines (nodes) running the Oracle E-Business Suite database. oracle User account that owns the database file system (database ORACLE_HOME and files). CONTEXT_NAME The CONTEXT_NAME variable specifies the name of the Applications context that is used by AutoConfig. The default is _. CONTEXT_FILE Full path to the Applications context file on the application tier or database tier. The default locations are as follows. Application tier context file: /admin/.xml Database tier context file: /appsutil/.xml APPSpwd Oracle E-Business Suite database user password. Monospace Text Represents command line text. Type such a command exactly as shown. < > Text enclosed in angle brackets represents a variable. Substitute a value for the variable text. Do not type the angle brackets. \ On UNIX or Linux, the backslash character can be entered to indicate continuation of the command line on the next screen line. This document is divided into following sections: Section 1: Overview Section 2: Environment Section 3: Install Oracle Grid Infrastructure 11gR2 Section 4: Migrate Oracle E-Business Suite Release 12.2 on a Single Database Instance to a RAC Database Section 5: Use Rapid Install to Install a RAC Configured Oracle E-Business Suite Release 12.2 system Section 6: References Appendices Section 1: Overview As of Oracle E-Business Suite Release 12.2, you have two options for deploying Oracle E-Business Suite in an Oracle RAC environment: Traditional tools (dbca) - can be used to migrate an existing an Oracle E-Business Suite Release 12.2 system to Oracle RAC. Rapid Install - can be used to configure an Oracle RAC system for use with a new Oracle E-Business Suite Release 12.2 system. Both methods include a number of common steps, such as configuring Oracle Grid and setting up shared storage. When planning to set up Oracle Real Application Clusters and shared devices, you should be familiar with Oracle Database 11gR2, and have a good knowledge of Oracle Real Application Clusters (RAC). For further information, refer to Oracle Real Application Clusters Administration and Deployment Guide 11g Release 2 (11.2). 1. Cluster Terminology You should understand the terminology used in a cluster environment. Key terms include the following. Automatic Storage Management (ASM) is an Oracle database component that acts as an integrated file system and volume manager, providing the performance of raw devices with the ease of management of a file system. In an ASM environment, you specify a disk group rather than the traditional datafile when creating or modifying a database structure such as a tablespace. ASM then creates and manages the underlying files automatically. Cluster Ready Services (CRS) is the primary program that manages high availability operations in an RAC environment. The crs process manages designated cluster resources, such as databases, instances, services, and listeners. Parallel Concurrent Processing (PCP) is an extension of the Concurrent Processing architecture. PCP allows concurrent processing activities to be distributed across multiple nodes in an Oracle RAC environment, maximizing throughput and providing resilience to node failure. Real Application Clusters (RAC) is an Oracle database technology that allows multiple machines to work on the same data in parallel, reducing processing time significantly. An Oracle RAC environment also offering resilience if one or more machines become temporarily unavailable as a result of planned or unplanned downtime. Oracle Grid Infrastructure is the new unified ORACLE_HOME for both ASM and CRS. That is, Grid Infrastructure Install replaces the Clusterware Install in Oracle Database 11gR2. For further information refer to Oracle Grid Infrastructure Installation Guide 11g Release 2 (11.2) for Linux. Section 2: Environment 2.1 Software and Hardware Configuration Refer to the relevant platform installation guides for supported hardware configurations. For example, Oracle Grid Infrastructure Installation Guide 11g Release 2 (11.2) for Linux and Oracle Real Application Clusters Installation Guide 11g Release 2 (11.2) for Linux and UNIX. The minimum software versions are as follows: Component Version Oracle E-Business Suite Release 12 12.2.x or higher Oracle Database 11.2.0.3 or higher Oracle Cluster Ready Services 11.2.0.3 or higher You can obtain the latest Oracle Database 11gR2 software from: http://www.oracle.com/technology/software/products/database/index.html Note: The Oracle Cluster Ready Services must be at a release level equal to, or greater than, the Oracle Database version. 2.2 ORACLE_HOME Nomenclature This document refers to various ORACLE_HOMEs, as follows: ORACLE_HOME Purpose SOURCE_ORACLE_HOME Database ORACLE_HOME used by Oracle E-Business Suite Release R12.2. It can be any supported version. 11g R2 ORACLE_HOME Database ORACLE_HOME installed for the Oracle 11gR2 RAC Database. 11g R2 CRS ORACLE_HOME ORACLE_HOME installed for the Oracle Database 11gR2 Cluster Ready Services (Infrastructure home). Section 3: Install Oracle Grid Infrastructure 11gR2 Installation of Oracle Grid Infrastructure 11g Release 2 is now part of the Infrastructure install, which requires an understanding of the specific type of cluster and infrastructure that are to be deployed: the selection of these is outside the scope of this document. For convenience, the general steps are outlined below, but you should use the Infrastructure documentation set as the primary reference. Note: This section should be followed for both configuration methods: manual migration and Rapid Install. Note: Refer to Appendix H Higher version of Grid Infrastructure, if you are planning to install Oracle E-Business Suite 12.2 RAC using rapid install on Oracle Database 11.2.0.4.0 or 12.1.0.1 with Grid Infrastructure. 3.1 Check Network Requirements In Oracle Database 11gR2, the grid Infrastructure install can be configured to specify address management via node addresses, names (as per older releases), or via Grid Naming Services. Regardless of the choice, nodes must satisfy the following requirements: Each node must have at least two network adapters: one for the public network interface and one for the private network interface (interconnect). For the public network, each network adapter must support the TCP/IP protocol. For the private network, the interconnect must support the user datagram protocol (UDP) using high-speed network adapters, and switches that support TCP/IP (Gigabit Ethernet or better is recommended). To improve availability, backup public and private network adapters can be configured for each node. The interface names associated with the network adapter(s) for each network must be the same on all nodes. If Grid Naming Services is not used, the following addresses must also be set up: An IP address and associated host name for each public network interface must be registered in the DNS. One unused virtual IP address (VIP) and associated virtual host name that are registered in DNS or resolved in the host file, or both, and which will be configured for the primary public network interface. The virtual IP address must be in the same subnet as the associated public interface. After installation, clients can be configured to use either the virtual host name or virtual IP address. If a node fails, its virtual IP address fails over to another node. A private IP address (and optionally a host name) for each private interface. Oracle recommends that you use private network IP addresses for these interfaces. An additional virtual IP address (VIP) and associated virtual host name for the SCAN Listener, registered in DNS. For further information, refer to the Pre-installation requirements in Oracle Grid Infrastructure Installation Guide 11g Release 2 (11.2) Linux. Note: A common mistake is to set up ntpd correctly. Refer to the Setting Network Time Protocol for Cluster Time Synchronization section in Oracle Grid Infrastructure Installation Guide. 3.2 Verify Kernel Parameters As part of the Infrastructure install, the pre-installation process checks the kernel parameters and, if necessary, creates a "fixup" script that corrects most of the common kernel parameter issues. Follow the installation instructions for running this script. Detailed hardware and OS requirements are detailed in the Advanced Installation Oracle Grid Infrastructure for a Cluster Preinstallation Tasks section of Advanced Installation Oracle Grid Infrastructure for a Cluster Pre-installation Tasks [Linux] 3.3 Set up Shared Storage The available shared storage options are either ASM or shared file system (clustered or NFS). Use of raw disk devices is only supported for upgrades. These storage options are described in the Configuring Storage for Oracle Grid Infrastructure for a Cluster and Oracle RAC section of Oracle Grid Infrastructure Installation Guide 11g Release 2 (11.2) - Configuring Storage Linux. 3.3.1 ASM Configuration With Oracle Database 11g Release 2 (11.2), Oracle ASM is part of an Oracle Grid Infrastructure installation, and ASM binaries will be installed. Key points are: Ensure the ASM disks are configured correctly, using oracleasm or another method. Refer to Oracle Automatic Storage Management Administrator's Guide 11g Release 2 (11.2) and Oracle Database 2 Day + Real Application Clusters Guide 11g Release 2 (11.2). Be aware that the Grid Infrastructure install creates a single disk group, and Rapid Install supports a only single disk group. 3.3.2 Shared File System Ensure that the database directory is mounted with required mount options as per Knowledge Document 359515.1 Mount Options for Oracle files when used with NFS on NAS devices. 3.4 Check Account Setup Configure the oracle account's environment for Oracle Clusterware and Oracle Database 11gR2, as per the Creating Groups, Users and Paths for Oracle Grid Infrastructure section of Oracle Grid Infrastructure Installation Guide 11g Release 2 (11.2) for Linux. 3.5 Configure Secure Shell on All Cluster Nodes Secure Shell configuration is covered in detail in both the Oracle Real Application Clusters Installation Guide and Oracle Grid Infrastructure Installation Guide. The Oracle Database 11gR2 installer now provides the option to automatically set up passwordless ssh connectivity, so unlike previous releases manual set up of Secure Shell is not necessary. For further details on manual set up of passwordless ssh, refer to Appendix E: How to Complete Installation Prerequisite Tasks Manually of Oracle Grid Infrastructure Installation Guide 11g Release 2 (11.2) for Linux ). 3.6 Run the Cluster Verification Utility (CVU) The installer will automatically run the Cluster Verify tool and provide fixup scripts for any OS issues. However, to check for potential issues you can also run CVU prior to installation. Install the cvuqdisk package as described in the Installing the cvuqdisk RPM for Linux section in Oracle Grid Infrastructure Installation Guide 11g Release 2 (11.2) for Linux). Use the following command to determine which pre-installation steps have been completed, and which still need to be performed: $ <11g Grid Software Stage>/runcluvfy.sh stage -pre crsinst -n Substitute <11g Grid Software Stage> with the stage location on your system. Substitute with with the names of the nodes in your cluster, separated by commas. To identify and resolve issues at this stage (rather than during install), consider adding the -fixup and -verbose options to the above command. Use the following command to check networking setup with CVU: $ <11g Grid Software Stage> /runcluvfy.sh comp nodecon -n [-verbose] Use the following command to check operating system requirements with CVU: $ <11g Software Stage> /runcluvfy.sh comp sys -n -p {crs|database} \ -osdba osdba_group -orainv orainv_group -verbose In steps 3 and 4 above, substitute <11g Grid Software Stage> with the stage location on your system. Substitute with a comma-separated list of the names of the nodes in your cluster. 3.7 Install Oracle Grid Infrastructure 11g Release 2 Use the same oraInventory location that was created during the installation of Oracle E-Business Suite Release 12; make a backup of oraInventory before installation. Start runInstaller from the Oracle Grid Infrastructure 11g Release 2 staging area, and install as per your requirements. For further information refer to the Installing Oracle Grid Infrastructure for a Cluster section of Oracle Grid Infrastructure Installation Guide 11g Release 2 (11.2) Linux. Note: Customers who have an existing Grid Infrastructure install tailored to their requirements can skip this step. Those who do not, require further information, or who are perhaps doing a test install, should refer to Appendix C for an example walk through. Confirming the Oracle Clusterware function: After installation, log in as root, and use the following command to confirm that your Oracle Clusterware installation is running correctly: $ /bin/crs_stat -t -v Successful Oracle Clusterware operation can also be verified using the following command: $ /bin/crsctl check crs CRS-4638: Oracle High Availability Services is online CRS-4537: Cluster Ready Services is online CRS-4529: Cluster Synchronization Services is online CRS-4533: Event Manager is online Section 4: Migrate Oracle E-Business Suite Release 12.2 on a Single Database Instance to a RAC Database. This section explains how to migrate Oracle E-Business Suite Release 12.2 running on a single database instance to an Oracle Real Application Cluster environment. Refer to Section 5 if you are using the Rapid Install to build a new Oracle E-Business Suite Release 12.2 system. This section is divided into following sections: 4.1: Configuration Prerequisites 4.2: Installing Oracle Database 11g Release 2 (11gR2) software 4.3: Configure Shared Storage 4.4: Listener Configuration in 11gR2 4.5: Converting single instance to RAC 4.6: Enable AutoConfig on all nodes in the cluster 4.7: Enable AutoConfig on Application Tier 4.1: Configuration Prerequisites The prerequisites for migrating a database to Oracle RAC are as follows: An existing Oracle E-Business Suite Release 12.2 non-Oracle RAC system. Your datafiles reside on shared storage. If your datafiles are on local storage, move them to shared storage and recreate the control files. You have completed Section 3 of this document. You have applied all relevant patches, as detailed in the Interoperability Notes for R12.2 MOS Knowledge Document 1623879.1. 4.2: Install the Oracle Database Software 11gR2 and Upgrade the Oracle E-Business Suite Database to 11gR2 Note: If you want to use Oracle Database 11.2.0.4.0 database go to Step 4.2.2 4.2.1 Install Oracle Database Software 11g Release 2 Take a full backup of the oraInventory directory before starting this stage, in which you will run the Oracle Universal Installer (runInstaller ) to carry out an Oracle Database Installation with Oracle RAC. In the Cluster Nodes Window, verify the cluster nodes shown for the installation. Select all the nodes included in your Oracle RAC cluster. 4.2.1.1 Install Oracle Database Software 11g Release 2 (11.2.0.3.0) To install Oracle Database 11g Release 2 software select all the nodes in cluster. Ensure that the database software is installed on all nodes in the cluster. 4.2.1.2 Apply all required database patches Ensure that all the database patches are applied. Refer to the Part B of the Apply Database Patches section of MOS Knowledge Document ID 1349240.1, Database Preparation Guidelines for an Release 12.2 Upgrade. 4.2.2 Install Oracle Database Software 11gR2 and Upgrade the Oracle E-Business Suite Database to 11gR2 Note: If you are using Oracle Database 11g Release 2 (11.2.0.4.0), then apply Patch 17429475 using the Opatch utility. To install Oracle Database 11gR2 software and upgrade an existing database to 11gR2, refer to the interoperability note, Document 1623879.1. Follow all the instructions and steps listed there except for the following: Start the new database listener (Conditional) Implement and run AutoConfig Restart Applications server processes (Conditional) Note: At this point, ensure that the Applications patching cycle has completed. If it has not, as the owner of the source administration server, run the following command to finish any in-progress adop session: $adop phase=prepare,cutover Note: Ensure the database software is installed on all nodes in the cluster. 4.3: Configure Shared Storage This document does not discuss the setup of shared storage, as there are no specific tasks in setting up ASM, NFS (NAS) or clustered storage. For ASM, refer to Oracle Database Storage Administrator's Guide11g Release 2 (11.2). For configuring shared storage, refer to the Configuring Storage for Oracle Grid Infrastructure for a Cluster and Oracle RAC section of Oracle Grid Infrastructure Installation Guide 11g Release 2 (11.2) for Linux. 4.4: Listener Configuration in 11gR2 The Listener configuration requires careful attention when converting an Oracle Database to Oracle RAC. There are two types of listener in Oracle 11gR2 Clusterware: the SCAN listener and general database listeners. The SCAN listener provides a single named access point for clients, and replaces the use of Virtual IP addresses (VIP) in client connection requests (tnsnames.ora aliases). However, connection requests can still be routed via the VIP name, as both access methods are fully supported. Note: Starting with Oracle E-Business Suite 12.2, the recommended approach is to always use the SCAN listener for connecting to the database. This is the default mode for Rapid Install. To start or stop a listener from srvctl, the following three configuration components are required: An Oracle Home from which to run lsncrtl. The listener.ora file under the TNS_ADMIN network directory. The listener name (defined in the listener.ora) to start and stop the service. The Oracle Home can either be the Infrastructure home or a database home. The TNS_ADMIN directory can be any accessible directory. The listener name must be unique within the listener.ora file. For further information refer to Oracle Real Application Clusters Administration and Deployment Guide 11g Release 2 (11.2) Three issues must be considered: Listener configuration in 11gR2 Clusterware Listener requirements for converting to Oracle RAC Listener requirements for AutoConfig For a more detailed explanation of how instances interact with listeners, refer to Appendix E. 4.4.1 Listener Requirements for Converting to Oracle RAC Tools such as rconfig, dbca, and dbua impose additional restrictions on the choice of listener. The listener must be the default Grid listener, and it must run from the Oracle Grid Infrastructure home. So if the default listener is not set up for rconfig, will need to modify it using the following command: $ srvctl modify listener -l LISTENER -p [ if default LISTENER exists ] An alternative way to do this is: $ srvctl add listener -p After conversion, you can reconfigure the listener as required. 4.4.2 Listener requirements for AutoConfig AutoConfig supports use of either a named database listener or the SCAN listener. 4.5: Convert the Oracle 11g Database to RAC There are three options for converting to Oracle RAC, which are detailed in the Converting to Oracle RAC and Oracle RAC One Node from Single-Instance Oracle Databases section of Oracle Real Application Clusters Installation Guide 11g Release 2 (11.2) for Linux and UNIX. DBCA rconfig Enterprise Manager All these will convert a database to Oracle RAC, so you may choose the one you are most familiar with. Prerequisites for conversion are as follows: A clustered Grid Infrastructure install with at least one SCAN listener address. The default listener, running from the Grid Infrastructure home. The default port can be used, or another port specified during the Grid Infrastructure install. An 11gR2 ORACLE_HOME installed on all nodes in the cluster. Shared storage - the database files can already be on shared storage (CFS or ASM), or moved to ASM as part of the conversion as in Section 3.3: Set up Shared Storage Note: If you are using rconfig for RAC conversion, ensure you have applied Patch 17429475 and ensure that the patching cycle has completed. As an example, the steps involved for Admin Managed rconfig conversion are as follows: As the oracle user, navigate to the 11gR2 directory $11gR2_ORACLE_HOME/assistants/rconfig/sampleXMLs, and open the sample file ConvertToRAC_AdminManaged.xml using a text editor such as vi. This XML sample file contains comment lines that provide instructions on how to edit the file for your specific configuration. Make a copy of the sample ConvertToRAC.xml file, and modify the parameters as necessary. Keep a note of the name of your modified copy. Note: Study the example file (and associated notes) in Appendix A before you edit your own file and run rconfig. Execute rconfig using the convert option: convert verify="ONLY" prior to performing the actual conversion. Although this is optional, it is highly recommended as the test validates the parameters and identifies any issues that need to be corrected before the conversion takes place. Note: Specify the SourceDBHome variable in ConvertToRAC_AdminManaged.xml as the Non-RAC Oracle Home (). If you wish to specify the NEW_ORACLE_HOME, start the database from the new Oracle Home. Navigate to $11gR2_ORACLE_HOME/bin, and run rconfig as follows: Note: Before running rconfig, ensure that the local_listener initialization parameter is set to NULL. $ ./rconfig The rconfig command will perform the following tasks: Migrate the database to ASM storage (if ASM is specified as the storage option in the configuration XML file). Create database instances on all nodes in the cluster. Configure the listener and NetService entries. Configure and register the CRS resources. Start the instances on all nodes in the cluster. 4.5.1 Post Migration Steps 4.5.1.1 Database in Archivelog mode The conversion tools may change some configuration options. Most notably, your database will now be in archivelog mode, regardless of whether it was prior to the conversion. If you do not want to use archivelog mode, perform the following steps: Mount but do not open the database, using the startup mount command. Use the command alter database noarchivelog to disable archiving. Shut down the database using the shutdown immediate command. Start up the database using the startup command. For further details of how to control archiving, refer to Oracle Database Administrator's Guide 11g Release 2 (11.2). 4.5.1.2 Listener Configuration When converting to Oracle RAC, whichever tool was used will have used the Grid Local Listener (LISTENER) for the actual conversion. It is recommended to use Oracle E-Business Suite local listeners along with the SCAN listener. Configure the Oracle E-Business Suite local listeners on all nodes using the same port as used for the single instance. 4.5.1.2.1 Configure Oracle E-Business Suite Local Listener Create a directory under <11gR2_ORACLE_HOME>/network/admin, using the new instance name. For example, if your database name is VISRAC and you want to use "vis" as the instance prefix, create the directory as vis1_. Copy the listener.ora and tnsnames.ora from /network/admin/ to $ORACLE_HOME/network/admin/. Modify the listener and tnsnames to point to the New Oracle Home and SID. Ensure that the _Local alias exists in the tnsnames.ora, otherwise create the alias. Start the listeners on all nodes. Log on to the database and set the local listener parameter to _local, then repeat the following on all nodes for each instance: $ sqlplus / as sysdba SQL>alter system set local_listener = scope=both sid=' 4.6. Enable AutoConfig on All Database Nodes 4.6.1 Steps to Perform On All Oracle RAC Nodes Ensure that you have applied the Oracle E-Business Suite patches listed in the prerequisites section Execute $AD_TOP/bin/admkappsutil.pl on the applications tier to generate an appsutil.zip file for the database tier. Copy (e.g. via ftp) the appsutil.zip file to the database tier 11g R2_ORACLE_HOME. Unzip the appsutil.zip file to create the appsutil directory in the 11g R2_ORACLE_HOME. Copy the jre directory from SOURCE_ORACLE_HOME>/appsutil to 11gR2_ORACLE_HOME>/appsutil. Set the following environment variables: ORACLE_HOME =<11g R2_ORACLE_HOME> LD_LIBRARY_PATH = <11gR2 _ORACLE_HOME>/lib, <11gR2 _ORACLE_HOME>/ctx/lib ORACLE_SID = PATH= $PATH:$ORACLE_HOME/bin; TNS_ADMIN = $ORACLE_HOME/network/admin/ As the APPS user, run the following command on the primary node to de-register the current configuration: SQL>exec fnd_conc_clone.setup_clean; From the 11gR2 ORACLE_HOME/appsutil/bin directory, create an instance-specific XML context file by executing the command: $ adbldxml.pl appsuser= appspass= Provide the SCAN name and SCAN Port when prompted. Set the value of s_virtual_hostname to point to the virtual hostname for the database host, by editing the database context file $ORACLE_HOME/appsutil/_hostname.xml. From the 11gR2 ORACLE_HOME/appsutil/bin directory, execute AutoConfig on the database tier by running the adconfig.pl script. Rerun AutoConfig on all nodes. 4.6.2 Shut Down Instances and Listeners Use the following commands: $ srvctl stop listener $ srvctl stop database -d 4.6.3 Update the Server Parameter File Settings After the Oracle RAC conversion, you will have a central server parameter file (spfile). It is important to understand the Oracle RAC specific changes that were introduced by AutoConfig, and to ensure that the context file is in sync with the database initialization parameters. The affected parameters are listed in the RAC template under 11gR2_ORACLE_HOME/appsutil/template/afinit_db112RAC.ora. They are also listed below. Many will have been set by the conversion, and others are likely to be set by customers for non-RAC related reasons. service_names - Oracle E-Business Suite customers may well have a variety of services already set. You must ensure that service_names includes %s_dbService% [database name] across all instances. local_listener - If you are using SRVCTL to manage your database, the installation guide recommends leaving this unset as it is dynamically set during instance start up. However, using the AutoConfig _local alias will also work. If you are using a non-default listener, then this parameter must be set to _local. remote_listener - If you are using AutoConfig to manage your connections, then the remote_listener must be set to the _remote AutoConfig alias. These six parameters will all have been set as part of the conversion. The following context variables should be updated to be in sync with the database: cluster_database cluster_database_instances undo_tablespace instance_name instance_number thread 4.6.4 Update the New listener.ora If you intend to manage an Oracle E-Business Suite database with SRVCTL, you must perform the following additional steps: Note: If you are using a shared Oracle Home then TNS_ADMIN cannot be shared as the directory path must be same on all nodes.See Appendix F for an example of how to use SRVCTL to manage listeners in a shared Oracle Home. If you wish to use the port allocated to the default listener, stop and remove the default listener. Add on Oracle E-Business Suite listener using the following commands: $ srvctl add listener -l -o <11gR2 ORACLE_HOME> -p $ srvctl setenv listener -l -T TNS_ADMIN= $ORACLE_HOME/network/admin Note: If registering the listener with Cluster Services failed with an CRS-0254 authorization failure error, refer to the Known Issues section. On each node, add the AutoConfig listener.ora as an ifile in the $ORACLE_HOME/network/admin/listener.ora. On each node, add the AutoConfig tnsnames.ora as an ifile in the $ORACLE_HOME/network/admin/tnsnames.ora. On each node, add the AutoConfig sqlnet.ora as an ifile in the $ORACLE_HOME/network/admin/sqlnet.ora Add TNS_ADMIN to the database using the following command: $ srvctl setenv database -d -T TNS_ADMIN= $ORACLE_HOME/network/admin Start up the database instances and listeners on all nodes. The database can now be managed using SRVCTL. 4.7. Establish the Oracle E-Business Suite Environment for Oracle RAC 4.7.1 Preparatory Steps Note: At this point, ensure that the Applications patching cycle has completed. If it has not, as the owner of the source administration server, run the following command to finish any in-progress adop session: $adop phase=prepare,cutover Perform the following steps on all application tier nodes: Source the Oracle E-Business Suite environment. On both the Run and Patch file systems, edit INSTANCE_NAME= and PORT=(if changed)in $TNS_ADMIN/tnsnames.ora to set up a connection to one of the instances in the Oracle RAC environment. Repeat this for all aliases including the _patch alias. Confirm that you are able to connect to one of the instances in the Oracle RAC environment from the RUN file system. On both the Run and Patch file systems, edit the context variable s_apps_jdbc_patch_connect_descriptor and modify INSTANCE_NAME to be one of the RAC instances in the CONNECT_DATA parameter value in the context file. For example : jdbc:oracle:thin:@(DESCRIPTION=(ADDRESS=(PROTOCOL=tcps)(HOST=)(PORT=))(CONNECT_DATA=(SERVICE_NAME=ebs_patch)(INSTANCE_NAME=)) Run AutoConfig on both the RUN and PATCH file system using the command: $ $AD_TOP/bin/adconfig.sh contextfile=$INST_TOP/appl/admin/ Note : AutoConfig will fail because adgentns.pl requires a Patch Edition, which does not exist yet. Ignore this error. For more information on AutoConfig, refer to the Technical Configuration section of the Oracle E-Business Suite Setup Guide Release 12.2 Edit all aliases (two_task and patch) in the tnsnames.ora on the Patch file system to set up a connection to one of the RAC instance. Execute the following commandto sync the Run and Patch file system: $ adop phase=prepare,cutover Check the $INST_TOP/admin/log/ AutoConfig log file for errors. Source the environment by using the latest environment file generated. Verify the tnsnames.ora and listener.ora files in the $INST_TOP/ora/10.1.2/network/admin directory (in both Run and Patch File systems) , and the jdbc URL in $FMW_HOME/user_projects/domain/EBS_domain_/config/jdbc/EBSDataSource--jdbc.xml. Ensure that the correct TNS aliases have been generated for load balancing and failover in each of these files, and that all the aliases are defined using the virtual hostnames. In the dbc file located at $FND_SECURE, ensure that the parameter APPS_JDBC_URL is configured with all of the instances in the environment, and that load_balance is set to YES. NOTE : To Setup Parallel Concurrent Processing follow Appendix I 4.7.2 Set Up Load Balancing The steps in this section describe how to implement load balancing for the Oracle E-Business Suite database connections. Note: As in other steps, ensure applications patching cycle is complete. Note: After setting TWO_TASK to the load balancing alias, the ADOP cleanup and cutover phases will fail. In order to workaround this problem: ADOP Cleanup: Copy the adalldefaults.txt file from $APPL_TOP/admin// to the $APPL_TOP/admin/ directory on RUN file system. Rerun the ADOP cutover. Implement load balancing across the Oracle E-Business Suite database connections: Using the Context Editor (via the Oracle Applications Manager interface), modify the variables as follows: To load-balance the Oracle Forms database connections, set the value of "Tools OH TWO_TASK" (s_tools_twotask) to point to the _balance alias generated in the tnsnames.ora file. To load-balance the Self-Service (HTML-based) database connections, set the value of "iAS OH TWO_TASK" (s_weboh_twotask) and "Apps JDBC Connect Alias" (s_apps_jdbc_connect_alias) to point to the _balance alias generated in the tnsnames.ora file. Execute AutoConfig by running the command: $ $AD_TOP/bin/adconfig.sh contextfile=$INST_TOP/appl/admin/ Restart the Oracle E-Business Suite processes using the new scripts generated by AutoConfig. Ensure that the value of the profile option "Application Database ID" is set to the dbc file name generated in $FND_SECURE. Note: If you are adding a new node to the Application Tier, repeat all the above steps to set up load balancing on the new Application Tier node. Section 5: Use Rapid Install to Install a RAC Configured Oracle E-Business Suite Release 12.2 System Oracle E-Business Suite Release 12.2 introduces Real Applications Cluster database installation using Rapid Install. This allows for a number of different configuration options, including shared Oracle Home and both ASM and shared file system database storage. This part of the document is divided into following sections: 5.1: Configuration Prerequisites 5.2: Install Oracle E-Business Suite Release 12.2 with Oracle Database 11gR2 on Cluster Nodes 5.1: Configuration Prerequisites Oracle E-Business Suite Release 12.2 with an Oracle Real Application Clusters (RAC) database supports various different configurations. The prerequisites for these are divided into following: 5.1..1 Cluster Prerequisties 5.1.2 Shared File System Prerequisties 5.1.3 Shared Oracle Home Prerequisites 5.1.4 Database Software Install Prequisites 5.1.1 Cluster Prequisities NOTE: If you have installed Oracle Grid Infrastructure 11.2.0.4 or higher, refer to Appendix H for known issues and workarounds. Ensure that you have already installed the Oracle Grid infrastructure as per Section 3. Ensure that cluster services are up and running, and in particular the SCAN_LISTENER and LISTENER. $ $CRS_HOME/bin/crs_stat 5.1.2 Shared File System Prequisties Shared storage configuration was discussed in Section 3. For ASM, verify that datagroup is created and sized appropriately for the Oracle E-Business Suite database install. The values shown in the following table for Free_MB should be greater than, or equal to, your required size. $ $CRS_HOME/bin/asmcmd ASMCMD> lsdg State Type Rebal Sector Block AU Total_MB Free_MB Req_mir_free_MB Usable_file_MB Offline_disks Voting_files Name MOUNTED EXTERN N 512 4096 1048576 244995 244547 0 244547 0 Y DATA 5.1.3 Shared Oracle Home Prequisities Rapid Install supports a shared Oracle Home install. The Oracle Home directory should be mounted on all nodes. Rapid Install checks availability of the directory. If you plan to use Shared Oracle Home, ensure that the database directory is mounted with required mount options and shared across all of the cluster nodes as per Knowledge Document 359515.1, Mount Options for Oracle files when used with NFS on NAS devices. For example, the mount options for Linux x86-64 are as follows: rw,bg,hard,nointr,rsize=32768, wsize=32768,tcp,vers=3, timeo=600, actimeo=0 Note: Rapid Install does not currently support installing the Oracle Home into an ACFS [ASM based] File System. 5.1.4 Database Software Install Prerequisites Note:If you are planning to install Oracle E-Business Suite with a different user (other than grid user), ensure that asmadmin and asmdba groups are assigned to the grid user. Refer to the Oracle ASM Groups for Job Role Separation Installations section of Oracle Grid Infrastructure Installation Guide 11g Release 2 (11.2) for Linux Refer to Appendix G for an example of creating users and groups. If you are planning to use a different user for the Database software, the following additional steps are required. For further information, refer to Oracle Grid Infrastructure Installation Guide 11g Release 2 for Linux.(11.2). If you are using ASM, use the following command to add asmdba to the oracle user's groups: $ /usr/bin/usermod -G dba,asmdba,asmadmin Rapid Install uses asmcmd, which is a command-line utility that you can use to manage Oracle ASM instances, disk groups, file access control for disk groups, etc. The default permissions on the files and directories in the Oracle Grid Home will cause asmcmd and therefore Rapid Install to fail for non-Grid users. To avoid this problem, temporarily change permissions as shown in the example below. For further information, refer to Knowledge Document 1295851.1 , ASMCMD Fails From Non-grid User Even if it Belongs To Same Groups. If you use the workaround, reset the permissions once Rapid Install has completed. $ cd /perl $ chmod -R 751 bin lib man ( Original permissions are 700 ) $ cd /lib $ chmod 660 libexpat.so.1 ( Original permissions are 600 ) $ cd /log chmod 770 Note: You should use the same inventory as used by the Oracle Grid install. 5.1.5 Other Considerations Run cluvfy manually before starting the installation from grid home. "cluvfy stage -pre dbinst -n " Check that the SCAN LISTENERS and GRID LOCAL LISTENERS are up and running as they are used by Rapid Install to convert the database into RAC. In order to avoid port Listener conflicts, always select a different port pool for the EBS Local Listener and Grid Local listener. The Grid local listener uses port 1521 by default so do not use that for EBS unless you have changed it during the grid installation. In the split tier configuration, keep the SCAN and VIP hosts details in the /etc/hosts file on the Application Tier server. Verify that the SCAN and VIP host can be pinged from the server where you are going to install Application Tier. 5.2: Install Oracle E-Business Suite Release 12.2 with Oracle Database 11gR2 on Cluster Nodes Rapid Install allows several different configuration options, including for example a shared Oracle Home installed on to either ASM or shared File System. This section describes what happens during the the Oracle E-Business Suite Release 12.2 Rapid Install. 5.2.1 The Rapid Install Rapid Install allows several different configuration options, including for example a shared Oracle Home installed on to either ASM or shared file system. This section describes the actions Oracle E-Business Suite Release 12.2 Rapid Install performs. 5.2.1.1 Installation Details The installation phase carries out the following tasks: Installs the database software on all selected nodes. If a shared Oracle Home is selected, the installer identifies the type of Oracle Home and performs the installation. Uses rman to restore the database on to the nominated shared storage (either ASM or shared file system). Configure the Oracle Database for Oracle E-Business Suite. Uses rconfig to convert the database to Oracle RAC. Runs AutoConfig on all nodes. Figure 1 shows the Oracle E-Business Suite Release 12.2 Rapid Install Database Node page, which has the following Oracle RAC options: RAC Enabled Storage Type Shared Oracle Home RAC Nodes Instance Prefix Close tab modal window When you select the Oracle RAC option, ASM storage is used by default. If you are not using ASM, you must specify file system. Select the appropriate check box if using a shared Oracle Home. When you click on the RAC Nodes button, the nodes list opens so you can select the required nodes for installation. There is also an option to change instance prefix also. After you have selected the relevant options, the installer checks the prerequisites have been met. This may take a few minutes. Validation Checks Rapid Install performs its standard validation checks for temporary space, swap space, etc. and in an Oracle RAC installation also performs cluster verification. If there any prerequisite failures, it will create an output file cluvfy_output_.lst under the temporary directory. It is essential that you review this and resolve any problems. If there are any issues that can be fixed automatically, Rapid Install will create a fixup.sh script, also in the temporary directory. While converting the Oracle database to Oracle RAC, rconfig uses the Oracle Grid local Listener, but once the AutoConfig configuration completes, it will use the SCAN Listener and Oracle E-Business Suite Database Listener. 5.2.2 Post Install Steps Update SRVCTL for the New listener.ora If you intend to manage an Oracle E-Business Suite database with SRVCTL, you must perform the following additional steps: Note: If you are using shared Oracle Home then TNS_ADMIN cannot be shared as the directory path must be same on all nodes.See Appendix F for an example of how to use SRVCTL to manage listeners in a shared Oracle Home. If you wish to use the port allocated to the default listener, stop and remove the default listener. Add the Oracle E-Business Suite listener as follows: $ srvctl add listener -l -o <11gR2 ORACLE_HOME> -p $ srvctl setenv listener -l -T TNS_ADMIN= $ORACLE_HOME/network/admin On each node, add the AutoConfig listener.ora as an ifile in the $ORACLE_HOME/network/admin/listener.ora. The contents of listener.ora file would be ifile=<11gR2 ORACLE_HOME>/network/admin//listener.ora On each node, add the AutoConfig tnsnames.ora as an ifile in the $ORACLE_HOME/network/admin/tnsnames.ora. On each node, add the AutoConfig sqlnet.ora as an ifile in the $ORACLE_HOME/network/admin/sqlnet.ora. Add TNS_ADMIN to the database as follows: $ srvctl setenv database -d -T TNS_ADMIN= $ORACLE_HOME/network/admin Start up the database instances and listeners on all nodes. The database can now be managed using SRVCTL. 5.2.3 Application Tier Install Typically, the application tier is not on the database machine. In such a case, you need to copy the configuration file to the application tier node(s) and install there. If you prefer to load the configuration from the database instead, you should use the Applications Database Listener port and dbname for the SID. For example: :: Rapid Install creates the application tier with the patch and run file systems, and the non-editioned file system. By default, all the database connections go through the SCAN Listener. Verify the SCAN host and SCAN port in the following $TNS_ADMIN/tnsnames.ora Context file: s_apps_jdbc_connect_descriptor and s_apps_jdbc_patch_connect_descriptor variables $FND_SECURE/.dbc The port and WebLogic server data source /user_projects/domains/EBS_domain_/config/jdbc/EBSDataSource--jdbc.xml Note: It is highly recommeded that you deploy a split-tier configuration and separate the applications and database tiers. 5.2.4 Set up Load Balancing Follow instructions given in Step 4.7.2 of Section 4.7 . 5.3 Known Issues First, check that all the prerequisites have been met. If you see any errors, check the Rapid Install log. For the Oracle Database tier: ORACLE_HOME/appsutil/log//.log. For the application tier(s): $INST_TOP/apps//logs/.log. Finally, review the OUI inventory log /logs/install.log. If the error reported is PRVF-5640, check that /etc/resolve.conf does not have multiple domains defined. When Rapid Install completes, the remote_listener parameter is set to :. Update the remote_listener parameter to _remote on all instances, using the following command: And also change s_instRemoteListener context variable in context file and run AutoConfig. SQL>alter system set remote_listener=_remote scope=both sid='' During the E-Business Suite 12.2.x RAC installation, you may encounter the following error during prerequistes checking: PRVF-7617 : Node connectivity between " : " and " : failed INFO: Cause: Node connectivity between the two interfaces identified ( : ) could not be verified. If so, modify /TechInstallMedia/database/client/stage/cvu/cv/admin/cvu_config and change the file as follows and then restart the installation: #CV_ASSUME_CL_VERSION=10.2 CV_ASSUME_CL_VERSION=11.2 Section 6: References Knowledge Document 745759.1, Oracle E-Business Suite and Oracle Real Application Clusters Documentation Roadmap Knowledge Document 384248.1, Sharing The Application Tier file system in Oracle E-Business Suite Release 12 Knowledge Document 406982.1, Cloning Oracle Applications Release 12 with Rapid Clone Knowledge Document 240575.1, RAC on Linux Best Practices Knowledge Document 265633.1, Automatic Storage Management Technical Best Practices Knowledge Document 881506.1, Oracle Applications Release R12 with Oracle 11g Release 2 Oracle E-Business Suite Installation Guide: Using Rapid Install, Release 12.2, Part No. E22950 Oracle E-Business Suite Setup Guide, Release 12.2, Part No. E22953 Appendices The appendices are divided as follows: Appendices A and B are intended to help with migrating non-Oracle RAC to Oracle RAC. Appendices C, D, E, and F are intended to help with Rapid Install usage in setting up Oracle RAC. Appendix G describes role separation. Appendix H lists Grid Infrastructure known issues. Appendix I describes how to set up Parallel Concurrent Processing (PCP). Migrating non-RAC system to RAC Appendix A: Sample Config XML file Appendix B: Database Conversion - Known Issues Appendix A: Sample Config XML file This appendix shows example contents of an rconfig XML input file. have been added to the code, and notes have been inserted between sections of code. RConfig xsi:schemaLocation="http://www.oracle.com/rconfig"> - - - Note: The Convert verify option in the ConvertToRAC.xml file can take one of three values YES/NO/ONLY: 1. YES: rconfig performs prerequisite checks and then starts conversion. 2. NO: rconfig does not perform prerequisite checks prior to starting the conversion. 3. ONLY: rconfig only performs prerequisites check and does not start the conversion. In order to validate and test the settings specified for converting to RAC with rconfig, it is advisable to execute rconfig using Convert verify="ONLY" prior to carrying out the actual conversion. /oracle/product/11.1.0/db_1 /oracle/product/11.1.0/db_1 - - - sys oracle sysdba - sys welcome sysdba - - - sales - - Note: rconfig can also migrate the single instance database to ASM storage. If you want to use this option, specify the ASM parameters as per your environment in the above xml file. The ASM instance name specified above is only the current node ASM instance. Ensure that ASM instances on all the nodes are running and the required diskgroups are mounted on each of them. The ASM disk groups can be identified by issuing the following statement when connected to the ASM instance: SQL> select name, state, total_mb, free_mb from v$asm_diskgroup; +ASMDG Note: rconfig can also migrate the single instance database to ASM storage. If you want to use this path, specify the ASM parameters as per your environment in the above XML file. If you are using CFS for your current database files then specify "NULL" to use the same location unless you want to switch to other CFS location. If you specify the path for the TargetDatabaseArea, rconfig will convert the files to Oracle Managed Files nomenclature. +ASMDG Appendix B: Database Conversion - Known Issues Database Upgrade Assistant (DBUA) If DBUA is used to upgrade an existing AutoConfig-enabled Oracle RAC database, you may encounter an error about a pre-11gR2 listener existing in CRS. In such a case, copy the AutoConfig listener.ora to the <11gR2_ORACLE_HOME>/network/admin directory, and merge the contents in with the existing listener.ora file. Migration to RAC and RAC installation Appendix C: Example Grid Installation Appendix D: Enabling/Disabling SCAN Listener Support in Autoconfig Appendix E: Instance and Listener Interaction Appendix F: Shared ORACLE_HOME and TNS_ADMIN Appendix C: Example Grid Installation The following assumes a fresh Grid install and is intended for those less experienced with Clusterware, or who may be doing a test install. Start the Installer. Choose "Install and Configure Grid Infrastructure for a Cluster". Click "Next". Choose "Advanced Configuration". This is needed when specifying a scan name that is different from the cluster name. Click "Next". Choose Languages. Click "Next". Uncheck "Configure GNS" - this is for experienced users only. Enter the cluster name, scan name and scan port. Click "Next". Add Hostnames and Virtual IP names for nodes in the cluster. Click "SSH Connectivity". Click "Test". If SSH is not established, enter the OS user and password and let the installer set up passwordless connectivity. Click "Test" again, and if successful click "Next". Choose one interface as public, one as private. eth0 should be public while eth1 is usually set up as private. Click "Next". Uncheck "Grid Infrastructure manager" page "configuration repository". Choose Shared File System. Click "Next". Choose the required level of redundancy, and enter location for the OCR disk. This must be located on shared storage. Click "Next". Choose the required level of redundancy, and enter location for the voting disk. This must be located on shared storage. Click "Next". Choose the default of "Do not use" for IPMI. Click "Next". Select an operating system group for the operator and dba accounts. For the purposes of this example installation, choose the same group, such as "dba", for both. Click "Yes" in the popup window that asks you to confirm that the same group should be used for both, then click "Next". Enter the Oracle Base and Oracle Home. The Oracle Home should not be located under Oracle Base. Click "Next". Enter Create Inventory location. Click "Next". In the "Root Script Execution" page, either select or unselect "Automatically run configuration scripts" option (as you prefer). System checks are now performed. Fix any errors by clicking on "Fix and Check Again", or check "Ignore All" and click "Next". If you are not familiar with the possible effects of ignoring errors, it is advisable to fix them. Save the response file for possible future use, then click "Finish" to start the install. You will be required to run various scripts as root during the install. Follow the relevant on-screen instructions. Appendix D: Enabling/Disabling SCAN Listener Support in Autoconfig Managing the scan listener is handled on the database server. All that is required for the middle tier is for AutoConfig to be re-run, to pick up the updated connection strings. Switching from SCAN to non-SCAN s_scan_name=null, s_scan_port=null and s_update_scan=TRUE local_listener should be _local and remote listener _remote (To allow failover aliases) Run AutoConfig, it creates non SCAN aliases in tnsnames.ora Run AutoConfig on middle tier, it creates non SCAN aliases in tnsnames.ora Re-enabling SCAN s_scan_name=,s_scan_port= and s_update_scan=TRUE Modify the remote_listener to : using the SQL command: alter system set remote_listener='...' for all instances. Run AutoConfig, it creates SCAN aliases in tnsnames.ora Run AutoConfig on middle tier, it creates SCAN aliases in tnsnames.ora Appendix E: Instance and Listener Interaction Understanding how instances and listeners interact is best done with a worked example. Consider a two-node Oracle RAC cluster, with nodes C1 and C2. In this example, two local listeners are used, the default listener and a listener called "EBS" listener. There is nothing special about the name of the latter: it could equally well have been called the "ABC" listener, for example. Listener Configuration Listener Type Node SCAN Name Host Name VIP Name Listener Host Listener Port Listener Address EBS listener C1 N/A C1 C1-VIP C1 1531 C1 and C1-VIP C2 N/A C2 C2-VIP C2 1531 C2 and C2-VIP Default listener C1 N/A C1 C1-VIP C1 1521 C1 and C1-VIP C2 N/A C2 C2-VIP C2 1521 C2 and C2-VIP SCAN Either C1 or C2 C-SCAN N/A N/A Either C1 or C2 1521 C-SCAN Note the following: The SCAN and local listener can listener on the same port as they listen on different addresses. The SCAN listener can run on either C1 or C2. Listeners have no built in relationship with instances. SRVCTL configuration Listener Type Listener Name Listener Port Listener Host Listener Address General [Local] listener 1521 C1 C1 and C1-VIP 1521 C2 C2 and C2-VIP ebs_listener 1531 C1 C1 and C1-VIP 1531 C2 C2 and C2-VIP SCAN SCAN [ name doesn't matter and can be default ] 1521 Either C1 or C2 C-SCAN Instance to Listener Assignment The relationship between instances and listeners is established by the local_listener and remote_listener init.ora parameters. Local_Listener The instance broadcasts to the address list, informing the listeners that the instance is now available. The local listener must be running on the same node as the instance, as the listener spawns the oracle processes. The default value comes from the cluster. Remote_Listener The instances broadcasts to the address list, informing the listeners that the instance is now available for accepting requests, and that the requests are to be handled by the local_listener address. The remote hosts can be on any machine. There is no default value for this parameter. Database Instance Node Local_Listener Remote_Listener Default Listener Status EBS Listener Status SCAN Listener Status D1 I1 C1 Set to C1 & C1-VIP on 1531 C-SCAN/1521 I1 is unavailable I1 is available I1 is available via redirect to EBS Listener for C1 Set to C1 & C1-VIP on 1531 C1/C1-VIP on 1531, C2/C2-VIP on 1531 I1& I2 are unavailable I1 is available. I2 is available via redirect to EBS Listener for C2. I1 not available Not set. Instance uses cluster default listener - i.e. C1 & C1-VIP on 1521 C-SCAN/1521 I1 is available I1 is unavailable. I1 is available via redirect to Default Listener for C1 I2 C2 Set to C2 & C2-VIP on 1531 C-SCAN/1521 I2 is unavailable I2 is available I2 is available via redirect to EBS Listener for C2 Set to C2 & C2-VIP on 1531 C1/C1-VIP on 1531, C2/C2-VIP on 1531 I2 & I1 are unavailable I2 is available. I1 is available via redirect to EBS Listener for C1 I2 not available Not set. Instance uses cluster default listener - i.e. C2 & C2-VIP on 1521 C-SCAN/1521 I2 is available I2 is unavailable I2 is available via redirect to Default Listener for C2 Appendix F Shared ORACLE_HOME and TNS_ADMIN In Oracle 11gR2, listeners are configured at the cluster level, and all nodes inherit the port and environment settings. This means that the TNS_ADMIN directory path will be the same on all nodes. In a shared ORACLE_HOME configuration, the TNS_ADMIN directory must be a local, non-shared directory, in order to be able to use AutoConfig generated network files. These network files will be included as ifiles. The following is an example for setting up TNS_ADMIN for a shared in a two node cluster, C1 and C2, with respective instances I1 and I2. Run AutoConfig on both nodes. This will create listener.ora and tnsnames.ora under the node network directories. i.e. /network/admin/ and . Edit AutoConfig listener.ora files and change LISTENER_ to the listener common name . Skip this step if you have applied the db listener patch. Create a , e.g. /etc/local/network_admin. Create a listener.ora under on each node. node ifile=/network/admin//listener.ora node ifile=/network/admin//listener.ora Create a tnsnames.ora under the on each node. node ifile=/tnsnames.ora node ifile=/tnsnames.ora Add the common listener name to the cluster and set TNS_ADMIN to the non shared directory: srvctl add listener -l -o -p srvctl setenv listener -l -t TNS_ADMIN= Appendix G: Role Separation Create Job Role Separation Operating System Privileges Groups, Users, and Directories This section provides the instructions on how to create the operating system users and groups to install all Oracle software using a Job Role Separation configuration The Job separation privleges of Oracle is a configuration with operation system to divide the administration privileges. In this section , for example grid is the owner of the Grid infrastructure software and Oracle Automatic Storage Management binaries and oracle is the owner of the Oracle RAC Software binaries Both users must have an Oracle Inventory group as their primary group (For example oinstall). Several Operating Systems Groups can be created in order to divide the adminstration privileges as explained in the following table. Description OS Group Name OS Users Assigned to this Group Oracle Privilege Oracle Group Name Oracle Inventory and Software Owner oinstall grid, oracle Oracle Automatic Storage Management Group asmadmin grid SYSASM OSASM ASM Database Administrator Group asmdba grid, oracle SYSDBA for ASM OSDBA for ASM ASM Operator Group asmoper grid SYSOPER for ASM OSOPER for ASM Database Administrator dba oracle SYSDBA OSDBA Database Operator oper oracle SYSOPER OSOPER Example: Creating the groups and users: Create oinstall, asmadmin,asmdba,asmoper (optional) groups. Perform the following as a root user: #groupadd -g 9999 oinstall #groupadd -g 8888 asmadmin #groupadd -g 7777 asmdba #groupadd -g 6666 asmoper The following command creates a user named grid (that owns the Grid infrastructure) and assign the necessary groups to that user. Remember to set the grid user password. useradd -g oinstall -G asmadmin,asmdba,asmoper -d grid Create groups for the Oracle software: #groupadd -g 1010 dba #groupadd -g 1020 oper The following command creates a user named oracle (that will own the Oracle RAC software) and assigns the asmadmin and asmdba groups, which is necessary when using different users for Grid and Oracle: useradd -g oinstall -G dba,oper,asmadmin,asmdba -d oracle Remember to set the resource limits for the Oracle software installation users as per documentation. Appendix H: Higher Version of Grid Infrastructure - Known Issues Using Grid Infrastructure 11.2.0.4.0 Installing Oracle E-Business Suite 12.2/11.2.0.3 RAC using Rapid Install on an Oracle 11.2.0.4.0 cluster fails while running the adRacAutoConfig script. To fix this issue: Download and apply Patch 18848525 to the 11.2.0.3.0 Oracle Home. The patch Readme is very large and you only need to run the following commands: $ /18848525/custom/server/18848525/custom/scripts/prepatch.sh -dbhome $ /OPatch/opatch napply -oh -local /18848525/custom/server/18848525 $ /18848525/custom/server/18848525/custom/scripts/postpatch.sh -dbhome Ensure that you have the old (single instance) context file present in $ORACLE_HOME/appsutil/. If you don't, copy the newly created RAC specific context to the old non-RAC context file - for example: cp prac1_.xml prac_.xml. Rerun the $ORACLE_HOME/temp//adRacAutoConfig.sh script. Upload the configuration file to complete the installation. java -classpath /jdbc/lib/ojdbc6.jar:/appsutil/java/xmlparserv2.jar:/appsutil/java oracle.apps.ad.autoconfig.oam.CtxSynchronizer contextfile=$CONTEXT_FILE action=upload upload=$ORACLE_HOME/appstuil/conf_.txt Grid Infrastructure 12.1.0.1 Installing Oracle E-Business Suite 12.2/11.2.0.3 RAC using Rapid Install on an Oracle Database 12c cluster fails while running the adRacAutoConfig script and rconfig fails to register the database in the cluster. To fix this issue: Download and apply Patch 18848525 to the 11.2.0.3.0 Oracle Home. Follow the instructions in the patch Readme. Register the database in the cluster using the following commands: $ srvctl add database -d -o $ORACLE_HOME $ srvctl add instance -d -i -n Note: Repeat the above command to add all the instances on their respective nodes. When you rerun adRacAutoconfig,it will fail to start the listener due to Bug 18892986. The problem is that the context variable s_virtual_hostname has been updated with both the hostname and domain instead of just the hostname. In order to workaround this problem, the simplest solution is to remove the domain part of the name from s_virtual_hostname. The domain name is also appended twice in the listener.ora. You need to remove one of the domain name entries from the listener.ora. Note that this needs to be performed on each node. Restart the listener and run AutoConfig on all nodes. $ lsnrctl start $ $ORACLE_HOME/appsutil/scripts//adautoconfig.sh Upload the configuration file to complete the installation. java -classpath /jdbc/lib/ojdbc6.jar:/appsutil/java/xmlparserv2.jar:/appsutil/java oracle.apps.ad.autoconfig.oam.CtxSynchronizer contextfile=$CONTEXT_FILE action=upload upload=$ORACLE_HOME/appstuil/conf_.txt Appendix I Configure Parallel Concurrent Processing Check prerequisites for setting up Parallel Concurrent Processing Parallel Concurrent Processing (PCP) spans two or more nodes. If you need to add nodes, follow the relevant instructions in My Oracle Support Knowledge Document 1383621.1, Cloning Oracle Applications Release 12 with Rapid Clone. Note: If you are planning to implement a shared Application tier file system, refer to My Oracle Support Knowledge Document 1375769.1.1, Sharing the Application Tier File System in Oracle E-Business Suite Release 12, for configuration steps. If you are adding a new Concurrent Processing node to the application tier, you will need to set up load balancing on the new application by repeating steps in Section 4.7.2. Set Up PCP Edit the applications context file via Oracle Applications Manager, and set the value of the variable APPLDCP to ON. Source the Applications environment. Execute AutoConfig by running the following command on all concurrent processing nodes: $ $INST_TOP/admin/scripts/adautocfg.sh Check the tnsnames.ora and listener.ora configuration files, located in $INST_TOP/ora/10.1.2/network/admin. Ensure that the required FNDSM and FNDFS entries are present for all other concurrent nodes. Restart the Applications listener processes on each application tier node. Log on to Oracle E-Business Suite Release 12 using the SYSADMIN account, and choose the System Administrator Responsibility. Navigate to the Install > Nodes screen, and ensure that each node in the cluster is registered. Verify that the Internal Monitor for each node is defined properly, with correct primary node specification, and work shift details. For example, Internal Monitor: Host1 must have primary node as host1. Also ensure that the Internal Monitor manager is activated: this can be done from Concurrent > Manager > Administrator. Set the $APPLCSF environment variable on all the Concurrent Processing nodes to point to a log directory on a shared file system. Set the $APPLPTMP environment variable on all the CP nodes to the value of the UTL_FILE_DIR entry in init.ora on the database nodes. (This value should be pointing to a directory on a shared file system.) Set profile option 'Concurrent: PCP Instance Check' to OFF if database instance-sensitive failover is not required. By setting it to 'ON', a concurrent manager will fail over to a secondary Application tier node if the database instance to which it is connected becomes unavailable for some reason. Set Up Transaction Managers Shut down the application services (servers) on all nodes Shut down all the database instances cleanly in the Oracle RAC environment, using the command: SQL>shutdown immediate; Edit $ORACLE_HOME/dbs/_ifile.ora. Add the following parameters: _lm_global_posts=TRUE _immediate_commit_propagation=TRUE Start the instances on all database nodes, one by one. Start up the application services (servers) on all nodes. Log on to Oracle E-Business Suite Release 12 using the SYSADMIN account, and choose the System Administrator responsibility. Navigate to Profile > System, change the profile option ‘Concurrent: TM Transport Type' to ‘QUEUE', and verify that the transaction manager works across the Oracle RAC instance. Navigate to Concurrent > Manager > Define screen, and set up the primary and secondary node names for transaction managers. Restart the concurrent managers. If any of the transaction managers are in deactivated status, activate them from Concurrent > Manager > Administrator. Set Up Load Balancing on Concurrent Processing Nodes Edit the applications context file through the Oracle Applications Manager interface, and set the value of Concurrent Manager TWO_TASK (s_cp_twotask) to the load balancing alias (_balance>). Note: Windows users must set the value of "Concurrent Manager TWO_TASK" (s_cp_twotask context variable) to the instance alias. Execute AutoConfig by running $INST_TOP/admin/scripts/adautocfg.sh on all concurrent nodes. Note: For further details on Concurrent Processing, refer to the Product Information Center (PIC) (Doc ID 1304305.1). Change Log Date Description 22-Jan-2015 Added Appendix I for PCP configuration 22-Jul-2014 Editorial Review and updated for 11.2.0.4 and 12c cluster. 25-Feb-2014 Updated for 11.2.0.4 Database. 15-Apr-2013 Implemented Remarks ( Section 4.7.2 s_tools_two_task to s_tools_twotask) 06-Jul-2012 Updated Known Issues section added remote_listener steps 03-Dec-2012 Initial Draft My Oracle Support Knowledge Document 1453213.1 by Oracle E-Business Suite Development Documentation Notices Copyright © 2012, 2014, Oracle and/or its affiliates. All rights reserved. This software and related documentation are provided under a license agreement containing restrictions on use and disclosure and are protected by intellectual property laws. Except as expressly permitted in your license agreement or allowed by law, you may not use, copy, reproduce, translate, broadcast, modify, license, transmit, distribute, exhibit, perform, publish, or display any part, in any form, or by any means. Reverse engineering, disassembly, or decompilation of this software, unless required by law for interoperability, is prohibited. The information contained herein is subject to change without notice and is not warranted to be error-free. If you find any errors, please report them to us in writing. If this is software or related documentation that is delivered to the U.S. Government or anyone licensing it on behalf of the U.S. Government, the following notice is applicable: U.S. GOVERNMENT END USERS: Oracle programs, including any operating system, integrated software, any programs installed on the hardware, and/or documentation, delivered to U.S. Government end users are "commercial computer software" pursuant to the applicable Federal Acquisition Regulation and agency-specific supplemental regulations. As such, use, duplication, disclosure, modification, and adaptation of the programs, including any operating system, integrated software, any programs installed on the hardware, and/or documentation, shall be subject to license terms and license restrictions applicable to the programs. No other rights are granted to the U.S. Government. This software or hardware is developed for general use in a variety of information management applications. It is not developed or intended for use in any inherently dangerous applications, including applications that may create a risk of personal injury. If you use this software or hardware in dangerous applications, then you shall be responsible to take all appropriate fail-safe, backup, redundancy, and other measures to ensure its safe use. Oracle Corporation and its affiliates disclaim any liability for any damages caused by use of this software or hardware in dangerous applications. Oracle and Java are registered trademarks of Oracle and/or its affiliates. Other names may be trademarks of their respective owners. Intel and Intel Xeon are trademarks or registered trademarks of Intel Corporation. All SPARC trademarks are used under license and are trademarks or registered trademarks of SPARC International, Inc. AMD, Opteron, the AMD logo, and the AMD Opteron logo are trademarks or registered trademarks of Advanced Micro Devices. UNIX is a registered trademark of The Open Group. This software or hardware and documentation may provide access to or information on content, products, and services from third parties. Oracle Corporation and its affiliates are not responsible for and expressly disclaim all warranties of any kind with respect to third-party content, products, and services. Oracle Corporation and its affiliates will not be responsible for any loss, costs, or damages incurred due to your access to or use of third-party content, products, or services. For information about Oracle's commitment to accessibility, visit the Oracle Accessibility Program website at http://www.oracle.com/pls/topic/lookup?ctx=acc&id=docacc. Access to Oracle Support Oracle customers have access to electronic support through My Oracle Support. For information, visit http://www.oracle.com/pls/topic/lookup?ctx=acc&id=info or visit http://www.oracle.com/pls/topic/lookup?ctx=acc&id=trs if you are hearing impaired.