Você está na página 1de 100

Step by Step Install of Oracle RAC 11gR2 on OEL 6.

5 on Oracle VM Virtual BOX Here I am listing out the steps to install 11gR2 RAC on OS OEL6.5 on Oracle VM Virtual BOX. Step1: Create new Virtual BOX VM. Click on new and provide Name as rac1 type as Linux and version as Oracle 64bit. Click Next

Step2: Set Base Memory to 3072 MB, then click the "Next" button

Step3:Accept the default option to create a new virtual hard disk by clicking the "Create" button

Step:4 Select the default VMDK type and click the "Next" button on the Create Virtual Hard Drive screen

Step5: Select Dynamically Allocated and select option split into files of less than 2gb Click next

Step6: Provide the location where you want to save the VM files. In my case I have provided path as below. Also increase the size of your vm from default to say 50GB and Click Create

Once we click on Create we get rac1 vm created as highlighted below:

Step7:Click on General->Advanced and change shared clipboard to Bidirectional and Change Drag n Drop to Bidirectional and click Ok

Step8: Click on Network

Add three Adaptors. a. Make sure "Adapter 1" is enabled, attached to "Internal Network" or "Host-only Adapter". This interface will be used for public network, for example, for connection to the RAC datbase from other applications. More about networking will be explained later. On the screenshot below "Internal Network" is selected and name "pubnet" was given to this network

b.Then click on the "Adapter 2" tab. Make sure "Adapter 2" is enabled and attach to "Internal Network". Name this network "privnet":

Then finally click on the "Adapter 3", enable it, and attach to "Bridged Adapter" or "NAT". This adapter will be used for internet. Then press "OK" button

Step:9 Click on storage

Step10:Select OEl6.5 ISO and click ok

Step11 Click on Shared Folder

Now we can see shared folders with 1 value. It Means we are sharing a folder/drive from Host machine to Guest.

Step12: Click on Start as shown below

Step13. After starting we get below screen and select Install or Upgrade an Existing System.

Step14: Select skip

Step15:Scroll Down and click NEXT

Step16: Click Next

Step17:Click Next

Step18: Select basic Storage and click Next

Step19: Select Discard any Data

Step20: Change the hostname as below(not mandatory that it should be same as below

Scroll down and click on Configure Network

Step20:Select System eth0 and click on edit

Step21: Select Connect Automatically and select IPV4 Setting

Step22: Make sure that "Connect automatically" is checked. Select "IPv4 Settings" tab; change Method to "Manual"; Press "Add" and fill Address: 192.168.56.71; Netmask: 255.255.255.0; Gateway: 0.0.0.0. Press "Apply" then done:

Step23: Now select System eth1 and click on edit

Step24: In the Network Connections screen select "System eth1" interface, this will be used for private network, then press "Edit". Then check the box "Connect automatically". Select "IPv4 Settings" tab; change Method to "Manual". Press "Add" and fill Address: 192.168.10.1; Netmask: 255.255.255.0; Gateway: 0.0.0.0. When done, press "Apply":

Step25: Finally select "System eth2" interface, this will be used for Internet, then press "Edit". Check the box "Connect automatically". Select "IPv4 Settings" tab make sure the Method is set to "Automatic (DHCP)".Press "Apply" button:

Step26: Click Next

Step27:Give password for root

Step28:

Step29:Click next

Step30:Select on Format

Step31:Select Write Changes to disk

Step32:Click Next

Step33: Select Database Server option and select Customize now and Click Next

Step34:Select Tiger VNC (Not Manadatory). I sometimes prefer using vnc

Step35:Select options as below for Desktop and Click Next

NOW Sit and Relax.

We are done with the installation of OEL 6.5: Click Reboot. 36:After Reboot: Click on Forward

37:Licence Info: Click Forward

Step38:Click Forward

Click39:

Step40:Click Forward

Step41:Click Forward

Step42:Click Finish

Step43:Login into the Server using root

First of all check whether we can connect to the internet or not

I will use putty to connect to Guest Linux.

Change the /etc/hosts entries as below # Public 192.168.56.71 192.168.56.72 # Private 192.168.10.1 192.168.10.2 # Virtual 192.168.56.81

rac1.localdomain rac2.localdomain

rac1 rac2

rac1-priv.localdomain rac1-priv rac2-priv.localdomain rac2-priv rac1-vip.localdomain rac1-vip

192.168.56.82 # SCAN 192.168.56.91 192.168.56.92 192.168.56.93

rac2-vip.localdomain rac2-vip rac-scan.localdomain rac-scan rac-scan.localdomain rac-scan rac-scan.localdomain rac-scan

Step44: Install Virtual BOX Software

Step45:Click OK

Step47:Click on RUN

Ste48: It is failed

HERE>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>. Step50: Follow my previous post

http://oracleappsdbar12.wordpress.com/2013/11/10/virtualbox-error-tmpvbox-0makefile-include-header97-error-unableto-find-the-sources-of-your-current-linux-kernel-specify-kern_dir/
To overcome this error update gcc using 1.yum update gcc 2. yum update 3. yum install kernel-uek-devel

Say Yes Once this is installed Reboot the Server. Once again try to install VM tools

Lets see what happens this time This time it went fine now reboot the server

Reboot. Purpose we will be able to view the shared folders in Linux Guest. Step51: Now we need to disable the firewall: Linux Main menu | System | Administration | Firewall. Click on "Disable" icon, then on "Apply".

Stop and Disable

Step52: Copy the software from shared folder to tmp and change the permissions to read write execute on zip files

Step53: Install oracle-rdbms-server-11gR2-preinstall using yum

Step54:

Select Y Install ASM packages as below

groupadd -g 1000 oinstall groupadd -g 1200 dba useradd -u 1100 -g oinstall -G dba oracle passwd oracle

Passwd oracle Create Passwd for oracle user Step54: Create the directory in which the Oracle software will be installed.
mkdir -p /u01/app/11.2.0.3/grid

mkdir -p /u01/app/oracle/product/11.2.0.3/db_1 chown -R oracle:oinstall /u01 chmod -R 775 /u01/

Step55: Disable secure linux by editing the "/etc/selinux/config" file, making sure the SELINUX flag is set as follows. SELINUX=disabled Change Enforcing to disabled

Add or amend the following lines to the "/etc/sysctl.conf" file. fs.aio-max-nr = 1048576 fs.file-max = 6815744 #kernel.shmall = 2097152 #kernel.shmmax = 1054504960 kernel.shmmni = 4096 # semaphores: semmsl, semmns, semopm, semmni kernel.sem = 250 32000 100 128 net.ipv4.ip_local_port_range = 9000 65500 net.core.rmem_default=262144 net.core.rmem_max=4194304 net.core.wmem_default=262144 net.core.wmem_max=1048586 Run the following command to change the current kernel parameters. /sbin/sysctl p

Add the following lines to the "/etc/security/limits.conf" file. oracle oracle oracle oracle oracle soft nproc 2047 hard nproc 16384 soft nofile 4096 hard nofile 65536 soft stack 10240

# service iptables stop # chkconfig iptables off Step57: Either configure NTP, or make sure it is not configured so the Oracle Cluster Time Synchronization Service (ctssd)
can synchronize the times of the RAC nodes. If you want to deconfigure NTP do the following. # service ntpd stop Shutting down ntpd: # chkconfig ntpd off # mv /etc/ntp.conf /etc/ntp.conf.orig # rm /var/run/ntpd.pid

OK

If you want to use NTP, you must add the "-x" option into the following line in the "/etc/sysconfig/ntpd" file. OPTIONS="-x -u ntp:ntp -p /var/run/ntpd.pid"

Then restart NTP. # service ntpd restart

Now we will shut down the server as we need to add asm disks. Before we add asm disks. We will backup our vm Backup VM. Click File export Appliance

Select our VM and click next

Save to some location

Click next and click export

Ok We done with the backup now add disks for ASM storage. TO add disks click on storage

Add ASMDISK3 as well

Now Restore the Backup that was taken earlier and change it as Rac2

Change the name as Rac2

Scroll down

Click Import After import we got RAC2 VM

Change the disks to shared that were created earlier for ASM

Do the same for all the ASMDISKs Now once this is done click on RAC2 Vm and Storage

Do the same for other two disks

Start the RAC2 VM

If we see here it is still rac1. Hostname has to be changed

Change the domain

Change the IP addresses

Reboot

If there is any problem then restart network services

Service network restart Now check whether you are able to ping the hosts as below from rac1

Now repeat for rac2 as well.

Install Oracleasmlib. I have downloaded file from http://www.oracle.com/technetwork/server-storage/linux/asmlib/ol6-1709075.html

Do the same with other storage devices i.e for /dev/sdc and /dev/sdd Configure OracleASM Configure ASMLib using the following command. # oracleasm configure -i

Do the same on rac2 as well


/usr/sbin/oracleasm init

On RAC2

Click on SSH Connectivity..

Give the password for grid and click next

Okay we see some issues with RPMs Lets install one after the other using yum

Now we have 3 issues 1. Asm 2. Ntp issue--ignore 3. Resolve.conf---ignore

1.ASM

Here the issue is with group. Installation is looking for oinstall group for disks. Lets check the group on the server

Repeat the same on RAC2 server as well

Now Issue with ASM is resolved now we will move on to second issue 2.NTP

If you want to use NTP, you must add the "-x" option into the following line in the /etc/sysconfig/ntpd file. OPTIONS="-x -u ntp:ntp -p /var/run/ntpd.pid"

Start running orainstRoot.sh on rac1 first

On RAC2

Root.sh on RAC1

On RAC2 Now:

SCAN Issue can be resolved using below

[root@rac1]# mv /usr/bin/nslookup /usr/bin/nslookup.original Next, create a new shell script named /usr/bin/nslookup as shown below while replacing 24.154.1.34 with your primary DNS, rac-scan with your SCAN host name, and 192.168.56.91 with your SCAN IP address: #!/bin/bash HOSTNAME=${1} if [[ $HOSTNAME = "racnode-cluster-scan" ]]; then echo "Server: 24.154.1.34" echo "Address: 24.154.1.34#53" echo "Non-authoritative answer:" echo "Name: racn-scan" echo "Address: 192.168.56.91 " else /usr/bin/nslookup.original $HOSTNAME Fi Finally, change the new nslookup shell script to executable: [root@rac1 ~]# chmod 755 /usr/bin/nslookup Remember to perform these actions on both Oracle RAC nodes. The new nslookup shell script simply echo's back your SCAN IP address whenever the CVU calls nslookup with your SCAN host name; otherwise, it calls the original nslookup binary. The CVU will now pass during the Oracle grid infrastructure installation when it attempts to verify your SCAN:

Checkagain will not work so need to run runInstaller again.

Você também pode gostar