标签:网卡模式 login 名称 操作系统 虚拟 vmnet sel bho lag
实验环境虚拟机
VMware? Workstation 15 Pro
操作系统
RHEL 6.5
存储
虚拟机模拟共享存储
Oracle软件
p13390677_112040_Linux-x86-64_1of7.zip
p13390677_112040_Linux-x86-64_2of7.zip
p13390677_112040_Linux-x86-64_3of7.zip
实验拓扑
服务器 | 连接状态 | 网卡名称 | IP | 网卡模式 |
---|---|---|---|---|
rac1 | VMnet8 | eth0 | 192.168.1.101 | 公有 |
rac1 | VMnet1 | eth1 | 10.10.0.1 | 私有 |
rac2 | VMnet8 | eth0 | 192.168.1.102 | 公有 |
rac2 | VMnet1 | eth1 | 10.10.0.2 | 私有 |
修改主机名
[root@hostname ~]vim /etc/sysconfig/network
NETWORKING=yes HOSTNAME=rac1
修改hosts文件
[root@rac1 ~]# vim /etc/hosts
192.168.1.101 rac1 192.168.1.102 rac2 10.10.0.1 rac1-priv 10.10.0.2 rac2-priv 192.168.1.103 rac1-vip 192.168.1.104 rac2-vip 192.168.1.110 rac-scan
禁用防火墙
[root@rac1 ~]# service iptables stop
[root@rac1 ~]# chkconfig iptables off
禁用selinux
[root@rac1 ~]# vim /etc/selinux/config
SELINUX=disabled
修改/etc/pam.d/login
[root@rac1 ~]# vim /etc/pam.d/login
session required pam_limits.so
修改/etc/profile
[root@rac1 ~]# vim /etc/profile
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
修改/etc/csh.login
[root@rac1 ~]# vim /etc/csh.login
if ( /$USER == "oracle" || /$USER == "grid" ) then limit maxproc 16384 limit descriptors 65536 endif
修改/etc/sysctl.conf
[root@rac1 ~]# vim /etc/sysctl.conf
fs.aio-max-nr = 1048576 fs.file-max = 6815744 #kernel.shmall = 2097152 #kernel.shmmax =42950000000 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@rac1 ~]# sysctl -p
为用户设置资源限制
[root@rac1 ~]# vim /etc/security/limits.conf
grid soft nproc 2047 grid hard nproc 16384 grid soft nofile 1024 grid hard nofile 65536 oracle soft nproc 2047 oracle hard nproc 16384 oracle soft nofile 1024 oracle hard nofile 65536
配置CTSS
使用集群时间同步服务在集群中提供同步服务,需要卸载网络时间协议 (NTP) 及其配置。要停用 NTP 服务,必须停止当前的 ntpd 服务,从初始化序列中禁用该服务,并删除 ntp.conf 文件。
[root@rac1 ~]# /sbin/service ntpd stop
[root@rac1 ~]# chkconfig ntpd off
[root@rac1 ~]# mv /etc/ntp.conf /etc/ntp.conf.original
[root@rac1 ~]# rm /var/run/ntpd.pid
创建用户和组
[root@rac1 ~]# groupadd -g 501 oinstall
[root@rac1 ~]# groupadd -g 502 asmadmin
[root@rac1 ~]# groupadd -g 503 asmdba
[root@rac1 ~]# groupadd -g 504 asmoper
[root@rac1 ~]# groupadd -g 505 dba
[root@rac1 ~]# groupadd -g 506 oper
[root@rac1 ~]# useradd -m -u 1100 -g oinstall -G asmadmin,asmdba,asmoper -d /home/grid -s /bin/bash -c "Grid Infrastructure Owner" grid
[root@rac1 ~]# useradd -m -u 1101 -g oinstall -G dba,oper,asmdba -d /home/oracle -s /bin/bash -c "Oracle Software Owner" oracle
创建目录及授权
[root@rac1 ~]# mkdir -p /u01/app/grid
[root@rac1 ~]# mkdir -p /u01/app/11.2.0/grid
[root@rac1 ~]# chown -R grid:oinstall /u01
[root@rac1 ~]# mkdir -p /u01/app/oracle
[root@rac1 ~]# chown oracle:oinstall /u01/app/oracle
[root@rac1 ~]# chmod -R 775 /u01
修改用户环境变量
grid用户
[grid@rac1 ~]$ vim .bash_profile
ORACLE_SID=+ASM1; export ORACLE_SID #ORACLE_SID=+ASM2; export ORACLE_SID JAVA_HOME=/usr/local/java; export JAVA_HOME ORACLE_BASE=/u01/app/grid; export ORACLE_BASE ORACLE_HOME=/u01/app/11.2.0/grid; export ORACLE_HOME ORACLE_PATH=/u01/app/oracle/common/oracle/sql; export ORACLE_PATH ORACLE_TERM=xterm; export ORACLE_TERM NLS_DATE_FORMAT="DD-MON-YYYY HH24:MI:SS"; export NLS_DATE_FORMAT TNS_ADMIN=$ORACLE_HOME/network/admin; export TNS_ADMIN ORA_NLS11=$ORACLE_HOME/nls/data; export ORA_NLS11 NLS_LANG=AMERICAN_AMERICA.ZHS16GBK; export NLS_LANG PATH=.:${JAVA_HOME}/bin:${PATH}:$HOME/bin:$ORACLE_HOME/bin PATH=${PATH}:/usr/bin:/bin:/usr/bin/X11:/usr/local/bin PATH=${PATH}:/u01/app/common/oracle/bin export PATH LD_LIBRARY_PATH=$ORACLE_HOME/lib LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:$ORACLE_HOME/oracm/lib LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:/lib:/usr/lib:/usr/local/lib export LD_LIBRARY_PATH CLASSPATH=$ORACLE_HOME/JRE CLASSPATH=${CLASSPATH}:$ORACLE_HOME/jlib CLASSPATH=${CLASSPATH}:$ORACLE_HOME/rdbms/jlib CLASSPATH=${CLASSPATH}:$ORACLE_HOME/network/jlib export CLASSPATH THREADS_FLAG=native; export THREADS_FLAG export TEMP=/tmp export TMPDIR=/tmp umask 022
oracle用户
[oracle@rac1 ~]$ vim .bash_profile
ORACLE_SID=racdb1; export ORACLE_SID #ORACLE_SID=racdb2; export ORACLE_SID ORACLE_UNQNAME=racdb; export ORACLE_UNQNAME JAVA_HOME=/usr/local/java; export JAVA_HOME ORACLE_BASE=/u01/app/oracle; export ORACLE_BASE ORACLE_HOME=$ORACLE_BASE/product/11.2.0/dbhome_1; export ORACLE_HOME ORACLE_PATH=/u01/app/common/oracle/sql; export ORACLE_PATH ORACLE_TERM=xterm; export ORACLE_TERM NLS_DATE_FORMAT="DD-MON-YYYY HH24:MI:SS"; export NLS_DATE_FORMAT TNS_ADMIN=$ORACLE_HOME/network/admin; export TNS_ADMIN ORA_NLS11=$ORACLE_HOME/nls/data; export ORA_NLS11 NLS_LANG=AMERICAN_AMERICA.ZHS16GBK; export NLS_LANG PATH=.:${JAVA_HOME}/bin:${PATH}:$HOME/bin:$ORACLE_HOME/bin PATH=${PATH}:/usr/bin:/bin:/usr/bin/X11:/usr/local/bin PATH=${PATH}:/u01/app/common/oracle/bin export PATH LD_LIBRARY_PATH=$ORACLE_HOME/lib LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:$ORACLE_HOME/oracm/lib LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:/lib:/usr/lib:/usr/local/lib export LD_LIBRARY_PATH CLASSPATH=$ORACLE_HOME/JRE CLASSPATH=${CLASSPATH}:$ORACLE_HOME/jlib CLASSPATH=${CLASSPATH}:$ORACLE_HOME/rdbms/jlib CLASSPATH=${CLASSPATH}:$ORACLE_HOME/network/jlib export CLASSPATH THREADS_FLAG=native; export THREADS_FLAG export TEMP=/tmp export TMPDIR=/tmp umask 022
RHEL6.5安装Oracle RAC 11g(一,系统配置)
标签:网卡模式 login 名称 操作系统 虚拟 vmnet sel bho lag
原文地址:https://blog.51cto.com/yuanshuai/2477482