Blog do Bruno Murassaki

maio 12, 2011

Oracle RAC 11gR2 11.2.0.2 – Instalação e Configuração Oracle RAC 11gR2 – Linux

Filed under: Oracle RAC — brunomurassaki @ 11:28 pm

==============================================================================================================

Ola Pessoal, hoje o artigo será sobre Oracle RAC 11G R2 11.2.0.2. Primeiramente gostaria de dedicar este artigo a minha Esposa Rute Bomfim Murassaki que sempre tem paciência para que eu me dedique aos estudos e me apoia com meus artigos. Também agradecer a todos meus amigos DBAs que me ajudaram com esse projeto diretamente ou indiretamente. Em especial ao Edson Martins(Responsavel de TI onde implantei o Oracle RAC 11g R2) pela oportunidade e confiança do meu trabalho, onde tive a oportunidade de implantar meu primeiro Oracle RAC 11gR2 em produção. Esse foi um Caso de Sucesso em um Cliente onde estarei contando aqui um pouco da minha experiência com Oracle RAC 11g R2.

Neste Projeto foi executado uma migração de Oracle Single Instance Database 9i R2 9.2.0.8 para Oracle Rac Databse 11g R2 11.2.0.2 (2 Nodes).

Para quem nunca implantou um Oracle RAC ai vai uma dica, para executar essa migração não é apenas sair instalando o Oracle RAC, é necessário todo um planejamento desde qual Hardware comprar (Hardware Homologado para Oracle RAC) como montar a estrutura física, que tipo de Sistema Operacional e que tipo de aplicação irá rodar.  Além de instalar e configurar o Oracle RAC é necessário testar… testar… e testar antes de rodar em produção. Pra vocês terem uma idéia a bateria de testes durou um mês. Houve bastante contato com a Equipe de TI da DELL no qual montou todo a parte de Hardware para que o projeto fosse executado com sucesso. Também foi envolvido um especialista em SO Linux e uma Equipe do Sistema para validar performance do Sistema, pois como sabemos de uma Versão 9i para a Versão 11g temos muitas alterações e como eu sempre falo “Migração de Banco de Dados Oracle é igual Kinder Ovo sempre tem uma Surpresa“.

Bom vamos lá….. iniciaremos pelo ambiente.

==============================================================================================================

AMBIENTE ORACLE RAC 11G R2 11.2.0.2

==============================================================================================================

Sistema Operacional: Oracle Enterprise Linux 5 – 64bits

Versão do Banco de Dados: Oracle Database 11g R2 11.2.0.2 – 64bits

Instalador Oracle 11g R2 PachSet 11.2.0.2:  Uma novidade do PachSet Oracle 11gR2 11.2.0.2 é que você não precisa mais instalar a versão 11.2.0.1 para aplicar o PachSet 11.2.0.2. Agora você pode instalar direto a versão 11.2.0.2 sem precisar instalar o instalador base 11.2.0.1 como em releases anteriores.

- p10098816_112020_Linux-x86-64_1of7

- p10098816_112020_Linux-x86-64_2of7

- p10098816_112020_Linux-x86-64_3of7

==============================================================================================================

==============================================================================================================

Pre-requisitos Instalação do Oracle RAC 11g R2 11.2.0.2

Instalar Pacotes Requeridos para Instalação do Oracle 11G R2:

# From Enterprise Linux 5 DVD
cd /media/cdrom/Server
rpm -Uvh binutils-2.*
rpm -Uvh compat-libstdc++-33*
rpm -Uvh elfutils-libelf-0.*
rpm -Uvh elfutils-libelf-devel-*
rpm -Uvh gcc-4.*
rpm -Uvh gcc-c++-4.*
rpm -Uvh glibc-2.*
rpm -Uvh glibc-common-2.*
rpm -Uvh glibc-devel-2.*
rpm -Uvh glibc-headers-2.*
rpm -Uvh ksh-2*
rpm -Uvh libaio-0.*
rpm -Uvh libaio-devel-0.*
rpm -Uvh libgcc-4.*
rpm -Uvh libstdc++-4.*
rpm -Uvh libstdc++-devel-4.*
rpm -Uvh make-3.*
rpm -Uvh sysstat-7.*
rpm -Uvh unixODBC-2.*
rpm -Uvh unixODBC-devel-2.*
cd /
eject

==============================================================================================================

Se você não está usando DNS,  configuração do arquivo “/etc/hosts”:
# Do not remove the following line, or various programs
# that require network functionality will fail.
127.0.0.1       localhost.localdomain localhost
::1             localhost6.localdomain6 localhost6
#Public
10.0.0.3           rac1.murassaki.ind.br         rac1
10.0.0.4           rac2.murassaki.ind.br         rac2
# Private
192.168.0.3        rac1-priv.murassaki.ind.br    rac1-priv
192.168.0.4        rac2-priv.murassaki.ind.br    rac2-priv
# Virtual
10.0.0.21          rac1-vip. murassaki.ind.br     rac1-vip
10.0.0.22          rac2-vip. murassaki.ind.br     rac2-vip
# SCAN
10.0.0.20          rac-scan. murassaki.ind.br     rac-scan

==============================================================================================================

Configuração do arquivo sysctl.conf

#Parametros de Memoria
kernel.shmmni = 4096
kernel.shmall = 2097152
# semaforos: semmsl, semmns, semopm, semmni
kernel.sem = 1010 143420 1010 142
net.ipv4.ip_local_port_range = 9000 65500
fs.aio-max-nr = 1048576
fs.file-max = 6815744
net.core.rmem_default = 262144
net.core.rmem_max = 4194304
net.core.wmem_default = 262144
net.core.wmem_max = 1048586
# parametros hugepages
kernel.shmmax = 6442450944
vm.nr_hugepages = 3072
vm.hugetlb_shm_group = 501

==============================================================================================================

Configuração do Arquivo /etc/limits.conf
oracle           soft       nproc             131072
oracle           hard      nproc             131072
oracle           soft       nofile             131072
oracle           hard     nofile              131072
oracle           soft      core                 unlimited
oracle           hard     core                 unlimited
oracle           soft      memlock         unlimited
oracle           hard     memlock         unlimited

==============================================================================================================

Criar usuario Oracle (Neste caso eu criei um usuario unico para tudo)
groupadd oinstall
groupadd dba
useradd -g oinstall -G dba oracle
[root@rac1 /]# passwd oracle
Changing password for user oracle.
New UNIX password:
Retype new UNIX password:
passwd: all authentication tokens updated successfully.

==============================================================================================================

Criar Diretorio Padrão OFA (Optimal Flexibile Architecture)
mkdir -p /u01/app/11.2.0/grid
mkdir -p /u01/app/oracle/product/11.2.0/ajr
mkdir -p /u01/installoracle
chown -R oracle.oinstall /u01

==============================================================================================================

Configuração das Variáveis de Ambiente:

# Oracle Settings
TMP=/tmp; export TMP
TMPDIR=$TMP; export TMPDIR

ORACLE_HOSTNAME=rac1.murassaki.ind.br; export ORACLE_HOSTNAME
ORACLE_UNQNAME=AJR; export ORACLE_UNQNAME
ORACLE_BASE=/u01/app/oracle; export ORACLE_BASE
ORACLE_HOME=$ORACLE_BASE/product/11.2.0/ajr; export ORACLE_HOME
ORACLE_SID=RAC1; export ORACLE_SID
ORACLE_TERM=xterm; export ORACLE_TERM
PATH=/usr/sbin:$PATH; export PATH
PATH=$ORACLE_HOME/bin:$PATH; export PATH

==============================================================================================================
———————————-
INSTALANDO ASMLIB
———————————-
[root@rac2 /]# cd installoracle/
[root@rac2 installoracle]# cd ASMLIB\ asmlib\ 2.6.18-194.el5xen/
[root@rac2 ASMLIB asmlib 2.6.18-194.el5xen]# ls
oracleasm-2.6.18-194.el5-2.0.5-1.el5.x86_64.rpm       oracleasm-2.6.18-194.el5-debuginfo-2.0.5-1.el5.x86_64.rpm  oracleasmlib-2.0.4-1.el5.x86_64.rpm
oracleasm-2.6.18-194.el5debug-2.0.5-1.el5.x86_64.rpm  oracleasm-2.6.18-194.el5xen-2.0.5-1.el5.x86_64.rpm         oracleasm-support-2.1.3-1.el5.x86_64.rpm
[root@rac2 ASMLIB asmlib 2.6.18-194.el5xen]# rpm -ivh oracleasm*
warning: oracleasm-2.6.18-194.el5-2.0.5-1.el5.x86_64.rpm: Header V3 DSA signature: NOKEY, key ID 1e5e0159
Preparing…                ########################################### [100%]
1:oracleasm-support      ########################################### [ 17%]
2:oracleasm-2.6.18-194.el########################################### [ 33%]
3:oracleasm-2.6.18-194.el########################################### [ 50%]
4:oracleasm-2.6.18-194.el########################################### [ 67%]
5:oracleasm-2.6.18-194.el########################################### [ 83%]
6:oracleasmlib           ########################################### [100%]
[root@rac2 ASMLIB asmlib 2.6.18-194.el5xen]#

==============================================================================================================

—————————————————–
VERIFICANDO ASMLIB INSTALADA
—————————————————–
[root@rac2 /]# rpm -q -i -a | grep asm
Name        : oracleasm-2.6.18-194.el5-debuginfo  Relocations: (not relocatable)
Group       : Development/Debug             Source RPM: oracleasm-2.6.18-194.el5-2.0.5-1.el5.src.rpm
URL         : http://oss.oracle.com/projects/oracleasm/
Summary     : Debug information for package oracleasm-2.6.18-194.el5
This package provides debug information for package oracleasm-2.6.18-194.el5.
Name        : oracleasm-2.6.18-194.el5xen  Relocations: (not relocatable)
Group       : System Environment/Kernel     Source RPM: oracleasm-2.6.18-194.el5-2.0.5-1.el5.src.rpm
URL         : http://oss.oracle.com/projects/oracleasm/
Name        : oracleasmlib                 Relocations: (not relocatable)
Group       : System Environment/Kernel     Source RPM: oracleasmlib-2.0.4-1.el5.src.rpm
Name        : oracleasm-2.6.18-194.el5     Relocations: (not relocatable)
Group       : System Environment/Kernel     Source RPM: oracleasm-2.6.18-194.el5-2.0.5-1.el5.src.rpm
URL         : http://oss.oracle.com/projects/oracleasm/
Name        : oracleasm-2.6.18-194.el5debug  Relocations: (not relocatable)
Group       : System Environment/Kernel     Source RPM: oracleasm-2.6.18-194.el5-2.0.5-1.el5.src.rpm
URL         : http://oss.oracle.com/projects/oracleasm/
Name        : oracleasm-support            Relocations: (not relocatable)
Group       : System Environment/Kernel     Source RPM: oracleasm-support-2.1.3-1.el5.src.rpm
URL         : http://oss.oracle.com/projects/oracleasm/

==============================================================================================================

Criar ASM DISKS
No nosso Storage temos o seguinte utilizando multipath:
[root@rac1 /]# cd /dev/mapper/
[root@rac1 mapper]# ls
asm-data  ocr01  VolGroup00-LogVol00  VolGroup00-LogVol02  voting01
control   ocr02  VolGroup00-LogVol01  VolGroup00-LogVol03  voting02

==============================================================================================================

Rode esse comando nos 2 nodes
[root@rac1 ~]# /usr/sbin/oracleasm configure -i
Configuring the Oracle ASM library driver.
This will configure the on-boot properties of the Oracle ASM library
driver.  The following questions will determine whether the driver is
loaded on boot and what permissions it will have.  The current values
will be shown in brackets (‘[]‘).  Hitting <ENTER> without typing an
answer will keep that current value.  Ctrl-C will abort.

Default user to own the driver interface [oracle]: oracle
Default group to own the driver interface [dba]: dba
Start Oracle ASM library driver on boot (y/n) [y]: y
Scan for Oracle ASM disks on boot (y/n) [y]: y
Writing Oracle ASM library driver configuration: done
[root@rac1 ~]#

[root@rac1 ~]# /usr/sbin/oracleasm createdisk ASMDATA /dev/mapper/asm-data

[root@rac1 ~]# /usr/sbin/oracleasm createdisk OCR01 /dev/mapper/ocr01

[root@rac1 ~]# /usr/sbin/oracleasm createdisk OCR02 /dev/mapper/ocr02

[root@rac1 ~]# /usr/sbin/oracleasm createdisk VOTING01 /dev/mapper/voting01

[root@rac1 ~]# /usr/sbin/oracleasm createdisk VOTING02 /dev/mapper/voting02

==============================================================================================================

[root@rac1 sysconfig]# /usr/sbin/oracleasm listdisks
ASMDATA
OCR01
OCR02
VOTING01
VOTING02

[root@rac2 sysconfig]# /usr/sbin/oracleasm listdisks
ASMDATA
OCR01
OCR02
VOTING01
VOTING02

==============================================================================================================

Configurar Multipath se não o Grid InfraStructure não irá achar os ASM DISKS

Rode em todos os nodes:
1. Modify the /etc/sysconfig/oracleasm with:

ORACLEASM_SCANORDER=”dm”
ORACLEASM_SCANEXCLUDE=”sd”

2. restart the asmlib by :

# /etc/init.d/oracleasm restart

The configuration file /etc/sysconfig/oracleasm parameters “ORACLEASM_SCANORDER”

and “ORACLEASM_SCANEXCLUDE” were updated, but after restarting the Oracleasm service the changes were not put into effect.

For example: multipath was configured and the “dm-” devices are presented.The “/etc/sysconfig/oracleasm” file was configured accordingly:

# ORACLEASM_SCANORDER: Matching patterns to order disk scanning
ORACLEASM_SCANORDER=”dm”

# ORACLEASM_SCANEXCLUDE: Matching patterns to exclude disks from scan
ORACLEASM_SCANEXCLUDE=”sd”

Caso não consiga
[root@rac1 sysconfig]# /usr/sbin/oracleasm configure
ORACLEASM_ENABLED=true
ORACLEASM_UID=oracle
ORACLEASM_GID=dba
ORACLEASM_SCANBOOT=true
ORACLEASM_SCANORDER=”"
ORACLEASM_SCANEXCLUDE=”"

Solução
Remover Manualmente o arquivo criado e criar um soft-link:

# mv /etc/sysconfig/oracleasm /etc/sysconfig/oracleasm_bak
# ln oracleasm-_dev_oracleasm /etc/sysconfig/oracleasm

Subsequentemente edite o arquivo /etc/sysconfig/oracleasm e verifique se está corretamente aplicado.

Note: Qualquer alteração no arquivo de configuração requer  restart do OracleASM para que as alterações sejam efetivadas:
# /etc/init.d/oracleasm restart

Selecione as Variáveis:

Mofique nas 2 maquinas
1. Modifique os parametros no arquivo /etc/sysconfig/oracleasm:
ORACLEASM_SCANORDER=”dm”
ORACLEASM_SCANEXCLUDE=”sd”

2. Reinicie o ASMLIB:
# /etc/init.d/oracleasm restart

Resultado Final terá que ficar assim em todos os Nodes:
[root@rac1 sysconfig]# /usr/sbin/oracleasm configure
ORACLEASM_ENABLED=true
ORACLEASM_UID=oracle
ORACLEASM_GID=dba
ORACLEASM_SCANBOOT=true
ORACLEASM_SCANORDER=”dm”
ORACLEASM_SCANEXCLUDE=”sd”

==============================================================================================================

Com isso o Grid InfraStructure reconhecerá os discos

==============================================================================================================

Configurações de Rede cada Servidor possui 4 placas de Rede(Recomendado para Oracle RAC):

[root@rac1 ~]# ifconfig

eth0      Link encap:Ethernet  HWaddr B8:AC:6F:14:3E:06

inet addr:10.0.0.3  Bcast:10.0.0.255  Mask:255.255.255.0

inet6 addr: fe80::baac:6fff:fe14:3e06/64 Scope:Link

eth1      Link encap:Ethernet  HWaddr B8:AC:6F:14:3E:08

inet addr:192.168.0.3  Bcast:192.168.0.255  Mask:255.255.255.0

inet6 addr: fe80::baac:6fff:fe14:3e08/64 Scope:Link

eth2      Link encap:Ethernet  HWaddr B8:AC:6F:14:3E:0A

inet addr:192.168.130.50  Bcast:192.168.130.255  Mask:255.255.255.0

inet6 addr: fe80::baac:6fff:fe14:3e0a/64 Scope:Link

eth3      Link encap:Ethernet  HWaddr B8:AC:6F:14:3E:0C

inet addr:192.168.130.51  Bcast:192.168.130.255  Mask:255.255.255.0

inet6 addr: fe80::baac:6fff:fe14:3e0c/64 Scope:Link

lo        Link encap:Local Loopback

inet addr:127.0.0.1  Mask:255.0.0.0

inet6 addr: ::1/128 Scope:Host

==============================================================================================================

[root@rac2 ~]# ifconfig

eth0      Link encap:Ethernet  HWaddr B8:AC:6F:13:E1:C7

inet addr:10.0.0.4  Bcast:10.0.0.255  Mask:255.255.255.0

inet6 addr: fe80::baac:6fff:fe13:e1c7/64 Scope:Link

eth1      Link encap:Ethernet  HWaddr B8:AC:6F:13:E1:C9

inet addr:192.168.0.4  Bcast:192.168.0.255  Mask:255.255.255.0

inet6 addr: fe80::baac:6fff:fe13:e1c9/64 Scope:Link

eth2      Link encap:Ethernet  HWaddr B8:AC:6F:13:E1:CB

inet addr:192.168.130.52  Bcast:192.168.130.255  Mask:255.255.255.0

inet6 addr: fe80::baac:6fff:fe13:e1cb/64 Scope:Link

eth3      Link encap:Ethernet  HWaddr B8:AC:6F:13:E1:CD

inet addr:192.168.130.53  Bcast:192.168.130.255  Mask:255.255.255.0

inet6 addr: fe80::baac:6fff:fe13:e1cd/64 Scope:Link

lo        Link encap:Local Loopback

inet addr:127.0.0.1  Mask:255.0.0.0

inet6 addr: ::1/128 Scope:Host

==============================================================================================================

INSTALAÇÃO DO GRID INFRASTRUCTURE

==============================================================================================================

==============================================================================================================

Uma novidade durante a instalação do Grid Infrastructure é que ele configura a Conectividade do SSH.

Eu testei e realmente funciona, não precisando configurar no linux como faziamos no Oracle RAC 10g


Caso nesta tela não apareça os discos será necessário executar os passos abaixo:

Configurar Multipath se não o Grid InfraStructure não irá achar os ASM DISKS

==============================================================================================================
Conforme Nota no Suporte Oracle seguir os procedimentos abaixo:

Rodar em todos os Nodes,

1. Modify the /etc/sysconfig/oracleasm with:

ORACLEASM_SCANORDER=”dm” ORACLEASM_SCANEXCLUDE=”sd”

==============================================================================================================

2. restart the asmlib by : # /etc/init.d/oracleasm restart

==============================================================================================================

The configuration file /etc/sysconfig/oracleasm parameters “ORACLEASM_SCANORDER” and “ORACLEASM_SCANEXCLUDE” were updated,

but after restarting the Oracleasm service the changes were not put into effect.

For example: multipath was configured and the “dm-” devices are presented.

The “/etc/sysconfig/oracleasm” file was configured accordingly:

# ORACLEASM_SCANORDER:

Matching patterns to order disk scanning

ORACLEASM_SCANORDER=”dm”

# ORACLEASM_SCANEXCLUDE:

Matching patterns to exclude disks from scan

ORACLEASM_SCANEXCLUDE=”sd”

Caso não consiga

[root@rac1 sysconfig]# /usr/sbin/oracleasm configure

ORACLEASM_ENABLED=true

ORACLEASM_UID=oracle

ORACLEASM_GID=dba

ORACLEASM_SCANBOOT=true

ORACLEASM_SCANORDER=”"

ORACLEASM_SCANEXCLUDE=”"

==============================================================================================================

Solução

Remove the manually created file and create the soft-link:

# mv /etc/sysconfig/oracleasm /etc/sysconfig/oracleasm_bak

# ln oracleasm-_dev_oracleasm /etc/sysconfig/oracleasm

==============================================================================================================

Subsequent edits to /etc/sysconfig/oracleasm will then be correctly applied

Note: Any changes to the  configuration file requires a restart of OracleASM to take effect:

# /etc/init.d/oracleasm restart

==============================================================================================================

Selecione as Variáveis:

Mofique nas 2 maquinas 1.

Modifique o arquivo /etc/sysconfig/oracleasm:

ORACLEASM_SCANORDER=”dm”

ORACLEASM_SCANEXCLUDE=”sd”

==============================================================================================================

2. Reinicie ASMLIB:

/etc/init.d/oracleasm restart

==============================================================================================================

Resultado Final terá que ficar assim em todos os Nodes:

[root@rac1 sysconfig]# /usr/sbin/oracleasm configure

ORACLEASM_ENABLED=true

ORACLEASM_UID=oracle

ORACLEASM_GID=dba

ORACLEASM_SCANBOOT=true

ORACLEASM_SCANORDER=”dm”

ORACLEASM_SCANEXCLUDE=”sd”

==============================================================================================================

Com isso o Grid InfraStructure reconhecerá os discos


Conforme a Nota no Suporte Oracle podemos ignorar este Erro conforme abaixo:

Device Checks for ASM Fails with PRVF-5150: Path xx is not a valid path on all nodes [ID 1210863.1]

Modified 10-OCT-2010     Type PROBLEM     Status MODERATED

In this Document
Symptoms
Cause
Solution


This document is being delivered to you via Oracle Support’s Rapid Visibility (RaV) process and therefore has not been subject to an independent technical review.

Applies to:

Oracle Server – Enterprise Edition – Version: 11.2.0.1 and later   [Release: 11.2 and later ]
Generic Linux

Symptoms

Device Checks for ASM Failed:

Device Checks for ASM – This is a pre-check to verity if the specified devices meet the requirements for configuration through the Oracle Universal Storage Manager Configuration Assistant.

Verification result of failed node: racnode1

List of errors:

- PRVF-5150: Path ORCL:DISKCLU is not a valid path on all nodes

Operation Failed on Nodes: [racnode1]

List of errors:

-  Could not get the type of storage

- Cause: Cause of Problem Not Available

- Action: User Action Not Available

Cause

Unpublished bug 10026970

Solution

At the time of this writing, bug 10026970 is not fixed yet. If ASM device passes manual verification, the warning can be ignored.

To verify asmlib status:

/etc/init.d/oracleasm status

Checking if ASM is loaded:                                  [  OK  ]

Checking if /dev/oracleasm is mounted:                [  OK  ]
## Both should be [OK]

To verify user setting in asmlib:
id <grid user>
uid=1001(grid) gid=1000(oinstall) groups=1000(oinstall)

/usr/sbin/oracleasm configure

ORACLEASM_ENABLED=true

ORACLEASM_UID=grid

ORACLEASM_GID=oinstall

ORACLEASM_SCANBOOT=true

ORACLEASM_SCANORDER=”"

ORACLEASM_SCANEXCLUDE=”"

## both ORACLEASM_UID and ORACLEASM_GID should match id output for grid user.

To verify disk

/etc/init.d/oracleasm listdisks

DISKCLU

ls -l /dev/oracleasm/disks

..

brw-rw—-    1 grid oinstall        8,  33 Sep 16 09:41 DISKCLU

dd if=/dev/oracleasm/disks/DISKCLU of=/dev/null bs=1024k count=1

1+0 records in

1+0 records out

## Disk DISKCLU is available and readable from above output.

[root@rac1 /]# /etc/init.d/oracleasm status

Checking if ASM is loaded: yes

Checking if /dev/oracleasm is mounted: yes

[root@rac2 /]# /etc/init.d/oracleasm status

Checking if ASM is loaded: yes

Checking if /dev/oracleasm is mounted: yes


[root@rac1 /]# /u01/app/oraInventory/orainstRoot.sh

Changing permissions of /u01/app/oraInventory.

Adding read,write permissions for group.

Removing read,write,execute permissions for world.

Changing groupname of /u01/app/oraInventory to oinstall.

The execution of the script is complete.

[root@rac1 /]#

==============================================================================================================

[root@rac2 /]# /u01/app/oraInventory/orainstRoot.sh

Changing permissions of /u01/app/oraInventory.

Adding read,write permissions for group.

Removing read,write,execute permissions for world.

Changing groupname of /u01/app/oraInventory to oinstall.

The execution of the script is complete.

==============================================================================================================

[root@rac1 /]# /u01/app/11.2.0/grid/root.sh

Running Oracle 11g root script…

The following environment variables are set as:

ORACLE_OWNER= oracle

ORACLE_HOME=  /u01/app/11.2.0/grid

Enter the full pathname of the local bin directory: [/usr/local/bin]:

Copying dbhome to /usr/local/bin …

Copying oraenv to /usr/local/bin …

Copying coraenv to /usr/local/bin …

Creating /etc/oratab file…

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 script.

Now product-specific root actions will be performed.

Using configuration parameter file: /u01/app/11.2.0/grid/crs/install/crsconfig_params

Creating trace directory

LOCAL ADD MODE

Creating OCR keys for user ‘root’, privgrp ‘root’..

Operation successful.

OLR initialization – successful

root wallet

root wallet cert

root cert export

peer wallet

profile reader wallet

pa wallet

peer wallet keys

pa wallet keys

peer cert request

pa cert request

peer cert

pa cert

peer root cert TP

profile reader root cert TP

pa root cert TP

peer pa cert TP

pa peer cert TP

profile reader pa cert TP

profile reader peer cert TP

peer user cert

pa user cert

Adding daemon to inittab

ACFS-9200: Supported

ACFS-9300: ADVM/ACFS distribution files found.

ACFS-9307: Installing requested ADVM/ACFS software.

ACFS-9308: Loading installed ADVM/ACFS drivers.

ACFS-9321: Creating udev for ADVM/ACFS.

ACFS-9323: Creating module dependencies – this may take some time.

ACFS-9327: Verifying ADVM/ACFS devices.

ACFS-9309: ADVM/ACFS installation correctness verified.

CRS-2672: Attempting to start ‘ora.mdnsd’ on ‘rac1′

CRS-2676: Start of ‘ora.mdnsd’ on ‘rac1′ succeeded

CRS-2672: Attempting to start ‘ora.gpnpd’ on ‘rac1′

CRS-2676: Start of ‘ora.gpnpd’ on ‘rac1′ succeeded

CRS-2672: Attempting to start ‘ora.cssdmonitor’ on ‘rac1′

CRS-2672: Attempting to start ‘ora.gipcd’ on ‘rac1′

CRS-2676: Start of ‘ora.cssdmonitor’ on ‘rac1′ succeeded

CRS-2676: Start of ‘ora.gipcd’ on ‘rac1′ succeeded

CRS-2672: Attempting to start ‘ora.cssd’ on ‘rac1′

CRS-2672: Attempting to start ‘ora.diskmon’ on ‘rac1′

CRS-2676: Start of ‘ora.diskmon’ on ‘rac1′ succeeded

CRS-2676: Start of ‘ora.cssd’ on ‘rac1′ succeeded

ASM created and started successfully.

Disk Group GRIDDATA created successfully.

clscfg: -install mode specified

Successfully accumulated necessary OCR keys.

Creating OCR keys for user ‘root’, privgrp ‘root’..

Operation successful.

CRS-4256: Updating the profile

Successful addition of voting disk 9fdb329eb3924f82bf5261c58e3fc2d5.

Successfully replaced voting disk group with +GRIDDATA.

CRS-4256: Updating the profile

CRS-4266: Voting file(s) successfully replaced

##  STATE    File Universal Id                File Name Disk group

–  —–    —————–                ——— ———

1. ONLINE   9fdb329eb3924f82bf5261c58e3fc2d5 (ORCL:OCR01) [GRIDDATA]

Located 1 voting disk(s).

CRS-2672: Attempting to start ‘ora.asm’ on ‘rac1′

CRS-2676: Start of ‘ora.asm’ on ‘rac1′ succeeded

CRS-2672: Attempting to start ‘ora.GRIDDATA.dg’ on ‘rac1′

CRS-2676: Start of ‘ora.GRIDDATA.dg’ on ‘rac1′ succeeded

ACFS-9200: Supported

ACFS-9200: Supported

CRS-2672: Attempting to start ‘ora.registry.acfs’ on ‘rac1′

CRS-2676: Start of ‘ora.registry.acfs’ on ‘rac1′ succeeded

Configure Oracle Grid Infrastructure for a Cluster … succeeded

[root@rac1 /]#

==============================================================================================================

[root@rac2 /]# /u01/app/11.2.0/grid/root.sh

Running Oracle 11g root script…

The following environment variables are set as:

ORACLE_OWNER= oracle

ORACLE_HOME=  /u01/app/11.2.0/grid

Enter the full pathname of the local bin directory: [/usr/local/bin]:

Copying dbhome to /usr/local/bin …

Copying oraenv to /usr/local/bin …

Copying coraenv to /usr/local/bin …

Creating /etc/oratab file…

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 script.

Now product-specific root actions will be performed.

Using configuration parameter file: /u01/app/11.2.0/grid/crs/install/crsconfig_params

Creating trace directory

LOCAL ADD MODE

Creating OCR keys for user ‘root’, privgrp ‘root’..

Operation successful.

OLR initialization – successful

Adding daemon to inittab

ACFS-9200: Supported

ACFS-9300: ADVM/ACFS distribution files found.

ACFS-9307: Installing requested ADVM/ACFS software.

ACFS-9308: Loading installed ADVM/ACFS drivers.

ACFS-9321: Creating udev for ADVM/ACFS.

ACFS-9323: Creating module dependencies – this may take some time.

ACFS-9327: Verifying ADVM/ACFS devices.

ACFS-9309: ADVM/ACFS installation correctness verified.

CRS-4402: The CSS daemon was started in exclusive mode but found an active CSS daemon on node rac1, number 1, and is terminating

An active cluster was found during exclusive startup, restarting to join the cluster

Configure Oracle Grid Infrastructure for a Cluster … succeeded

[root@rac2 /]#

==============================================================================================================

Grid InfraStructure do Cluster Instalado com sucesso !

==============================================================================================================

INSTALAÇÃO DO SOFTWARE ORACLE 11G R2 11.2.0.2

==============================================================================================================

==============================================================================================================

==============================================================================================================


[root@rac1 /]# /u01/app/oracle/product/11.2.0/ajr/root.sh

Running Oracle 11g root script…

The following environment variables are set as:

ORACLE_OWNER= oracle

ORACLE_HOME=  /u01/app/oracle/product/11.2.0/ajr

Enter the full pathname of the local bin directory: [/usr/local/bin]:

The contents of “dbhome” have not changed. No need to overwrite.

The contents of “oraenv” have not changed. No need to overwrite.

The contents of “coraenv” have not changed. No need to overwrite.

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 script.

Now product-specific root actions will be performed.

Finished product-specific root actions.

[root@rac1 /]#

==============================================================================================================

[root@rac2 /]# /u01/app/oracle/product/11.2.0/ajr/root.sh

Running Oracle 11g root script…

The following environment variables are set as:

ORACLE_OWNER= oracle

ORACLE_HOME=  /u01/app/oracle/product/11.2.0/ajr

Enter the full pathname of the local bin directory: [/usr/local/bin]:

The contents of “dbhome” have not changed. No need to overwrite.

The contents of “oraenv” have not changed. No need to overwrite.

The contents of “coraenv” have not changed. No need to overwrite.

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 script.

Now product-specific root actions will be performed.

Finished product-specific root actions.

[root@rac2 /]#

==============================================================================================================

Software Oracle 11g 11.2.0.2 Instalado com sucesso !

==============================================================================================================

ASMCA – Criar Disk Group para armazenamento do Banco de Dados

==============================================================================================================

ASMCA uma nova Feature do Oracle 11gR2 no qual pode criar e gerenciar DiskGroups.

/u01/app/11.2.0/bin/asmca




==============================================================================================================

Disk Group criado com sucesso !

==============================================================================================================

DBCA – CRIAÇÃO DO BANCO DE DADOS COM DBCA

==============================================================================================================


==============================================================================================================

Banco de Dados Oracle Criado com Sucesso !

==============================================================================================================

Para finalizar segue alguns comandos de administração do Oracle RAC 11g R2:

Parar Enterprise Manager

[oracle@rac1 ~]$ emctl stop dbconsole

Iniciar Enterprise Manager

[oracle@rac1 ~]$ emctl start dbconsole

==============================================================================================================

Parar todos os Listerners

[oracle@rac1 ~]$ srvctl stop listener

Iniciar todos os Listerners

[oracle@rac1 ~]$ srvctl start listener

==============================================================================================================

Parar apenas um Listener (AJR1)

[oracle@rac1 ~]$ srvctl stop listener -n AJR1

Iniciar apenas um Listener (AJR1)

[oracle@rac1 ~]$ srvctl start listener -n AJR1

==============================================================================================================

Parar apenas uma Instancia(AJR2)

[oracle@rac1 ~]$ srvctl  stop instance -d AJR -i AJR2

Iniciar apenas uma Instancia(AJR2)

[oracle@rac1 ~]$ srvctl start  instance -d AJR -i AJR2

==============================================================================================================

Parar todas as Instancias e Banco de Dados

[oracle@rac1 ~]$ srvctl stop database -d RAC

Iniciar todas as Instancias e Banco de Dados

[oracle@rac1 ~]$ srvctl start database -d RAC

==============================================================================================================

Verificar o Cluster

Cluster [root@rac1 /]# /u01/app/11.2.0/grid/bin/crsctl check cluster

CRS-4537: Cluster Ready Services is online

CRS-4529: Cluster Synchronization Services is online

CRS-4533: Event Manager is online

=============================================================================================================

Parar o Cluster (detalhe com usuario root)

[root@rac1 /]# /u01/app/11.2.0/grid/bin/crsctl stop cluster

Iniciar o Cluster (detalhe com usuario root)

[root@rac1 /]# /u01/app/11.2.0/grid/bin/crsctl start cluster

==============================================================================================================

Bom Pessoal espero ter ajudado.

Abraço,

Bruno Murassaki


11 Comentários »

  1. Olá Bruno..
    Muito bom o artigo..vou simular em maquina virtual para aprender alguns passos contigo..
    Abraços

    Comentário por Emerson — maio 13, 2011 @ 12:24 pm | Responder

  2. Bem Bruno, nem preciso comentar não é mesmo?
    Acompnahei de longe parte deste processo, e desde o inicio sempre disse que você conseguiria, mesmo depois de tantas conversas, rss….Esta ai a maior prova do seu empenho e esforço. Meus sinceros parabéns a todos os envolvidos neste projeto em especial ao Bruno que prova mais uma vez sua excelente qualidade como profissional Oracle.

    Abraço

    Comentário por David Siqueira — maio 16, 2011 @ 2:10 pm | Responder

  3. Bruno,

    Parábens pelo artigo! Realmente, um guia de instalação muito bom.

    Abraços,
    Rodrigo Almeida

    Comentário por Rodrigo Almeida — maio 16, 2011 @ 4:42 pm | Responder

  4. Olá Bruno,
    parabéns pelo seu excelente artigo, muito bom.

    Queria saber se alguém já teve este problema que eu tenho:

    Instalei recentemente um Oracle RAC 11.2.0.2 com 3 nodes em windows 2008 R2 Enterprise.
    Na aplicação estou usando o client 11.2.0.2 e na configuração do tnsnames uso apenas o nome do scan (que resolve por DNS).

    Quando faço reboot a um dos nodes o sistema demora cerca de uma hora até estabilizar e durante esse tempo tenho erros intermitentes ao conectar a partir do sqlplus do client.

    Alguma dica para melhorar esta situação ?

    Muito Obrigado,
    Jorge Ferreira

    Comentário por Jorge Ferreira — junho 2, 2011 @ 11:01 am | Responder

  5. Parabens Bruno! o seu artigo ficou ótimo. Com certeza irá me ajudar muito.
    Obrigado.

    Comentário por Vlamir Duarte Novaes — junho 4, 2011 @ 12:36 am | Responder

  6. Parabéns,

    Ficou ótimo este guia.

    Sds.

    Comentário por Junior Assunção — julho 15, 2011 @ 2:13 pm | Responder

  7. Parabéns Bruno! Já utilizei para para consulta…. :)

    Eder Ferreira

    Comentário por eder — agosto 21, 2011 @ 2:47 pm | Responder

  8. Ficou muito didático. Seu blog está muito bom, parabéns!

    Comentário por Luis Adelson — fevereiro 16, 2012 @ 2:30 pm | Responder

    • Obrigado Luis pelo comentário.
      Infelizmente na correria da vida de DBA estou sem tempo para postar mais artigos.
      Abraço
      Bruno Murassaki

      Comentário por brunomurassaki — fevereiro 16, 2012 @ 2:53 pm | Responder


Feed RSS para comentários sobre este post. URI de trackback

Deixe uma resposta

Preencha os seus dados abaixo ou clique em um ícone para log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Sair / Alterar )

Imagem do Twitter

You are commenting using your Twitter account. Sair / Alterar )

Foto do Facebook

You are commenting using your Facebook account. Sair / Alterar )

Connecting to %s

Tema: Rubric. Blog no WordPress.com.

Seguir

Obtenha todo post novo entregue na sua caixa de entrada.