标签:style io color os ar for sp strong 文件
配置11gR2 RAC需要安装Oracle Grid Infrastructure软件、Oracle数据库软件,其中Grid软件等同于Oracle 10g的Clusterware集群件。Oracle建议以不同的用户分别安装Grid Infrastructure软件、Oracle数据库软件,我们这里以grid用户安装Grid Infrastructure,oracle用户安装Oracle数据库软件。并且grid、oracle用户需要属于不同的用户组。在配置RAC时,还要求这两个用户在RAC的不同节点上uid、gid要一致。用户、组的对应信息见下表:
Group Name |
Group ID |
Group Info |
Oracle User(1100) |
Grid User(1101) |
oinstall |
1000 |
Inventory Group |
Y |
Y |
dba |
1300 |
OSDBA Group |
Y |
|
oper |
1301 |
OSOPER Group |
Y |
|
asmadmin |
1200 |
OSASM |
|
Y |
asmdba |
1201 |
OSDBA for ASM |
Y |
Y |
asmoper |
1202 |
OSOPER for ASM |
|
Y |
groupadd -g 1000 oinstall
groupadd -g 1300 dba
|
测试
[root@node1 shell]# id grid uid=1100(grid) gid=1000(oinstall) groups=1000(oinstall),1200(asmadmin),1201(asmdba),1202(asmoper) [root@node1 shell]# id oracle uid=1101(oracle) gid=1000(oinstall) groups=1000(oinstall),1201(asmdba),1300(dba),1301(oper) [root@node1 shell]# |
说明:在节点node2上执行该脚本时,需要将grid用户环境变量ORACLE_SID修改为+ASM2,oracle用户环境变量ORACLE_SID修改为devdb2,ORACLE_HOSTNAME环境变量修改为node2.localdomain
关于grid、oracle用户的环境变量配置信息,见下述表格。
Environment Variable |
Grid User |
Oracle User |
ORACLE_BASE |
/u01/app/grid |
/u01/app/oracle |
ORACLE_HOME |
/u01/app/11.2.0/grid |
/u01/app/oracle/product/11.2.0/db_1 |
ORACLE_SID [node1] |
+ASM1 |
devdb1 |
ORACLE_SID [node2] |
+ASM2 |
devdb2 |
mkdir -p /u01/app/grid [root@node1 shell]# cd /u01/app/ [root@node1 app]# ll total 12 drwxrwxr-x 3 grid oinstall 4096 Apr 24 10:06 11.2.0 drwxrwxr-x 2 grid oinstall 4096 Apr 24 10:06 grid drwxrwxr-x 2 oracle oinstall 4096 Apr 24 10:06 oracle [root@node1 app]# |
cp /etc/security/limits.conf /etc/security/limits.conf.bak echo "oracle soft nproc 2047" >>/etc/security/limits.conf echo "oracle hard nproc 16384" >>/etc/security/limits.conf echo "oracle soft nofile 1024" >>/etc/security/limits.conf echo "oracle hard nofile 65536" >>/etc/security/limits.conf echo "grid soft nproc 2047" >>/etc/security/limits.conf echo "grid hard nproc 16384" >>/etc/security/limits.conf echo "grid soft nofile 1024" >>/etc/security/limits.conf echo "grid hard nofile 65536" >>/etc/security/limits.conf |
cp /etc/pam.d/login /etc/pam.d/login.bak |
cp /etc/profile /etc/profile.bak |
cp /etc/sysctl.conf /etc/sysctl.conf.bak |
[root@node1 ~]# service ntpd status ntpd is stopped [root@node1 ~]# chkconfig ntpd off [root@node1 ~]# cat /etc/ntp ntp/ ntp.conf [root@node1 ~]# cp /etc/ntp.conf /etc/ntp.conf.bak [root@node1 ~]# rm -rf /etc/ntp.conf [root@node1 ~]# |
我们已经在node1完成基本准备配置工作,在node2上重复上述1到7中准备工作,以完成节点2的准备工作。
Linux下搭建Oracle11g RAC(3)----创建用户及配置相关文件
标签:style io color os ar for sp strong 文件
原文地址:http://www.cnblogs.com/SUN-PH/p/4056267.html