RHEL5 Oracle 11G R2 RAC 靜默安裝 (一) GI安裝前 準備
一,安裝前準備
1, 組和使用者建立 (每個節點)
2, 使用者目錄建立(每個節點)
3,網路配置 (每個節點)
/etc/hosts
4, 核心引數配置 (每個節點)
vi /etc/sysctl.conf
5, 使用者限制 (每個節點)
[root@huy1 ~]# vi /etc/security/limits.conf (追加)
[root@huy1 ~]# vi /etc/pam.d/login 追加
vi /etc/profile 追加
6, 關閉 NTP 各個節點
[root@huy1 ~]# chkconfig ntpd off
7, grid使用者 SSH 相互信任 在節點一操作, passphrase都設定為空
測試 (兩邊節點)
7, grid使用者 SSH 相互信任 在節點一操作, passphrase都設定為空
測試 (兩邊節點)
8,安裝asmlib (兩邊節點)
9, 配置asm磁碟 (節點一上)
另一個節點
10, 用 yum 安裝 各個節點
[root@huy1 yum.repos.d]# yum install -y sysstat*
[root@huy1 yum.repos.d]# yum install -y libaio*
[root@huy1 yum.repos.d]# yum install -y unixODBC*
準備工作完成
1, 組和使用者建立 (每個節點)
點選(此處)摺疊或開啟
-
[root@huy1 ~]# groupadd -g 200 oinstall
-
[root@huy1 ~]# groupadd -g 201 dba
-
[root@huy1 ~]# groupadd -g 202 oper
-
[root@huy1 ~]# groupadd -g 204 asmoper
-
[root@huy1 ~]# groupadd -g 205 asmdba
-
[root@huy1 ~]# useradd -u 200 -g oinstall -G dba,asmdba,oper oracle
- [root@huy1 ~]# useradd -u 201 -g oinstall -G asmadmin,asmdba,asmoper,oper,dba grid
- [root@huy1 ~]# passwd grid
-
[root@huy1 ~]# passwd oracle
點選(此處)摺疊或開啟
-
[root@huy1 ~]# mkdir -p /u01/app/oraInventory
-
[root@huy1 ~]# chown -R grid:oinstall /u01/app/oraInventory/
-
[root@huy1 ~]# chmod -R 775 /u01/app/oraInventory/
-
[root@huy1 ~]# mkdir -p /u01/11.2.0/grid
-
[root@huy1 ~]# chown -R grid:oinstall /u01/11.2.0/grid/
-
[root@huy1 ~]# chmod -R 775 /u01/11.2.0/grid/
-
[root@huy1 ~]# mkdir -p /u01/app/oraInventory/
-
[root@huy1 ~]# mkdir -p /u01/app/oracle
-
[root@huy1 ~]# mkdir -p /u01/app/oracle/cfgtoollogs
-
[root@huy1 ~]# mkdir -p /u01/app/oracle/product/11.2.0/db_1
-
[root@huy1 ~]# chown -R oracle:oinstall /u01/app/oracle
- [root@huy1 ~]# chmod -R 775 /u01/app/oracle
/etc/hosts
點選(此處)摺疊或開啟
-
127.0.0.1 localhost.localdomain localhost
-
192.168.56.101 huy1
-
192.168.56.102 huy2
-
192.168.56.201 huy1-vip
-
192.168.56.202 huy2-vip
-
192.168.56.100 huy-scan
-
10.10.10.101 huy1-priv
- 10.10.10.102 huy2-priv
vi /etc/sysctl.conf
點選(此處)摺疊或開啟
-
kernel.shmall = 268435456
-
fs.aio-max-nr = 1048576
-
fs.file-max = 6815744
-
kernel.shmall = 2097152
-
kernel.shmmax = 536870912
-
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@huy1 ~]# vi /etc/security/limits.conf (追加)
點選(此處)摺疊或開啟
-
oracle soft nproc 2047
-
oracle hard nproc 16384
-
oracle soft nofile 1024
-
oracle hard nofile 65536
-
oracle soft stack 10240
-
grid soft nproc 2047
-
grid hard nproc 16384
-
grid soft nofile 1024
-
grid hard nofile 65536
- grid soft stack 10240
點選(此處)摺疊或開啟
- session required /lib/security/pam_limits.so
-
if [ $USER = "oracle" ]||[ $USER = "grid" ]; then
if [ $SHELL = "/bin/ksh" ]; then
ulimit -p 16384
ulimit -n 65536
else
ulimit -u 16384 -n 65536
fi
fi
[root@huy1 ~]# chkconfig ntpd off
7, grid使用者 SSH 相互信任 在節點一操作, passphrase都設定為空
點選(此處)摺疊或開啟
-
[grid@huy1 ~]$ ssh-keygen -t dsa
-
[grid@huy1 ~]$ ssh-keygen -t rsa
-
[grid@huy1 ~]$ ssh huy2 ssh-keygen -t dsa
-
[grid@huy1 ~]$ ssh huy2 ssh-keygen -t rsa
-
[grid@huy1 ~]$ cat .ssh/id_dsa.pub >> .ssh/authorized_keys
-
[grid@huy1 ~]$ cat .ssh/id_rsa.pub >> .ssh/authorized_keys
- [grid@huy1 ~]$ ssh huy2 cat .ssh/id_dsa.pub >> .ssh/authorized_keys
- grid@huy2's password:
- [grid@huy1 ~]$ ssh huy2 cat .ssh/id_rsa.pub >> .ssh/authorized_keys
- grid@huy2's password:
- [grid@huy1 ~]$ scp .ssh/authorized_keys huy2:~/.ssh/
-
grid@huy2's password:
點選(此處)摺疊或開啟
-
[grid@huy1 ~]$ ssh huy1 date
-
[grid@huy1 ~]$ ssh huy2 date
-
[grid@huy1 ~]$ ssh huy1-priv date
- [grid@huy1 ~]$ ssh huy2-priv date
7, grid使用者 SSH 相互信任 在節點一操作, passphrase都設定為空
點選(此處)摺疊或開啟
-
[oracle@huy1 ~]$ ssh-keygen -t dsa
-
[oracle@huy1 ~]$ ssh-keygen -t rsa
-
[oracle@huy1 ~]$ ssh huy2 ssh-keygen -t dsa
-
[oracle@huy1 ~]$ ssh huy2 ssh-keygen -t rsa
-
[oracle@huy1 ~]$ cat .ssh/id_dsa.pub >> .ssh/authorized_keys
-
[oracle@huy1 ~]$ cat .ssh/id_rsa.pub >> .ssh/authorized_keys
-
[oracle@huy1 ~]$ ssh huy2 cat .ssh/id_dsa.pub >> .ssh/authorized_keys
-
oracle@huy2\'s password:
-
[oracle@huy1 ~]$ ssh huy2 cat .ssh/id_rsa.pub >> .ssh/authorized_keys
-
oracle@huy2\'s password:
-
[oracle@huy1 ~]$ scp .ssh/authorized_keys huy2:~/.ssh/
- oracle@huy2's password:
點選(此處)摺疊或開啟
-
[oracle@huy1 ~]$ ssh huy1 date
-
[oracle@huy1 ~]$ ssh huy2 date
-
[oracle@huy1 ~]$ ssh huy1-priv date
- [oracle@huy1 ~]$ ssh huy2-priv date
點選(此處)摺疊或開啟
-
[root@huy1 asm]# ls
-
oracleasm-2.6.18-194.el5-2.0.5-1.el5.i686.rpm oracleasmlib-2.0.4-1.el5.i386.rpm oracleasm-support-2.1.3-1.el5.i386.rpm
- [root@huy1 asm]# rpm -ivh *.rpm
9, 配置asm磁碟 (節點一上)
點選(此處)摺疊或開啟
-
[root@huy1 soft]# service oracleasm configure
-
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 []: grid
-
Default group to own the driver interface []: asmadmin
-
Start Oracle ASM library driver on boot (y/n) [n]: y
-
Scan for Oracle ASM disks on boot (y/n) [y]: y
-
Writing Oracle ASM library driver configuration: done
-
Initializing the Oracle ASMLib driver: [ OK ]
-
Scanning the system for Oracle ASMLib disks: [ OK ]
-
[root@huy1 soft]# service oracleasm createdisk OCR_VOTE1 /dev/sdb1
-
Marking disk \"OCR_VOTE1\" as an ASM disk: [ OK ]
-
[root@huy1 soft]# service oracleasm createdisk OCR_VOTE2 /dev/sdb2
-
Marking disk \"OCR_VOTE2\" as an ASM disk: [ OK ]
-
[root@huy1 soft]# service oracleasm createdisk OCR_VOTE3 /dev/sdb3
-
Marking disk \"OCR_VOTE3\" as an ASM disk: [ OK ]
-
[root@huy1 soft]# service oracleasm createdisk DATA1 /dev/sdb5
-
Marking disk \"DATA1\" as an ASM disk: [ OK ]
-
[root@huy1 soft]# service oracleasm createdisk DATA2 /dev/sdb6
-
Marking disk \"DATA2\" as an ASM disk: [ OK ]
-
[root@huy1 soft]# service oracleasm createdisk RCY1 /dev/sdb7
-
Marking disk \"RCY1\" as an ASM disk: [ OK ]
-
[root@huy1 soft]# service oracleasm createdisk RCY2 /dev/sdb8
-
Marking disk \"RCY2\" as an ASM disk: [ OK ]
-
[root@huy1 soft]# service oracleasm listdisks
-
DATA1
-
DATA2
-
OCR_VOTE1
-
OCR_VOTE2
-
OCR_VOTE3
-
RCY1
-
RCY2
-
[root@huy1 soft]# ll /dev/oracleasm/disks
-
total 0
-
brw-rw---- 1 grid asmadmin 8, 21 Sep 9 18:01 DATA1
-
brw-rw---- 1 grid asmadmin 8, 22 Sep 9 18:01 DATA2
-
brw-rw---- 1 grid asmadmin 8, 17 Sep 9 18:00 OCR_VOTE1
-
brw-rw---- 1 grid asmadmin 8, 18 Sep 9 18:00 OCR_VOTE2
-
brw-rw---- 1 grid asmadmin 8, 19 Sep 9 18:00 OCR_VOTE3
-
brw-rw---- 1 grid asmadmin 8, 23 Sep 9 18:01 RCY1
- brw-rw---- 1 grid asmadmin 8, 24 Sep 9 18:01 RCY2
另一個節點
點選(此處)摺疊或開啟
-
[root@node2 asm]# service oracleasm configure
-
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 []: grid
-
Default group to own the driver interface []: asmadmin
-
Start Oracle ASM library driver on boot (y/n) [n]: y
-
Scan for Oracle ASM disks on boot (y/n) [y]: y
-
Writing Oracle ASM library driver configuration: done
-
Initializing the Oracle ASMLib driver: [ OK ]
-
Scanning the system for Oracle ASMLib disks: [ OK ]
-
[root@node2 asm]# service oracleasm listdisks
-
DATA1
-
DATA2
-
OCR_VOTE1
-
OCR_VOTE2
-
OCR_VOTE3
-
RCY1
-
RCY2
-
[root@node2 asm]# ll /dev/oracleasm/disks
-
total 0
-
brw-rw---- 1 grid asmadmin 8, 21 Sep 9 18:01 DATA1
-
brw-rw---- 1 grid asmadmin 8, 22 Sep 9 18:01 DATA2
-
brw-rw---- 1 grid asmadmin 8, 17 Sep 9 18:01 OCR_VOTE1
-
brw-rw---- 1 grid asmadmin 8, 18 Sep 9 18:01 OCR_VOTE2
-
brw-rw---- 1 grid asmadmin 8, 19 Sep 9 18:01 OCR_VOTE3
-
brw-rw---- 1 grid asmadmin 8, 23 Sep 9 18:01 RCY1
- brw-rw---- 1 grid asmadmin 8, 24 Sep 9 18:01 RCY2
[root@huy1 yum.repos.d]# yum install -y sysstat*
[root@huy1 yum.repos.d]# yum install -y libaio*
[root@huy1 yum.repos.d]# yum install -y unixODBC*
準備工作完成
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/12238525/viewspace-1288988/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- RHEL5 Oracle 11G R2 RAC 靜默安裝 (二)GI靜默安裝Oracle
- RHEL5 Oracle 11G R2 RAC 靜默安裝 (三) rdbms安裝 dbca 建庫Oracle
- oracle 11g rac 靜默解除安裝Oracle
- RAC安裝之一 安裝前準備
- oracle 11g RAC 安裝前準備指令碼Oracle指令碼
- rac靜默安裝
- Oracle 11G RAC叢集安裝(1)——安裝前的準備Oracle
- Oracle 11g 靜默安裝Oracle
- oracle 11G RAC 安裝前準備和注意事項Oracle
- Oracle 11g Database靜默安裝OracleDatabase
- Linux 安裝11g RAC 前準備工作Linux
- Oracle 靜默安裝Oracle
- Oracle靜默安裝Oracle
- CentOS 7.5靜默安裝Oracle 11gCentOSOracle
- oracle 11g R2安裝RACOracle
- CentOS 6.6系統上命令列靜默安裝安裝Oracle 11G R2(11.2.0.3)CentOS命令列Oracle
- 靜默安裝ORACLE(文件)Oracle
- 11.2.0.3 RAC 靜默安裝第一彈
- 靜默方式安裝oracle 11g 完整攻略Oracle
- ORACLE 11G 靜默安裝soft db listenerOracle
- Linux下Oracle 11g靜默安裝LinuxOracle
- 靜默安裝Oracle資料庫11gOracle資料庫
- oracle靜默安裝raw裝置Oracle
- 靜默方式安裝、升級oracle(一): 安裝oracle軟體Oracle
- Oracle 10g RAC 靜默安裝過程Oracle 10g
- Android靜默安裝和靜默解除安裝Android
- 【DBCA -SILENT】靜默安裝之rac資料庫安裝資料庫
- 靜默安裝oracle時報錯Oracle
- ORACLE 11.2.0.4靜默安裝Oracle
- 靜默安裝oracle軟體Oracle
- Oracle靜默安裝(單機)Oracle
- 靜默安裝ORACLE 軟體Oracle
- Oracle靜默安裝說明Oracle
- 非圖形化靜默安裝oracle 11gOracle
- Oracle Linux 7.1 靜默安裝Oracle 18c RACOracleLinux
- OEL6下靜默安裝Oracle 11g,靜默配置監聽Oracle
- Oracle 12cR1 RAC 在VMware Workstation上安裝(下)—靜默安裝Oracle
- Openfiler+RAC的安裝之六--安裝前的準備工作