Get Upgrading: Steps To Upgrade To 11gR2

As 11gR2 is out for Linux, I decided to upgrade one of my existing database to to get the look and feel of 11gR2. Direct upgrade to 11gR2 is supported from or higher, or higher, or higher and or higher. If you have a database then first you need to upgrade to intermediate release i.e then to>>>>> I will discuss how to upgrade an existing Single Instance database with ASM, having same ORACLE_HOME, to 11gR2 with ASM. The upgrade needs to be performed in two phases: 1. Upgrade the ASM instance 2. Upgrade the database Upgrade ASM Instance: =============== There are three ways to upgrade already existing ASM instance: - Using OUI of Grid Infrastructure - Using ASM Configuration Assistant - Manual upgrade The recommended method to upgrade ASM instance is to use OUI of Grid Infrastructure, which I have used . STEP 1: – Create OSASM group: If you want, you can create a separate group for ASM instance here it is named as ASMADMIN. # groupadd asmadmin # usermod -a -G asmadmin oracle STEP 2: Before upgrading an ASM instance to 11gR2 it is mandatory to add a ‘user and password’ combination to the password file which is local to node’s ASM instance. Login to database instance “/ as sysdba”:

To download the software for 11gR2 Grid Infrastructure click here Start the RunInstaller: . USERNAME SYSDB SYSOP -----------------------------./runInstaller Click on the Image to Enlarge.----SYS TRUE TRUE SOOD TRUE FALSE ----- STEP 3: From 11gR2 onwards ASM is part of Grid Infrastructure and we need to download Grid Infrastructure software first. It will automatically defaults to the “Upgrade Mode” Select “Upgrade Grid Infrastructure” and click Next. SQL > grant sysdba to sood. It will detect the already existing ASM instance. Click “Yes”. On clicking Next. SQL > select * from v$pwfile_users. Select the Language . 2. Shutdown the Database and ASM instance at this point. 1. 3.SQL > create user sood identified by oracle.

4. Click “Yes”. Do not worry about that cross Click “Next”. Enter a Password for ASMSNMP user. 5. Provide the Group details Click “Next”.Click “Next”. . though Oracle will ask you to set a password which adhers to Oracle’s standards otherwise a “Red Cross” will be shown in the tab at left hand side. The password can be anything you want.

8. Now the setup for “Grid Infrastructure’ is started . 7. 9. For more information on this click Installation Fixup script I have select “Ignore All” Click “Next”. Provide the Base and Home location for Grid Infrastructure Home Click “Next”. Now you will see “Summary” page.6. make sure that the Installation Option is shown as “Upgrade Grid Infrastructure” and Migrate ASM as “True”. Click “Finish”. It will perform the Prerequisite checks here.

.sh script. 2009-09-05 11:46:25: Checking for super user privileges 2009-09-05 11:46:25: User has super user privileges 2009-09-05 11:46:25: Parsing the host name .sh [root@localhost ~]# cd /u01/11g/oracle/product/11..2. The following environment variables are set as: ORACLE_OWNER= oracle ORACLE_HOME= /u01/11g/oracle/product/11. Entries will be added to the /etc/oratab file as needed by Database Configuration Assistant when a database is created Finished running generic part of root./rootupgrade.0/grid Enter the full pathname of the local bin directory: [/usr/local/bin]: The file "dbhome" already exists in /usr/local/bin.2.0/grid [root@localhost grid]# .sh # . Overwrite it? (y/n) [n]: y Copying dbhome to /usr/local/bin . The file "oraenv" already exists in /usr/local/bin.0/grid/ [root@localhost grid]# pwd /u01/11g/oracle/product/ Running Oracle 11g root..Run the rootupgrade./rootupgrade...2. Overwrite it? (y/n) [n]: y Copying coraenv to /usr/local/bin .. Overwrite it? (y/n) [n]: y Copying oraenv to /usr/local/bin .. The file "coraenv" already exists in /usr/local/bin. Now product-specific root actions will be script.

2. you can follow this link to . privgrp 'oinstall'.e now ASM is a part of “Grid Infrastructure” “+ASM:/u01/11g/oracle/product/11..0/grid:N” Upgrade Database Instance: =================== NOTE: DO NOT SHUTDOWN DATABASE BEFORE RUNNING DBUA.2. Shutdown has begun.loc The inventory is located at /u01/10g/oraInventory 'UpdateNodeList' was successful. Adding daemon to inittab CRS-4123: Oracle High Availability Services has been started. Operation successful. ohasd is starting localhost 2009/09/05 11:49:02 /u01/11g/oracle/product/11. Execute runInstaller to install “SOFTWARE ONLY” option. [root@localhost grid]# Actual 885 MB Passed 10.. After the upgrade I have checked /etc/oratab file and found the entry of ASM pointing to new home i. Checking swap space: must be greater than 500 MB. The daemons should exit soon.olr Successfully configured Oracle Grid Infrastructure for a Standalone Server Updating inventory properties for clusterware Starting Oracle Universal Installer. Shutting down CSS daemon.0/grid/crs/install/crsconfig_params Creating trace directory LOCAL ADD MODE Creating OCR keys for user 'oracle'.Using configuration parameter file: /u01/11g/oracle/product/11. CRS-4664: Node localhost successfully pinned.2. CSS appears healthy Stopping CSSD..0/grid/cdata/localhost/backup_20090905_114902. The inventory pointer is located at /etc/oraInst. STEP 1: Install The Software: To download Oracle Database 11gR2 software click Here . Shutdown request successfully issued.

. then: SQL > spool /tmp/upgrade.2 Pre-Upgrade Information Tool 09-04-2009 01:54:32 .2... Once the software is installed.2..sql script to /tmp directory. minimum required size: 464 MB . ********************************************************************** Database: ********************************************************************** --> name: ORCL10G --> version: 10.0. .3...2.3..0 --> blocksize: 8192 --> platform: Linux IA (32-bit) --> timezone file: V3 . Make sure that you select “software only” option as shown below rest of the steps are same as described in above link.0/dbhome_1″ location. Now login to 10g database “/ as sysdba” and startup the 10g database.0. ********************************************************************** Tablespaces: [make adjustments in the current environment] ********************************************************************** --> SYSTEM tablespace is adequate for the upgrade.0 --> compatible: 10.. STEP 2: Run Pre-Upgrade Information tool I have installed the software under “/u01/11g/oracle/product/11.spl SQL > @/tmp/utlu112i. then go to location $ORACLE_HOME/rdbms/admin and copy utlu112i. AUTOEXTEND additional space required: 439 MB .install the software... AUTOEXTEND additional space required: 244 MB --> UNDOTBS1 tablespace is adequate for the upgrade... .sql SQL > spool off Following is the output of this script from my database: Oracle Database 11. minimum required size: 724 MB .

********************************************************************** Components: [The following database components will be upgraded or installed] ********************************************************************** --> Oracle Catalog Views [upgrade] VALID --> Oracle Packages and Types [upgrade] VALID --> JServer JAVA Virtual Machine [upgrade] VALID --> Oracle XDK for Java [upgrade] VALID --> Oracle Workspace Manager [upgrade] VALID --> OLAP Analytic Workspace [upgrade] VALID --> OLAP Catalog [upgrade] VALID --> EM Repository [upgrade] VALID --> Oracle Text [upgrade] VALID --> Oracle XML Database [upgrade] VALID --> Oracle Java Packages [upgrade] VALID --> Oracle interMedia [upgrade] VALID --> Spatial [upgrade] VALID --> Data Mining [upgrade] VALID --> Expression Filter [upgrade] VALID --> Rule Manager [upgrade] VALID --> Oracle OLAP API [upgrade] VALID ..2 init.No renamed parameters found. AUTOEXTEND additional space required: 207 MB --> TEMP tablespace is adequate for the upgrade.2 init. minimum required size: 447 MB .1 DEPRECATED replaced by "diagnostic_dest" --> user_dump_dest 11.... ...2 init. ********************************************************************** Obsolete/Deprecated Parameters: [Update Oracle Database 11. No changes are required..ora or spfile] ********************************************************************** --> background_dump_dest 11. ********************************************************************** Miscellaneous Warnings ********************************************************************** WARNING: --> Database is using a timezone file older than version 11..1 DEPRECATED replaced by "diagnostic_dest" --> core_dump_dest 11. ********************************************************************** Renamed Parameters: [Update Oracle Database 11.ora or spfile] ********************************************************************** WARNING: --> "sga_target" needs to be increased to at least 336 MB WARNING: --> "java_pool_size" needs to be increased to at least 64 MB WARNING: --> "pga_aggregate_target" needs to be increased to at least 24 MB . minimum required size: 61 MB . .1 DEPRECATED replaced by "diagnostic_dest" . .--> SYSAUX tablespace is adequate for the upgrade. ********************************************************************** Flashback: OFF ********************************************************************** ********************************************************************** Update Parameters: [Update Oracle Database 11. AUTOEXTEND additional space required: 41 MB ....ora or spfile] ********************************************************************** -. ..

XDB WARNING: --> Database contains schemas with objects dependent on network packages. PL/SQL procedure successfully completed.......0... . After the release migration. SYS . ... . your database.. Select the database that you want to upgrade . SQL> spool off Adjust the warnings shown by Pre-Upgrade Information tool. Your recycle bin turned on.... Refer to the Upgrade Guide for instructions to update ...3.. .... STEP 3 : Upgrade using DBUA Execute the DBUA from 11gR2 software home as $ cd $ORACLE_HOME/bin $. . Refer to the .. WARNING: --> EM Database Control Repository exists in the database. The command: PURGE DBA_RECYCLEBIN ... Click “Next” 2.. ..2.. Refer to the Upgrade Guide for instructions to configure Network ACLs... schema statistics prior to upgrading the database. that the recycle bin is empty prior to upgrading . be used to upgrade the 10.......... must be executed immediately prior to executing your upgrade...... it is recommended that DBMS_DST package . WARNING:--> recycle bin in use.. Upgrade Guide for instructions to save the EM data prior to upgrade...0 database timezone version .. to the latest version which comes with the new release. Direct downgrade of EM Database Control is not supported. WARNING: --> Database contains schemas with stale optimizer statistics./dbua 1... It is REQUIRED ... Component Schemas with stale statistics: ... .

Turn OFF archiving while upgrading Click “Next” 5.Click “Next” 3. Here DBUA will show warnings that were not solved after running PreUpgrade Information tool Click “Yes” 4. though the “move datafile” check-box was not highlighted when I upgraded . Check whether you want to move the datafiles while upgrade.

7. Check configuration for EM Click “Next”. 8. 6. Check “Summary” page Click “Finish” . Specify “FRA” and “Diagnostic Destination” Click “Next”.Click “Next”.

Upgrade Process is started Check the Results Congratulations!!!!!!!!!! Upgrade is Successful !!!!!!!!!!!!!!! Now you are ready to use Most Powerful Database!! .