基于CentOS与VmwareStation10搭建Oracle11G RAC 64集群环境:2.搭建环境-2.7. 配置资源与参数

时间:2023-03-08 15:43:04
基于CentOS与VmwareStation10搭建Oracle11G RAC 64集群环境:2.搭建环境-2.7.	配置资源与参数

2.7.配置资源与参数

2.7.1. 修改主机名称

[root@linuxrac1 ~]# cd /etc/sysconfig

[root@linuxrac1 sysconfig]# vi network

NETWORKING=yes

NETWORKING_IPV6=no

HOSTNAME=linuxrac1

[root@linuxrac1 sysconfig]#

[root@linuxrac2 ~]# cd /etc/sysconfig

[root@linuxrac2 sysconfig]# vi network

NETWORKING=yes

NETWORKING_IPV6=no

HOSTNAME=linuxrac2

[root@linuxrac2 sysconfig]#

2.7.2. 配置用户,组,目录和权

  创建组之前要确认一下/etc/group及/etc/passwd下的组及用户,确保每个节点上的uid及gid 一致 (当然也可以建组的时候加入id号,groupadd -g 501 oinstall) .

  根据规划:

  Grid Infrastructure操作系统用户grid , 主组为oinstall辅助组为asmadmin, asmdba, asmoper

  Oracle RAC操作系统用户oracle , 主组为oinstall , 辅助组为dba, oper , asmdba

[root@localhost /]# groupadd oinstall

[root@localhost /]# groupadd dba

[root@localhost /]# groupadd oper

[root@localhost /]# groupadd asmadmin

[root@localhost /]# groupadd asmdba

[root@localhost /]# groupadd asmoper

[root@localhost /]# useradd -g oinstall -G dba,asmdba,asmadmin,asmoper grid

[root@localhost /]# useradd -g oinstall -G dba,oper,asmdba oracle

[root@localhost /]# echo -n oracle|passwd --stdin grid

Changing password for user grid.

passwd: all authentication tokens updated successfully.

[root@localhost /]# echo -n oracle|passwd --stdin oracle

Changing password for user oracle.

passwd: all authentication tokens updated successfully.

[root@localhost /]# mkdir -p /u01/app/11.2.0/grid

[root@localhost /]# mkdir -p /u01/app/grid

[root@localhost /]# mkdir -p /u01/app/oracle

[root@localhost /]# chown grid:oinstall /u01/app/11.2.0/grid

[root@localhost /]# chown grid:oinstall /u01/app/grid

[root@localhost /]# chown -R oracle:oinstall /u01/app/oracle

[root@localhost /]# chmod -R 777 /u01/

[root@localhost /]# chown -R grid:oinstall /u01

2.7.3.修改系统内核参数/etc/sysctl.conf

[root@linuxrac1 etc]# vi sysctl.conf

# add parameter for oracle

fs.aio-max-nr = 1048576

fs.file-max = 6815744

kernel.shmall = 2097152

kernel.shmmax = 1073741824

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

2.7.4.配置/etc/security/limits.conf

[root@linuxrac1]# vi /etc/security/limits.conf

#add parameter for oracle and grid

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

2.7.5. 配置/etc/profile

[root@linuxrac1 etc]# vi profile

# for oracle

if [ \$USER = "oracle" ] || [ \$USER = "grid" ];then

if [ \$SHELL = "/bin/ksh" ];then

ulimit -p 16384 ulimit -n 65536

else

ulimit -u 16384 -n 65536

fi

umask 022

fi

#############################

export PATH=$PATH:/u01/app/11.2.0/grid/bin

#color of grep

alias grep='grep --color=auto'

基于CentOS与VmwareStation10搭建Oracle11G RAC 64集群环境所有链接:

1.资源准备
http://www.cnblogs.com/HondaHsu/p/4046352.html

2.搭建环境-2.1创建虚拟机
http://www.cnblogs.com/HondaHsu/p/4046378.html

2.搭建环境-2.2安装操作系统CentOS5.4
http://www.cnblogs.com/HondaHsu/p/4046384.html

2.搭建环境-2.3配置共享磁盘
http://www.cnblogs.com/HondaHsu/p/4046389.html

2.搭建环境-2.4. 安装JDK
http://www.cnblogs.com/HondaHsu/p/4046430.html

2.搭建环境-2.5. 配置网络
http://www.cnblogs.com/HondaHsu/p/4046443.html

2.搭建环境-2.6. 安装Oracle所依赖的必要包
http://www.cnblogs.com/HondaHsu/p/4054216.html

2.搭建环境-2.7. 配置资源与参数
http://www.cnblogs.com/HondaHsu/p/4054238.html

2.搭建环境-2.8. 配置用户环境
http://www.cnblogs.com/HondaHsu/p/4054259.html

2.搭建环境-2.9. 配置用户等效性(可选项)
http://www.cnblogs.com/HondaHsu/p/4054277.html

2.搭建环境-2.10.配置用户NTF服务
http://www.cnblogs.com/HondaHsu/p/4054333.html

3.安装Oracle RAC-3.1.安装并配置ASM驱动
http://www.cnblogs.com/HondaHsu/p/4054367.html

3.安装Oracle RAC-3.2.安装 cvuqdisk 软件包
http://www.cnblogs.com/HondaHsu/p/4054395.html

3.安装Oracle RAC-3.3.安装前检查
http://www.cnblogs.com/HondaHsu/p/4054481.html

3.安装Oracle RAC-3.4.安装Grid Infrastructure
http://www.cnblogs.com/HondaHsu/p/4054518.html

3.安装Oracle RAC-3.5.安装oracle11gr2 database 软件与创建数据库
http://www.cnblogs.com/HondaHsu/p/4054586.html

3.安装Oracle RAC-3.6.集群管理命令
http://www.cnblogs.com/HondaHsu/p/4054635.html

4.安装Oracle RAC FAQ-4.1.系统界面报错Gnome
http://www.cnblogs.com/HondaHsu/p/4046314.html

4.安装Oracle RAC FAQ-4.2.Oracleasm Createdisk ASM磁盘失败:Instantiating disk: failed
http://www.cnblogs.com/HondaHsu/p/4046248.html

4.安装Oracle RAC FAQ-4.3.Oracle 集群节点间连通失败
http://www.cnblogs.com/HondaHsu/p/4046263.html

4.安装Oracle RAC FAQ-4.4.无法图形化安装Grid Infrastructure
http://www.cnblogs.com/HondaHsu/p/4046273.html

4.安装Oracle RAC FAQ-4.5.安装Grid,创建ASM磁盘组空间不足
http://www.cnblogs.com/HondaHsu/p/4046285.html

4.安装Oracle RAC FAQ-4.6.重新配置与缷载11R2 Grid Infrastructure
http://www.cnblogs.com/HondaHsu/p/4046300.html

4.安装Oracle RAC FAQ-4.7.Oracle 11G R2 RAC修改public网络IP
http://www.cnblogs.com/HondaHsu/p/4054953.html