Install-Oracle11g-ASM-Linux6.3-VBox

Install Oracle 11gR2 on Oracle Linux 6.3 with ASM

 Software
  • Oracle Linux 6.3
  • Virtual Box4.2.6
  • Oracle Grid 11.2.0.1
  • Oracle 11gR2( 11.2.0.1)

 Install the Oracle Linux on Virtual Box

Refer here.

Configure Hosts Name

/etc/hosts and /etc/sysconfig/network must have the host name.

image: http://lh3.ggpht.com/-3btRJXDyaP4/UOUQOVpc6nI/AAAAAAAACmU/xTlhJ2CeD_w/image_thumb%25255B66%25255D.png?imgmax=800
image
Configure Kernel Parameter and number of open file descriptor
Refer here for the Oracle Requirement and here for how to fix kernel parameters.

Install ASM package


  • ASM Kernel: Part of the Oracle Linux Kernel ( UEK). Can be upgrade from Oracle public yum repository. Part of Oracle Linux installation media.
  • ASM support: Can be upgrade from Oracle public yum repository. Part of Oracle Linux installation media.
  • ASM lib: Only can be download from Oracle side.
Kernel 2.6.39-300.17.3.el6uek will break the Virtual Box Guest Additions.
rpm -Uvh oracleasmlib-2.0.4-1.el6.x86_64.rpm
yum install oracleasm-support

image: http://lh5.ggpht.com/-S3l0qNnQDVc/UOUQPZReNnI/AAAAAAAACmk/0TesGeF9ExU/image_thumb%25255B1%25255D.png?imgmax=800
image

image: http://lh5.ggpht.com/-sYKNPGyHtio/UOUQQejuxXI/AAAAAAAACm0/VGd-wYvt9EI/image_thumb%25255B4%25255D.png?imgmax=800
image
Create user/group
groupadd dba
useradd grid -g dba
useradd oracle -g dba
# set password
passwd grid
passwd oracle

image: http://lh3.ggpht.com/-vMIHZCAPcLc/UOUQRPlRsWI/AAAAAAAACnE/yQgCDTOtDJo/image_thumb%25255B7%25255D.png?imgmax=800
image

Create Software installation folders

  • /u01/app/oracle –> for $ORACLE_BASE for Oracle Database instance
  • /u01/app/grid –> for $ORACLE_BASE for ASM instance
  • /u01/app/11.2.0/grid –> for $ORACLE_HOME for ASM instance

mkdir -p /u01/app/grid
mkdir -p /u01/app/11.2.0/grid
mkdir -p /u01/app/oracle
 
chown -R grid:dba /u01
chown -R oracle:dba /u01/app/oracle

image: http://lh4.ggpht.com/-TEa-nx4yMBw/UOUQRy_D2MI/AAAAAAAACnU/WaamqlY8D0Q/image_thumb%25255B11%25255D.png?imgmax=800
image

Configure oracle User profile

~oracle/.bash_profile
TMP=/tmp; export TMP
TMPDIR=$TMP; export TMPDIR
 
ORACLE_HOSTNAME=RAC1.localdomain; export ORACLE_HOSTNAME
ORACLE_UNQNAME=RAC; export ORACLE_UNQNAME
ORACLE_BASE=/u01/app/grid; export ORACLE_BASE
GRID_HOME=/u01/app/11.2.0/grid; export GRID_HOME
DB_HOME=/u01/app/oracle/product/11.2.0/db_1; export DB_HOME
ORACLE_HOME=$DB_HOME; export ORACLE_HOME
ORACLE_SID=RAC1; export ORACLE_SID
ORACLE_TERM=xterm; export ORACLE_TERM
BASE_PATH=/usr/sbin:$PATH; export BASE_PATH
PATH=$ORACLE_HOME/bin:$BASE_PATH; export PATH
 
LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib; export LD_LIBRARY_PATH
CLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib; export CLASSPATH
~oracle/.bashrc
alias grid_env='. /home/oracle/grid_env'
alias db_env='. /home/oracle/db_env'

~oracle//grid_env
ORACLE_SID=+ASM1; export ORACLE_SID
ORACLE_HOME=$GRID_HOME; export ORACLE_HOME
PATH=$ORACLE_HOME/bin:$BASE_PATH; export PATH
 
LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib; export LD_LIBRARY_PATH
CLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib; export CLASSPATH
~oracle//db_env
ORACLE_SID=RAC1; export ORACLE_SID
ORACLE_HOME=$DB_HOME; export ORACLE_HOME
ORACLE_BASE==/u01/app/oracle; export ORACLE_BASE
PATH=$ORACLE_HOME/bin:$BASE_PATH; export PATH
 
LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib; export LD_LIBRARY_PATH
CLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib; export CLASSPATH

Configure ASM

/etc/init.d/oracleasm configure

image: http://lh4.ggpht.com/-rzhXLbdSMXo/UOUQTH02YXI/AAAAAAAACnk/Y33Wf0nAaKc/image_thumb%25255B15%25255D.png?imgmax=800
image
Use chkconfig to check whether oracleasm service is set to start up automatically. and also check the /etc/rc.*/

image: http://lh6.ggpht.com/-SbLikEfkv4U/UOUQUM9AJbI/AAAAAAAACn0/ZRImmJFtAWM/image_thumb%25255B19%25255D.png?imgmax=800
image

Add Disk to VM

"C:\program Files\Oracle\VirtualBox\VBoxManage.exe" createhd --filename D:\VirtualBoxVM\OEL63\ASM_1.vdi --size 5120 --format VDI --variant Fixed
"C:\program Files\Oracle\VirtualBox\VBoxManage.exe" createhd --filename D:\VirtualBoxVM\OEL63\ASM_2.vdi --size 5120 --format VDI --variant Fixed
"C:\program Files\Oracle\VirtualBox\VBoxManage.exe" createhd --filename D:\VirtualBoxVM\OEL63\ASM_3.vdi --size 5120 --format VDI --variant Fixed
"C:\program Files\Oracle\VirtualBox\VBoxManage.exe" createhd --filename D:\VirtualBoxVM\OEL63\ASM_4.vdi --size 5120 --format VDI --variant Fixed
 
"C:\program Files\Oracle\VirtualBox\VBoxManage.exe" storageattach OEL63 --storagectl "SATA" --port 1 --device 0 --type hdd --medium D:\VirtualBoxVM\OEL63\ASM_1.vdi
"C:\program Files\Oracle\VirtualBox\VBoxManage.exe" storageattach OEL63 --storagectl "SATA" --port 2 --device 0 --type hdd --medium D:\VirtualBoxVM\OEL63\ASM_2.vdi
"C:\program Files\Oracle\VirtualBox\VBoxManage.exe" storageattach OEL63 --storagectl "SATA" --port 3 --device 0 --type hdd --medium D:\VirtualBoxVM\OEL63\ASM_3.vdi
"C:\program Files\Oracle\VirtualBox\VBoxManage.exe" storageattach OEL63 --storagectl "SATA" --port 4 --device 0 --type hdd --medium D:\VirtualBoxVM\OEL63\ASM_4.vdi
 

image: http://lh4.ggpht.com/-BsYYofSPNlk/UOUQWuKAGJI/AAAAAAAACoE/32vz8Nn92xo/image_thumb%25255B28%25255D.png?imgmax=800
image

image: http://lh4.ggpht.com/-RI7SgJM9gJE/UOUQZEh2wWI/AAAAAAAACoU/5_PgmBUElyI/image_thumb%25255B25%25255D.png?imgmax=800
image

Partition Disks

All Disks needed to be partition first. Refer here.

image: http://lh5.ggpht.com/-vd7d7xDhXJw/UOUQanvRDqI/AAAAAAAACok/KojKvSKLGTs/image_thumb%25255B30%25255D.png?imgmax=800
image

Create ASM Disk

Disk needs to be partition first before we use oracleasm.
# list all the disks
fdisk -l
oracleasm createdisk DISK_NAME DEVICE_NAME


image: http://lh3.ggpht.com/-DppriinnTU4/UOUQccUM8uI/AAAAAAAACo0/rIdtmqftJLs/image_thumb%25255B32%25255D.png?imgmax=800
image
oracleasm listdisks

image: http://lh6.ggpht.com/-M3JArj9iwbI/UOUQdUAD8bI/AAAAAAAACpE/jhy4OqgAR5k/image_thumb%25255B34%25255D.png?imgmax=800
image
oracleasm querydisk /dev/sdb1

image: http://lh3.ggpht.com/-JQVwxb4Xr_E/UOUQfVcEtyI/AAAAAAAACpU/_1ROL1JaYWg/image_thumb%25255B36%25255D.png?imgmax=800
image
Remove the ASM disk
oracleasm deletedisk DISK_NAME

image: http://lh5.ggpht.com/-x-2lnR72dWQ/UOUQg-bcbrI/AAAAAAAACpk/cGIOF4LJQGg/image_thumb%25255B22%25255D_thumb.png?imgmax=800
image_thumb[22]

Installing the oracle-rdbms-server-11gR2-preinstall RPM


 yum install oracle-rdbms-server-11gR2-preinstall

Refer here.

Install the Grid Infrastructure

Login as ‘grid’ user and Make sure the Below environment variables before execute the runInstaller .
  • $ORACLE_HOME
  • $ORACLE_BASE
  • $ORACLE_SID

image: http://lh3.ggpht.com/-UH_4715hBlk/UOUQh3uitPI/AAAAAAAACp0/LkUE1f0t4Vc/image_thumb%25255B60%25255D.png?imgmax=800
image
Execute ./runInstaller
Select “Install and Configure Grid Infrastructure for a standalone Server”

image: http://lh3.ggpht.com/-CKoIFWkbt_o/UOUQi4Zaq-I/AAAAAAAACqE/satFScHZTsg/image_thumb%25255B38%25255D.png?imgmax=800
image

image: http://lh4.ggpht.com/-91bVXgBOZqY/UOUQjiMQ2pI/AAAAAAAACqU/6280vVeHq5w/image_thumb%25255B40%25255D.png?imgmax=800
image
Name the disk group as DATA group.
Redundancy:
  • High: Similar to RAID 5. Require 3 disks.
  • Normal: Similar to RAID 1. Require 2 disks.
  • External: Single Disk. Rely on 3rd party vendor software to provide the redundancy.

image: http://lh4.ggpht.com/-xgtgt7Yi9WA/UOUQkts4emI/AAAAAAAACqk/-XilYyPU7QE/image_thumb%25255B42%25255D.png?imgmax=800
image
Create the SYS and ASMSNMP password. If it does not meet Oracle recommendation, the installer will give the warming.

image: http://lh5.ggpht.com/-5b6BhI1r8ic/UOUQlvtRdwI/AAAAAAAACq0/pqv5945LMwg/image_thumb%25255B45%25255D.png?imgmax=800
image


image: http://lh6.ggpht.com/-uynWUmAQUZY/UOUQmn7O6XI/AAAAAAAACrE/XQr4DWuTn4w/image_thumb%25255B48%25255D.png?imgmax=800
image
If OSDBA,OSPER and OSASM are using the same group, the installer would give the warming but wont affect the installation.

image: http://lh3.ggpht.com/-LiijIBO-QR4/UOUQnRSs3HI/AAAAAAAACrU/838J73_iqog/image_thumb%25255B52%25255D.png?imgmax=800
image

image: http://lh5.ggpht.com/-Dh41eoHdO9o/UOUQoON7IkI/AAAAAAAACrk/4fr8wwVq5xU/image_thumb%25255B63%25255D.png?imgmax=800
image

image: http://lh5.ggpht.com/-44ePXZWoUJg/UOUQo7hUTZI/AAAAAAAACr0/cfwpTbagnzs/image_thumb%25255B64%25255D.png?imgmax=800
image
Use yum or rpm to install the missing packages. However, the 11.2.0 installer does not recognize the newer version of package therefore, if the system already has the newer version of the packages, it can be ignore. Below screenshot lists the common packages that can be ignore due to the installer does not recognize the newer package.
  • “pdksh” can be ignore as ksh has taken its place by  “oracle-rdbms-server-11gR2-preinstall”.
  • i386 packages has been replace by the i686 correspond packages.  Only need to make sure the i686 packages installed.



image: http://lh6.ggpht.com/-7p80YRghfaM/UOUQpw4BBgI/AAAAAAAACsE/dJSlHhBlQgs/image_thumb%25255B71%25255D.png?imgmax=800
image
yum list PACKAGE_NAME
yum install PACKAGE_NAME

image: http://lh4.ggpht.com/-87l6Pytry70/UOUQqjcAowI/AAAAAAAACsU/Ki8pZQCQa6o/image_thumb%25255B73%25255D.png?imgmax=800
image

image: http://lh3.ggpht.com/-xhihgfmGS6g/UOUQro6rGKI/AAAAAAAACsk/uT7M4SyPyO4/image_thumb%25255B76%25255D.png?imgmax=800
image

image: http://lh6.ggpht.com/-cq-d122E3FM/UOUQslm-anI/AAAAAAAACs0/DixhyVf_qvA/image_thumb%25255B78%25255D.png?imgmax=800
image

image: http://lh4.ggpht.com/-8TS_LdurNbI/UOUQtfMtjGI/AAAAAAAACtE/f9iM6LziQr8/image_thumb%25255B81%25255D.png?imgmax=800
image

image: http://lh6.ggpht.com/-OCSWXVymzP0/UOUQuZB7e5I/AAAAAAAACtU/BBdfdsxLGeA/image_thumb%25255B82%25255D.png?imgmax=800
image
Root.sh would fail to execute at Linux 6.3. The solution is here.

Install Oracle Database

Login as ‘oracle’ user and Make sure the Below environment variables before execute the runInstaller .
  • $ORACLE_HOME
  • $ORACLE_BASE
  • $ORACLE_SID

image: http://lh3.ggpht.com/-t5TRSXjxuqI/UOUQvJZBbEI/AAAAAAAACtk/OcRR5bk_rCw/image_thumb%25255B88%25255D.png?imgmax=800
image
Execute runinstaller

image: http://lh5.ggpht.com/-Q1sF2_pPz7s/UOUQv1VslRI/AAAAAAAACt0/n9Ead_J_xJI/image_thumb%25255B86%25255D.png?imgmax=800
image

image: http://lh3.ggpht.com/-hM7fcWq6fsc/UOUQw1RSIrI/AAAAAAAACuE/g9e8BOytuR8/image_thumb%25255B90%25255D.png?imgmax=800
image

image: http://lh5.ggpht.com/-nhOYVUTf0i4/UOUQxoqpNtI/AAAAAAAACuU/DAmTb_ZjzRY/image_thumb%25255B92%25255D.png?imgmax=800
image

image: http://lh4.ggpht.com/-hRSgDCbl5j8/UOUQymvU5rI/AAAAAAAACuk/iib9xeGlJoQ/image_thumb%25255B95%25255D.png?imgmax=800
image

image: http://lh5.ggpht.com/-TKA-ORJugDI/UOUQzVMacUI/AAAAAAAACu0/EC0GnD7xueQ/image_thumb%25255B96%25255D.png?imgmax=800
image

image: http://lh5.ggpht.com/-ECedOCTlQXc/UOUQ0OHvG3I/AAAAAAAACvE/lGVY4BNsUNA/image_thumb%25255B100%25255D.png?imgmax=800
image

image: http://lh4.ggpht.com/-DgsdnE1Nl-A/UOUQ0zzvP-I/AAAAAAAACvU/-IkuiPPI6hE/image_thumb%25255B99%25255D.png?imgmax=800
image

image: http://lh4.ggpht.com/-8FQZR9qxKhw/UOUQ1x_zZqI/AAAAAAAACvk/Ch0CmNXhu-0/image_thumb%25255B102%25255D.png?imgmax=800
image

image: http://lh5.ggpht.com/-z1_HOZsnDi0/UOUQ2rOZdYI/AAAAAAAACv0/O8u-hHtYJEI/image_thumb%25255B104%25255D.png?imgmax=800
image

image: http://lh6.ggpht.com/-5V17bNqHorY/UOUQ3pyu9kI/AAAAAAAACwE/uMfSiwgfT6s/image_thumb%25255B106%25255D.png?imgmax=800
image
dbhome,oraenv and coreenv are already exist as part of grid infrastructure installation . Those files are identical.

image: http://lh6.ggpht.com/-E_xGLhTAPvw/UOUQ4T1f2kI/AAAAAAAACwU/WEdKa9Y91kY/image_thumb%25255B108%25255D.png?imgmax=800
image

image: http://lh5.ggpht.com/-bxNFpmjDGYQ/UOUQ5bvi98I/AAAAAAAACwk/WeT-gBalDRE/image_thumb%25255B110%25255D.png?imgmax=800
image

Create Oracle Database with DBCA.


image: http://lh4.ggpht.com/-rsZxfR7vuh0/UOUQ5xSj__I/AAAAAAAACw0/ebADUTmkZUI/image_thumb%25255B112%25255D.png?imgmax=800
image

image: http://lh3.ggpht.com/-ZXEEcATrT4g/UOUQ67XOd1I/AAAAAAAACxE/LvOK9IRSYkE/image_thumb%25255B116%25255D.png?imgmax=800
image

image: http://lh3.ggpht.com/-PyMpBDegE7s/UOUQ8IY1PaI/AAAAAAAACxU/GNJ20FXnzo0/image_thumb%25255B118%25255D.png?imgmax=800
image

image: http://lh5.ggpht.com/-MIGpV0XhcRI/UOUQ8wsUu9I/AAAAAAAACxk/QaE_HLgt2gc/image_thumb%25255B120%25255D.png?imgmax=800
image

image: http://lh6.ggpht.com/--PZnkfiwoBQ/UOUQ-TjPcNI/AAAAAAAACx0/DUp3QoUsr_Y/image_thumb%25255B122%25255D.png?imgmax=800
image

image: http://lh4.ggpht.com/-LnaIp-z0RSY/UOUQ_JV6YzI/AAAAAAAACyE/HPPqsnqWBvk/image_thumb%25255B124%25255D.png?imgmax=800
image

image: http://lh4.ggpht.com/-JsdxzY35Sms/UOURAFj2EpI/AAAAAAAACyU/neQ-Acc2vF4/image_thumb%25255B137%25255D.png?imgmax=800
image

image: http://lh5.ggpht.com/-j2_Mamlmzyw/UOURA-GIASI/AAAAAAAACyk/NSel_0iIgx4/image_thumb%25255B138%25255D.png?imgmax=800
image
Need to provide the ASMNMP password.

image: http://lh5.ggpht.com/-tVhXqeqbHRI/UOURBZWiv_I/AAAAAAAACy0/SBmoOaSM7n0/image_thumb%25255B139%25255D.png?imgmax=800
image

image: http://lh5.ggpht.com/-le19oVTq1EY/UOURCfM-AFI/AAAAAAAACzE/HlaB_kverdk/image_thumb%25255B140%25255D.png?imgmax=800
image

image: http://lh3.ggpht.com/-wHVOlTjAuiw/UOURDAeZHGI/AAAAAAAACzU/cuUDA6m0LyM/image_thumb%25255B141%25255D.png?imgmax=800
image

image: http://lh4.ggpht.com/-TBb0Pcmkve0/UOURDzkPs6I/AAAAAAAACzk/CpkX80cxhgg/image_thumb%25255B142%25255D.png?imgmax=800
image

image: http://lh5.ggpht.com/-Fg3j6wD_WPg/UOUREq-ZhdI/AAAAAAAACz0/quVc82cPa54/image_thumb%25255B144%25255D.png?imgmax=800
image

image: http://lh6.ggpht.com/-qvq6lKdVnug/UOURF2YJd9I/AAAAAAAAC0E/Ed9T2ey9B3I/image_thumb%25255B143%25255D.png?imgmax=800
image

image: http://lh4.ggpht.com/-7TFQ7PyLxjU/UOURGnNYSFI/AAAAAAAAC0U/uVixMBPWfo4/image_thumb%25255B145%25255D.png?imgmax=800
image

image: http://lh5.ggpht.com/-Iwax8i5rxvE/UOURHcUyZzI/AAAAAAAAC0k/ymB5C5Uo7II/image_thumb%25255B146%25255D.png?imgmax=800
image

image: http://lh3.ggpht.com/-mdseY_uk5C0/UOURIabQLfI/AAAAAAAAC00/QW76YD9Go7Q/image_thumb%25255B147%25255D.png?imgmax=800
image

image: http://lh6.ggpht.com/-AtY1KU5A8pU/UOUYPcQjElI/AAAAAAAAC3A/WYqmAtqgFoE/image_thumb%25255B149%25255D.png?imgmax=800
image

No comments: