martes, 30 de abril de 2013

Install ASM on existing Oracle database 11gR2


- ASMLIB (Step 4- Prerequisites)
- Grid --> Grid_download



1) To see our partitions we have to open a terminal, connect as root user and write "cat /proc/partitions"

I have 3 partitions, two of 2Gb and one of 3Gb called hdb,hdc and hdd (hda is the primary master, don't do anything!!)

2) To configure the partitions, we have to use fdisk utility. Like partitions are under /dev/sdX, we have to run fdisk /dev/sdX, one time for each partition. In that step, we will write "n","p" "1" (number 1) and "w" (in that order):

3) If we list partitions again we will show the result:

4) We have to download ASM libraries and drivers. The easy way is using yum utility. Open a terminal with root user and execute:

5) Now we have to configure the kernel module  for ASM executing "/etc/init.d/oracleasm configure" with root. The answers this time will be "oracle", "oinstall", "y" and  "y"

6) Create disks for ASM
/etc/init.d/oracleasm createdisk ASM1 /dev/sdb1
/etc/init.d/oracleasm createdisk ASM2 /dev/sdc1
/etc/init.d/oracleasm createdisk ASM3 /dev/sdd1

7) run scandisk and listdisk to be sure that we have all asmdisk available.
/etc/init.d/oracleasm scandisks 
/etc/init.d/oracleasm listdisks 



1) with user oracle, "Unzip" grid software:

2) execute /grid/runInstaller (grid directory is created when we unzipped grid software) to start grid configuration window

3) choose the second option and "Next"

4) choose your language and "Next"

5) In that window we only select 2 asmdisk for DATA (the other will be for Flash_recovery_area, we will do it later), it's important choose Extern Redundancy
(you can select the path of your DISKs in "Change discovery path", by default "/dev/oracleasm/disks"):

6) Time to choose our passwords, different password for accounts or the same password for all the accounts, like you want

7) Select all groups as dba and "Next" (will appear a warning, but ignore it)

8) Select the path where grid will be installed

9) In that step, the installation check that all will be ok, if not you have to check the description of the error and solve it, when all will be ok, "next"

10) Verify the information showed and "Finish"

11) wait untill installation finish

12) Almost at the end of the installation will appear a new window, we must run with root user, when finish click on accept, and the installation will continue.

Set /usr/local/bin like teh full pathname of the local bin directory.

*like we had installed an oracle database before, you must overwrite dbhome, oraenv and coraenv

13) when the installation finish, close the window.

14) We have already installed grid infraestructure, now we are going to add FLASH_RECOVERY_AREA to the other free asmdisk (step 5). We need to run asmca, to do it we must set the correct ORACLE_HOME and ORACLE_SID. In this case ORACLE_SID will be +ASM and ORACLE_HOME is the grid path. To go to the easy way, open a terminal and write "oraenv", you will be question for the new ORACLE_SID, write "+ASM" and the ORACLE_HOME automatically change too:

15) A new window appears, choose create:

16) Now choose the name, select "extern" and select the disk. "Next"

17) We have now both asmdisks:

No hay comentarios:

Publicar un comentario