12c 搭建rac 环境
- IP规划
节点 public ip vip private ip scan ip
host01 13.2.71.200 13.2.71.202 13.2.43.200 13.2.71.204
host02 13.2.71.201 13.2.71.203 13.2.43.201
- 系统安装rh7.5
语言选 英文+中文简体
Software GUI,peformance tools,development tools,security tools,system administration tools
分区时,选standard partition,
swap 内存的两倍,最大16G,
boot 2G,
/分区 剩下所有
- 虚拟机注意的点
快照对共享存储不起作用,可以对文件所在的文件夹直接复制
- 环境配置
- hostnamectl set-hostname host01
- 同步阿里云的时间 (时间同步和域名服务器可以不配置)
chmod +x /etc/rc.d/rc.local
cat >> /etc/rc.d/rc.local <<EOF
/usr/sbin/ntpdate ntp.aliyum.com
EOF
ntpdate ntp.aliyun.com
- 关闭防火墙
systemctl stop firewalld
systemctl disable firewalld
- 关闭selinux
vi /etc/selinux/config
SELINUX=disabled
- 配置/etc/hosts
#
13.2.71.200 host01
13.2.71.201 host02
#每个节点又有一个虚拟IP,节点故障则漂移到另外正常的节点上
13.2.71.202 host01-vip
13.2.71.203 host02-vip
#用于心跳网络,保证数据同步
13.2.43.200 host01-priv
13.2.43.201 host02-priv
#客户端可以通过 SCAN 特性负载均衡地连接到 RAC数据库
13.2.71.204 rac-scan
- 配置 vim /etc/security/limits.conf
grid soft nofile 1024
grid hard nofile 65536
grid soft nproc 2047
grid hard nproc 16384
grid soft stack 10240
grid hard stack 32768
oracle soft nofile 1024
oracle hard nofile 65536
oracle soft nproc 2047
oracle hard nproc 16384
oracle soft stack 10240
oracle hard stack 32768
oracle soft memlock 3145728 (12C的新参数)
oracle hard memlock 3145728
- /dev/shm
内存的80%
vim /etc/fstab
tmpfs /dev/shm tmpfs defaults,size=6G 0 0
mount –o remount /dev/shm
- 内核参数 两条注释的改下,其他的不变
/etc/sysctl.d/ 99-sysctl.conf
fs.aio-max-nr = 1048576
fs.file-max = 6815744
kernel.shmall = 1572864 #shmmax/4096
kernel.shmmax = 6442450944 #物理内存的80%
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 = 1048576
sysctl –system(立即生效)
sysctl –a|grep shmmax
sysctl –a|grep shmall
- 用户配置:
groupadd oinstall
groupadd dba
groupadd oper
<
最低0.47元/天 解锁文章
589

被折叠的 条评论
为什么被折叠?



