最近在11gr2 RAC方式的资料,看到了CLONE方式安装grid与rdbms。原来只用过clone方式方案rdbms。下面就开始我们的测试吧。安装过程中运行的命令在最后一篇blog中可以下载。
OS:RHEL 5.6 OS:11.2.0.2
1.节点1系统配置
- Last login: Tue Oct 9 21:44:11 2012
- 1.1 修改参数
- 因为各个环境不一样,参数的值可以也不一样,根据各人自己的环境来配置参数,特别是shmmax,vm.nr_hugepages等参数。
- [root@11rac4 ~]# echo "fs.aio-max-nr = 1048576
- > fs.file-max = 6815744
- > kernel.shmall = 2097152
- > kernel.shmmax = 11036870912
- > kernel.shmmni = 4096
- > 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">>/etc/sysctl.conf
- [root@11rac4 ~]# tail -12 /etc/sysctl.conf
- kernel.shmall = 4294967296
- fs.aio-max-nr = 1048576
- fs.file-max = 6815744
- kernel.shmall = 2097152
- kernel.shmmax = 11036870912
- kernel.shmmni = 4096
- 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
- 1.2 配置limit,注意在11gr2中要对grid与oracle用户配置
- [root@11rac4 ~]# echo "oracle soft nproc 2047
- > oracle hard nproc 16384
- > oracle soft nofile 1024
- > oracle hard nofile 65536
- > grid soft nproc 2047
- > grid hard nproc 16384
- > grid soft nofile 1024
- > grid hard nofile 65536">>/etc/security/limits.conf
- [root@11rac4 ~]# tail -8 /etc/security/limits.conf
- oracle soft nproc 2047
- oracle hard nproc 16384
- oracle soft nofile 1024
- oracle hard nofile 65536
- grid soft nproc 2047
- grid hard nproc 16384
- grid soft nofile 1024
- grid hard nofile 65536
- [root@11rac4 ~]# echo "session required pam_limits.so">>/etc/pam.d/login
- [root@11rac4 ~]# tail -1 /etc/pam.d/login
- session required pam_limits.so
- [root@11rac4 ~]#
- 1.3 创建grid与oracle用户
- [root@11rac4 ~]# /usr/sbin/groupadd -g 501 oinstall
- /usr/sbin/groupadd -g 502 dba
- [root@11rac4 ~]# /usr/sbin/groupadd -g 502 dba
- /usr/sbin/groupadd -g 504 asmadmin
- [root@11rac4 ~]# /usr/sbin/groupadd -g 504 asmadmin
- [root@11rac4 ~]# /usr/sbin/groupadd -g 506 asmdba
- [root@11rac4 ~]# /usr/sbin/groupadd -g 507 asmoper
- /usr/sbin/useradd -u 501 -g oinstall -G asmadmin,asmdba,asmoper grid
- [root@11rac4 ~]# /usr/sbin/useradd -u 501 -g oinstall -G asmadmin,asmdba,asmoper grid
- echo "oracle"|passwd oracle --stdin
- [root@11rac4 ~]# /usr/sbin/useradd -u 502 -g oinstall -G dba,asmdba oracle
- 修改密码
- [root@11rac4 ~]# echo "oracle"|passwd oracle --stdin
- Changing password for user oracle.
- passwd: all authentication tokens updated successfully.
- [root@11rac4 ~]# echo "oracle"|passwd grid --stdin
- Changing password for user grid.
- passwd: all authentication tokens updated successfully.
- [root@11rac4 ~]#
- 1.4 修改hosts文件
- [root@11rac4 ~]# echo "192.168.100.50 11rac4
- > 192.168.100.51 11rac5
- >
- > 192.168.100.55 11rac4-vip
- > 192.168.100.56 11rac5-vip
- >
- > 192.168.101.50 11rac4-priv
- > 192.168.101.51 11rac5-priv
- >
- >
- > 192.168.100.59 scan">>/etc/hosts
- [root@11rac4 ~]# tail -14 /etc/hosts
- # that require network functionality will fail.
- 127.0.0.1 localhost.localdomain localhost
- ::1 localhost6.localdomain6 localhost6
- 192.168.100.50 11rac4
- 192.168.100.51 11rac5
- 192.168.100.55 11rac4-vip
- 192.168.100.56 11rac5-vip
- 192.168.101.50 11rac4-priv
- 192.168.101.51 11rac5-priv
- 192.168.100.59 scan
- [root@11rac4 ~]#
- 1.5 配置yum本地资源库
- [root@11rac4 ~]# mount /dev/cdrom /media
- echo "
- mount: block device /dev/cdrom is write-protected, mounting read-only
- [RHEL5.6]
- [root@11rac4 ~]# echo "
- > [RHEL5.6]
- > name = Enterprise Linux 5.5 DVD
- > baseurl=file:///media/Server/
- > gpgcheck=0
- > enabled=1">/etc/yum.repos.d/public-yum-el5.repo
- [root@11rac4 ~]# tail -5 /etc/yum.repos.d/public-yum-el5.repo
- [RHEL5.6]
- name = Enterprise Linux 5.5 DVD
- baseurl=file:///media/Server/
- gpgcheck=0
- enabled=1
- 1.6 安装相关软件
- [root@11rac4 ~]# rpm -q --qf '%{NAME}-%{VERSION}-%{RELEASE} (%{ARCH})\n' binutils \
- > compat-libstdc++-33 \
- > elfutils-libelf \
- > elfutils-libelf-devel \
- > gcc \
- > gcc-c++ \
- > glibc \
- > glibc-common \
- > glibc-devel \
- > glibc-headers \
- > ksh \
- > libaio \
- > libaio-devel \
- > libgcc \
- > libstdc++ \
- > libstdc++-devel \
- > make \
- > sysstat \
- > unixODBC \
- > unixODBC-devel \
- > libaio-devel
- yum install sysstat unixODBC unixODBC-devel libaio-develbinutils-2.17.50.0.6-14.el5 (x86_64)
- compat-libstdc++-33-3.2.3-61 (x86_64)
- compat-libstdc++-33-3.2.3-61 (i386)
- elfutils-libelf-0.137-3.el5 (x86_64)
- elfutils-libelf-0.137-3.el5 (i386)
- elfutils-libelf-devel-0.137-3.el5 (x86_64)
- gcc-4.1.2-50.el5 (x86_64)
- gcc-c++-4.1.2-50.el5 (x86_64)
- glibc-2.5-58 (x86_64)
- glibc-2.5-58 (i686)
- glibc-common-2.5-58 (x86_64)
- glibc-devel-2.5-58 (x86_64)
- glibc-devel-2.5-58 (i386)
- glibc-headers-2.5-58 (x86_64)
- ksh-20100202-1.el5_5.1 (x86_64)
- libaio-0.3.106-5 (x86_64)
- libaio-0.3.106-5 (i386)
- package libaio-devel is not installed
- libgcc-4.1.2-50.el5 (x86_64)
- libgcc-4.1.2-50.el5 (i386)
- libstdc++-4.1.2-50.el5 (x86_64)
- libstdc++-4.1.2-50.el5 (i386)
- libstdc++-devel-4.1.2-50.el5 (x86_64)
- make-3.81-3.el5 (x86_64)
- package sysstat is not installed
- package unixODBC is not installed
- package unixODBC-devel is not installed
- package libaio-devel is not installed
- [root@11rac4 ~]# yum install sysstat unixODBC unixODBC-devel libaio-devel
- Loaded plugins: rhnplugin, security
- This system is not registered with RHN.
- RHN support will be disabled.
- RHEL5.6 | 1.3 kB 00:00
- RHEL5.6/primary | 905 kB 00:00
- RHEL5.6 3229/3229
- Setting up Install Process
- Resolving Dependencies
- --> Running transaction check
- ---> Package libaio-devel.i386 0:0.3.106-5 set to be updated
- ---> Package libaio-devel.x86_64 0:0.3.106-5 set to be updated
- ---> Package sysstat.x86_64 0:7.0.2-3.el5_5.1 set to be updated
- ---> Package unixODBC.i386 0:2.2.11-7.1 set to be updated
- ---> Package unixODBC.x86_64 0:2.2.11-7.1 set to be updated
- ---> Package unixODBC-devel.i386 0:2.2.11-7.1 set to be updated
- ---> Package unixODBC-devel.x86_64 0:2.2.11-7.1 set to be updated
- --> Finished Dependency Resolution
- Dependencies Resolved
- ========================================================================================================================================================================
- Package Arch Version Repository Size
- ========================================================================================================================================================================
- Installing:
- libaio-devel i386 0.3.106-5 RHEL5.6 12 k
- libaio-devel x86_64 0.3.106-5 RHEL5.6 11 k
- sysstat x86_64 7.0.2-3.el5_5.1 RHEL5.6 174 k
- unixODBC i386 2.2.11-7.1 RHEL5.6 832 k
- unixODBC x86_64 2.2.11-7.1 RHEL5.6 837 k
- unixODBC-devel i386 2.2.11-7.1 RHEL5.6 737 k
- unixODBC-devel x86_64 2.2.11-7.1 RHEL5.6 793 k
- Transaction Summary
- ========================================================================================================================================================================
- Install 7 Package(s)
- Upgrade 0 Package(s)
- Total download size: 3.3 M
- Is this ok [y/N]: y
- Downloading Packages:
- ------------------------------------------------------------------------------------------------------------------------------------------------------------------------
- Total 197 MB/s | 3.3 MB 00:00
- Running rpm_check_debug
- Running Transaction Test
- Finished Transaction Test
- Transaction Test Succeeded
- Running Transaction
- Installing : unixODBC 1/7
- Installing : unixODBC 2/7
- Installing : unixODBC-devel 3/7
- Installing : unixODBC-devel 4/7
- Installing : libaio-devel 5/7
- Installing : sysstat 6/7
- Installing : libaio-devel 7/7
- Installed:
- libaio-devel.i386 0:0.3.106-5 libaio-devel.x86_64 0:0.3.106-5 sysstat.x86_64 0:7.0.2-3.el5_5.1 unixODBC.i386 0:2.2.11-7.1 unixODBC.x86_64 0:2.2.11-7.1
- unixODBC-devel.i386 0:2.2.11-7.1 unixODBC-devel.x86_64 0:2.2.11-7.1
- Complete!
- 1.8 配置udev,这里我使用的是udev,个人觉得更简单。也可以使用asmlib来实现。
- [root@11rac4 ~]# for i in b c d ;
- > do
- > echo "KERNEL==\"sd*\", BUS==\"scsi\", PROGRAM==\"/sbin/scsi_id -g -u -s %p\", RESULT==\"`scsi_id -g -u -s /block/sd$i`\", NAME=\"asm-disk$i\", OWNER=\"grid\", GROUP=\"asmadmin\", MODE=\"0660\"" >> /etc/udev/rules.d/99-oracle-asmdevices.rules
- > done
- [root@11rac4 ~]# cat /etc/udev/rules.d/99-oracle-asmdevices.rules
- scsi_id -g -u -s /block/sd
- KERNEL=="sd*", BUS=="scsi", PROGRAM=="/sbin/scsi_id -g -u -s %p", RESULT=="SATA_VBOX_HARDDISK_VB92e83562-d3aa4e2c_", NAME="asm-diskb", OWNER="grid", GROUP="asmadmin", MODE="0660"
- KERNEL=="sd*", BUS=="scsi", PROGRAM=="/sbin/scsi_id -g -u -s %p", RESULT=="SATA_VBOX_HARDDISK_VBdc07bc6d-ef3fd4d5_", NAME="asm-diskc", OWNER="grid", GROUP="asmadmin", MODE="0660"
- KERNEL=="sd*", BUS=="scsi", PROGRAM=="/sbin/scsi_id -g -u -s %p", RESULT=="", NAME="asm-diskd", OWNER="grid", GROUP="asmadmin", MODE="0660"
- [root@11rac4 ~]# start_udev
- Starting udev: ls -l /dev/asm*[ OK ]
- [root@11rac4 ~]# ls -l /dev/asm*
- brw-rw---- 1 grid asmadmin 8, 16 Oct 9 22:02 /dev/asm-diskb
- brw-rw---- 1 grid asmadmin 8, 32 Oct 9 22:02 /dev/asm-diskc
- 1.9 配置环境变量
- [root@11rac4 ~]# echo "
- > ORACLE_BASE=/u01/app/grid; export ORACLE_BASE
- > ORACLE_HOME=/u01/app/11.2.0/grid; export ORACLE_HOME
- > export PATH=\$ORACLE_HOME/bin:\$PATH
- > export TNS_ADMIN=\$ORACLE_HOME/network/admin
- > export ORACLE_SID=+ASM1
- > export DISPLAY=192.168.100.1:0.0
- > stty erase ^h
- > set -o vi
- > export SHELL_HOME=\$HOME/rs
- > export PATH=\$PATH:\$SHELL_HOME/bin:\$SHELL_HOME/dbmonitor:\$SHELL_HOME/asm:\$SHELL_HOME/rman:\$SHELL_HOME/tune:\$SHELL_HOME/dump:\$SHELL_HOME/event:\$SHELL_HOME/dg">>/home/grid/.bash_profile
- [root@11rac4 ~]# echo "
- > ORACLE_BASE=/u01/app/oracle; export ORACLE_BASE
- > ORACLE_HOME=\$ORACLE_BASE/product/11.2.0/db_1; export ORACLE_HOME
- > export PATH=\$ORACLE_HOME/bin:\$PATH
- > export TNS_ADMIN=\$ORACLE_HOME/network/admin
- > export ORACLE_SID=power1
- > export DISPLAY=192.168.100.1:0.0
- > stty erase ^h
- > set -o vi
- > export SHELL_HOME=\$HOME/rs
- > export PATH=\$PATH:\$SHELL_HOME/bin:\$SHELL_HOME/dbmonitor:\$SHELL_HOME/asm:\$SHELL_HOME/rman:\$SHELL_HOME/tune:\$SHELL_HOME/dump:\$SHELL_HOME/event:\$SHELL_HOME/dg">>/home/oracle/.bash_profile
- [root@11rac4 ~]# echo "
- > ORACLE_HOME=/u01/app/oracle/product/11.2.0/db_1; export ORACLE_HOME
- > export GRID_HOME=/u01/app/11.2.0/grid
- > export PATH=\$ORACLE_HOME/bin:\$PATH:\$GRID_HOME\bin
- > export TNS_ADMIN=\$ORACLE_HOME/network/admin
- > export ORACLE_SID=power2
- > export DISPLAY=192.168.100.1:0.0
- > stty erase ^h
- > set -o vi">>~/.bash_profile
- [root@11rac4 ~]# tail -7 ~/.bash_profile
- export GRID_HOME=/u01/app/11.2.0/grid
- export PATH=$ORACLE_HOME/bin:$PATH:$GRID_HOME\bin
- export TNS_ADMIN=$ORACLE_HOME/network/admin
- export ORACLE_SID=power2
- export DISPLAY=192.168.100.1:0.0
- stty erase ^h
- set -o vi
- 1.10 创建安装目录
- [root@11rac4 ~]# mkdir /u01
- [root@11rac4 ~]# chmod 777 /u01
2.节点2系统配置
- 配置内容跟1节点差不多
- Last login: Tue Oct 9 21:43:05 2012
- [root@11rac5 ~]# echo "fs.aio-max-nr = 1048576
- > fs.file-max = 6815744
- > kernel.shmall = 2097152
- > kernel.shmmax = 11036870912
- > kernel.shmmni = 4096
- > 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">>/etc/sysctl.conf
- [root@11rac5 ~]# tail -12 /etc/sysctl.conf
- kernel.shmall = 4294967296
- fs.aio-max-nr = 1048576
- fs.file-max = 6815744
- kernel.shmall = 2097152
- kernel.shmmax = 11036870912
- kernel.shmmni = 4096
- 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
- [root@11rac5 ~]# echo "oracle soft nproc 2047
- > oracle hard nproc 16384
- > oracle soft nofile 1024
- > oracle hard nofile 65536
- > grid soft nproc 2047
- > grid hard nproc 16384
- > grid soft nofile 1024
- > grid hard nofile 65536">>/etc/security/limits.conf
- [root@11rac5 ~]# tail -8 /etc/security/limits.conf
- oracle soft nproc 2047
- oracle hard nproc 16384
- oracle soft nofile 1024
- oracle hard nofile 65536
- grid soft nproc 2047
- grid hard nproc 16384
- grid soft nofile 1024
- grid hard nofile 65536
- [root@11rac5 ~]# echo "session required pam_limits.so">>/etc/pam.d/login
- [root@11rac5 ~]# tail -1 /etc/pam.d/login
- session required pam_limits.so
- [root@11rac5 ~]#
- [root@11rac5 ~]# /usr/sbin/groupadd -g 501 oinstall
- /usr/sbin/groupadd -g 502 dba
- [root@11rac5 ~]# /usr/sbin/groupadd -g 502 dba
- /usr/sbin/groupadd -g 504 asmadmin
- [root@11rac5 ~]# /usr/sbin/groupadd -g 504 asmadmin
- /usr/sbin/groupadd -g 506 asmdba
- [root@11rac5 ~]# /usr/sbin/groupadd -g 506 asmdba
- [root@11rac5 ~]# /usr/sbin/groupadd -g 507 asmoper
- [root@11rac5 ~]# /usr/sbin/useradd -u 501 -g oinstall -G asmadmin,asmdba,asmoper grid
- /usr/sbin/useradd -u 502 -g oinstall -G dba,asmdba oracle
- [root@11rac5 ~]# /usr/sbin/useradd -u 502 -g oinstall -G dba,asmdba oracle
- [root@11rac5 ~]# echo "oracle"|passwd oracle --stdin
- Changing password for user oracle.
- passwd: all authentication tokens updated successfully.
- [root@11rac5 ~]# echo "oracle"|passwd grid --stdin
- Changing password for user grid.
- passwd: all authentication tokens updated successfully.
- [root@11rac5 ~]#
- [root@11rac5 ~]# echo "192.168.100.50 11rac4
- > 192.168.100.51 11rac5
- >
- > 192.168.100.55 11rac4-vip
- > 192.168.100.56 11rac5-vip
- >
- > 192.168.101.50 11rac4-priv
- > 192.168.101.51 11rac5-priv
- >
- >
- > 192.168.100.59 scan">>/etc/hosts
- [root@11rac5 ~]# tail -14 /etc/hosts
- # that require network functionality will fail.
- 127.0.0.1 localhost.localdomain localhost
- ::1 localhost6.localdomain6 localhost6
- 192.168.100.50 11rac4
- 192.168.100.51 11rac5
- 192.168.100.55 11rac4-vip
- 192.168.100.56 11rac5-vip
- 192.168.101.50 11rac4-priv
- 192.168.101.51 11rac5-priv
- 192.168.100.59 scan
- [root@11rac5 ~]#
- [root@11rac5 ~]# mount /dev/cdrom /media
- echo "
- mount: block device /dev/cdrom is write-protected, mounting read-only
- [RHEL5.6]
- [root@11rac5 ~]# echo "
- > [RHEL5.6]
- > name = Enterprise Linux 5.5 DVD
- > baseurl=file:///media/Server/
- > gpgcheck=0
- > enabled=1">/etc/yum.repos.d/public-yum-el5.repo
- [root@11rac5 ~]# tail -5 /etc/yum.repos.d/public-yum-el5.repo
- [RHEL5.6]
- name = Enterprise Linux 5.5 DVD
- baseurl=file:///media/Server/
- gpgcheck=0
- enabled=1
- [root@11rac5 ~]# rpm -q --qf '%{NAME}-%{VERSION}-%{RELEASE} (%{ARCH})\n' binutils \
- > compat-libstdc++-33 \
- > elfutils-libelf \
- > elfutils-libelf-devel \
- > gcc \
- > gcc-c++ \
- > glibc \
- > glibc-common \
- > glibc-devel \
- > glibc-headers \
- > ksh \
- > libaio \
- > libaio-devel \
- > libgcc \
- > libstdc++ \
- > libstdc++-devel \
- > make \
- > sysstat \
- > unixODBC \
- > unixODBC-devel \
- > libaio-devel
- yum install sysstat unixODBC unixODBC-devel libaio-develbinutils-2.17.50.0.6-14.el5 (x86_64)
- compat-libstdc++-33-3.2.3-61 (x86_64)
- compat-libstdc++-33-3.2.3-61 (i386)
- elfutils-libelf-0.137-3.el5 (x86_64)
- elfutils-libelf-0.137-3.el5 (i386)
- elfutils-libelf-devel-0.137-3.el5 (x86_64)
- gcc-4.1.2-50.el5 (x86_64)
- gcc-c++-4.1.2-50.el5 (x86_64)
- glibc-2.5-58 (x86_64)
- glibc-2.5-58 (i686)
- glibc-common-2.5-58 (x86_64)
- glibc-devel-2.5-58 (x86_64)
- glibc-devel-2.5-58 (i386)
- glibc-headers-2.5-58 (x86_64)
- ksh-20100202-1.el5_5.1 (x86_64)
- libaio-0.3.106-5 (x86_64)
- libaio-0.3.106-5 (i386)
- package libaio-devel is not installed
- libgcc-4.1.2-50.el5 (x86_64)
- libgcc-4.1.2-50.el5 (i386)
- libstdc++-4.1.2-50.el5 (x86_64)
- libstdc++-4.1.2-50.el5 (i386)
- libstdc++-devel-4.1.2-50.el5 (x86_64)
- make-3.81-3.el5 (x86_64)
- package sysstat is not installed
- package unixODBC is not installed
- package unixODBC-devel is not installed
- package libaio-devel is not installed
- [root@11rac5 ~]# yum install sysstat unixODBC unixODBC-devel libaio-devel
- Loaded plugins: rhnplugin, security
- This system is not registered with RHN.
- RHN support will be disabled.
- RHEL5.6 | 1.3 kB 00:00
- RHEL5.6/primary | 905 kB 00:00
- RHEL5.6 3229/3229
- Setting up Install Process
- Resolving Dependencies
- --> Running transaction check
- ---> Package libaio-devel.i386 0:0.3.106-5 set to be updated
- ---> Package libaio-devel.x86_64 0:0.3.106-5 set to be updated
- ---> Package sysstat.x86_64 0:7.0.2-3.el5_5.1 set to be updated
- ---> Package unixODBC.i386 0:2.2.11-7.1 set to be updated
- ---> Package unixODBC.x86_64 0:2.2.11-7.1 set to be updated
- ---> Package unixODBC-devel.i386 0:2.2.11-7.1 set to be updated
- ---> Package unixODBC-devel.x86_64 0:2.2.11-7.1 set to be updated
- --> Finished Dependency Resolution
- Dependencies Resolved
- ========================================================================================================================================================================
- Package Arch Version Repository Size
- ========================================================================================================================================================================
- Installing:
- libaio-devel i386 0.3.106-5 RHEL5.6 12 k
- libaio-devel x86_64 0.3.106-5 RHEL5.6 11 k
- sysstat x86_64 7.0.2-3.el5_5.1 RHEL5.6 174 k
- unixODBC i386 2.2.11-7.1 RHEL5.6 832 k
- unixODBC x86_64 2.2.11-7.1 RHEL5.6 837 k
- unixODBC-devel i386 2.2.11-7.1 RHEL5.6 737 k
- unixODBC-devel x86_64 2.2.11-7.1 RHEL5.6 793 k
- Transaction Summary
- ========================================================================================================================================================================
- Install 7 Package(s)
- Upgrade 0 Package(s)
- Total download size: 3.3 M
- Is this ok [y/N]: y
- Downloading Packages:
- ------------------------------------------------------------------------------------------------------------------------------------------------------------------------
- Total 194 MB/s | 3.3 MB 00:00
- Running rpm_check_debug
- Running Transaction Test
- Finished Transaction Test
- Transaction Test Succeeded
- Running Transaction
- Installing : unixODBC 1/7
- Installing : unixODBC 2/7
- Installing : unixODBC-devel 3/7
- Installing : unixODBC-devel 4/7
- Installing : libaio-devel 5/7
- Installing : sysstat 6/7
- Installing : libaio-devel 7/7
- Installed:
- libaio-devel.i386 0:0.3.106-5 libaio-devel.x86_64 0:0.3.106-5 sysstat.x86_64 0:7.0.2-3.el5_5.1 unixODBC.i386 0:2.2.11-7.1 unixODBC.x86_64 0:2.2.11-7.1
- unixODBC-devel.i386 0:2.2.11-7.1 unixODBC-devel.x86_64 0:2.2.11-7.1
- Complete!
- [root@11rac5 ~]# for i in b c d ;
- > do
- > echo "KERNEL==\"sd*\", BUS==\"scsi\", PROGRAM==\"/sbin/scsi_id -g -u -s %p\", RESULT==\"`scsi_id -g -u -s /block/sd$i`\", NAME=\"asm-disk$i\", OWNER=\"grid\", GROUP=\"asmadmin\", MODE=\"0660\"" >> /etc/udev/rules.d/99-oracle-asmdevices.rules
- > done
- [root@11rac5 ~]# cat /etc/udev/rules.d/99-oracle-asmdevices.rules
- KERNEL=="sd*", BUS=="scsi", PROGRAM=="/sbin/scsi_id -g -u -s %p", RESULT=="SATA_VBOX_HARDDISK_VB92e83562-d3aa4e2c_", NAME="asm-diskb", OWNER="grid", GROUP="asmadmin", MODE="0660"
- KERNEL=="sd*", BUS=="scsi", PROGRAM=="/sbin/scsi_id -g -u -s %p", RESULT=="SATA_VBOX_HARDDISK_VBdc07bc6d-ef3fd4d5_", NAME="asm-diskc", OWNER="grid", GROUP="asmadmin", MODE="0660"
- KERNEL=="sd*", BUS=="scsi", PROGRAM=="/sbin/scsi_id -g -u -s %p", RESULT=="", NAME="asm-diskd", OWNER="grid", GROUP="asmadmin", MODE="0660"
- [root@11rac5 ~]# start_udev
- Starting udev: ls -l /dev/asm*
- [ OK ]
- [root@11rac5 ~]# ls -l /dev/asm*
- brw-rw---- 1 grid asmadmin 8, 16 Oct 9 22:02 /dev/asm-diskb
- brw-rw---- 1 grid asmadmin 8, 32 Oct 9 22:02 /dev/asm-diskc
- [root@11rac5 ~]# echo "ORACLE_BASE=/u01/app/grid; export ORACLE_BASE
- > ORACLE_HOME=/u01/app/11.2.0/grid; export ORACLE_HOME
- > export PATH=\$ORACLE_HOME/bin:\$PATH
- > export TNS_ADMIN=\$ORACLE_HOME/network/admin
- > export ORACLE_SID=+ASM2
- > export DISPLAY=192.168.100.1:0.0
- > stty erase ^h
- > set -o vi
- > export SHELL_HOME=\$HOME/rs
- > export PATH=\$PATH:\$SHELL_HOME/bin:\$SHELL_HOME/dbmonitor:\$SHELL_HOME/asm:\$SHELL_HOME/rman:\$SHELL_HOME/tune:\$SHELL_HOME/dump:\$SHELL_HOME/event:\$SHELL_HOME/dg">>/home/grid/.bash_profile
- [root@11rac5 ~]#
- [root@11rac5 ~]# echo "
- > ORACLE_BASE=/u01/app/oracle; export ORACLE_BASE
- > ORACLE_HOME=\$ORACLE_BASE/product/11.2.0/db_1; export ORACLE_HOME
- > export PATH=\$ORACLE_HOME/bin:\$PATH
- > export TNS_ADMIN=\$ORACLE_HOME/network/admin
- > export ORACLE_SID=power2
- > alias bdump='cd /u01/app/oracle/diag/rdbms/orcl/ORCL/trace'
- > export DISPLAY=192.168.100.1:0.0
- > stty erase ^h
- > set -o vi
- > export SHELL_HOME=\$HOME/rs
- > export PATH=\$PATH:\$SHELL_HOME/bin:\$SHELL_HOME/dbmonitor:\$SHELL_HOME/asm:\$SHELL_HOME/rman:\$SHELL_HOME/tune:\$SHELL_HOME/dump:\$SHELL_HOME/event:\$SHELL_HOME/dg">>/home/oracle/.bash_profile
- [root@11rac5 ~]#
- [root@11rac5 ~]#
- [root@11rac5 ~]#
- [root@11rac5 ~]#
- [root@11rac5 ~]# echo "
- > ORACLE_HOME=/u01/app/oracle/product/11.2.0/db_1; export ORACLE_HOME
- > export GRID_HOME=/u01/app/11.2.0/grid
- > export PATH=\$ORACLE_HOME/bin:\$PATH:\$GRID_HOME/bin
- > export TNS_ADMIN=\$ORACLE_HOME/network/admin
- > export ORACLE_SID=power2
- > export DISPLAY=192.168.100.1:0.0
- > stty erase ^h
- > set -o vi">>~/.bash_profile
- [root@11rac5 ~]# tail -7 ~/.bash_profile
- export GRID_HOME=/u01/app/11.2.0/grid
- export PATH=$ORACLE_HOME/bin:$PATH:$GRID_HOME\bin
- export TNS_ADMIN=$ORACLE_HOME/network/admin
- export ORACLE_SID=power2
- export DISPLAY=192.168.100.1:0.0
- stty erase ^h
- set -o vi
- [root@11rac5 ~]# mkdir /u01
- [root@11rac5 ~]# chmod 777 /u01
3,重启主机
注意重启主机最好是一台一台的重启,主机1重启后再重启主机2.
TAR包CLONE方式 安装11GR2 RAC数据库
http://luoping.blog.51cto.com/534596/1024788
TAR包CLONE方式 安装11GR2 RAC数据库 (gril软件安装)
http://luoping.blog.51cto.com/534596/1024795
TAR包CLONE方式 安装11GR2 RAC数据库 (gril软件root.sh)
http://luoping.blog.51cto.com/534596/1024804
TAR包CLONE方式 安装11GR2 RAC数据库 (rdbms部分)
http://luoping.blog.51cto.com/534596/1024811