OracleLinux6.4+OracleRAC11.2.0.3安装文档
更新时间:2023-04-27 13:03:01 阅读量: 实用文档 文档下载
环境说明
操作系统:OracleLinux6.4 X86_64位
Oracle版本:11.2.0.3
挂载linux安装操作系统镜像
挂载linux安装文件到/mnt下
[root@localhost ~]# mount /opt/soft/Oracle Linux_V37084-01_Oracle_6.4X64.iso /mnt -0 loop 检查挂载
[root@localhost ~]# df -h
文件系统容量已用可用已用%% 挂载点
/dev/mapper/VolGroup-lv_root
22G 6.7G 14G 34% /
tmpfs 4.0G 176K 4.0G 1% /dev/shm
/dev/sda1 485M 55M 405M 12% /boot
/opt/soft/Oracle Linux_V37084-01_Oracle_6.4X64.iso
3.5G 3.5G 0 100% /mnt
配置yum
修改yum配置文件
[root@localhost ~]# cat /etc/yum.repos.d/public-yum-ol6.repo
[oracle]
name=Unbreakable Enterprise Kernel for Oracle Linux $releasever ($basearch)
baseurl=file:/mnt
gpgcheck=0
enabled=1
清除yum原有文件列表
[root@localhost ~]#yum clean
重新生成yum文件列表
[root@localhost ~]#yum list
安装VNCserver
安装VNC
[root@localhost ~]#yum install tiger*
启动VNC服务
[root@localhost ~]#vncserver:1
修改VNC配置文件
[root@localhost ~]# cat /root/.vnc/xstartup
#!/bin/sh
xterm -geometry 80x24+10+10 -ls title "$VNCDESKTOP Desktop" &
gnome-session gnome
twm &
启动VNCserver
[root@localhost ~]vmcserver –kill :1
[root@localhost ~]#vncserver :1
修改系统参数
修改hosts文件
[root@localhost ~]# cat /etc/hosts
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4 ::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
#RAC_D1_131
10.8.1.131 RAC1.localdomain RAC1
10.8.1.132 RAC1-vip.localdomain RAC1-vip
192.168.1.31 RAC1-priv.localdomain RAC1-priv
#RAC_D1_133
10.8.1.133 RAC2.localdomain RAC2
10.8.1.134 RAC2-vip.localdomain RAC2-vip
192.168.1.33 RAC2-priv.localdomain RAC2-priv
#scan-ip
10.8.1.137 scan-cluster.localdomain scan-cluster
修改network文件
[root@localhost ~]# cat /etc/sysconfig/network
NETWORKING=yes
HOSTNAME=RAC2
配置系统限制
[root@localhost ~]# cat /etc/security/limits.d/90-nproc.conf
# Default limit for number of user's processes to prevent
# accidental fork bombs.
# See rhbz #432903 for reasoning.
* - nproc 16384
root soft nproc unlimited
关闭selinux
[root@localhost ~]# cat /etc/sysconfig/selinux
# This file controls the state of SELinux on the system.
# SELINUX= can take one of these three values:
# enforcing - SELinux security policy is enforced.
# permissive - SELinux prints warnings instead of enforcing. # disabled - No SELinux policy is loaded.
SELINUX=disabled
# SELINUXTYPE= can take one of these two values:
# targeted - Targeted processes are protected,
# mls - Multi Level Security protection. SELINUXTYPE=targeted
关闭防火墙
[root@localhost ~]# service iptables stop
iptables:清除防火墙规则:[确定]
iptables:将链设置为政策ACCEPT:filter [确定] iptables:正在卸载模块:[确定]
[root@localhost ~]# chkconfig iptables off
关闭时钟
[root@localhost ~]# service ntpd stop
关闭ntpd:[失败]
[root@localhost ~]# chkconfig ntpd off
[root@localhost ~]# mv /etc/ntp.conf /etc/ntp.conf.orig [root@localhost ~]# rm /var/run/ntpd.pid
rm: 无法删除"/var/run/ntpd.pid": 没有那个文件或目录
修改安全限制
Add the below at the end of file “/etc/security/limits.conf”#Grid
grid soft nofile 1024
grid hard nofile 65536
grid soft nproc 2047
grid hard nproc 16384
grid soft stack 10240
grid hard stack 32768
设置本地域名解析
[root@localhost ~]# cat /etc/resolv.conf
search localdomain
[root@localhost ~]# service dnsmasq restart
Starting dnsmasq: [确定]
[root@localhost ~]# chkconfig dnsmasq on
添加用户
创建集群用户组
[root@localhost ~]# groupadd -g 1000 oinstall
[root@localhost ~]# groupadd -g 1010 dba
[root@localhost ~]# groupadd -g 1020 asmadmin
[root@localhost ~]# groupadd -g 1030 asmdba
创建grid用户
[root@localhost ~]# useradd -u 1100 -g oinstall -G asmadmin,asmdba grid [root@localhost ~]# mkdir -p /opt/u01/app/11.2.0/grid
[root@localhost ~]# mkdir -p /opt/u01/app/grid
[root@localhost ~]# chown -R grid:oinstall /opt/u01
[root@localhost ~]# passwd grid
创建oracle用户
[root@localhost ~]# useradd -u 1101 -g oinstall -G dba,asmdba oracle [root@localhost ~]# mkdir -p /opt/u01/app/oracle/product/11.2.0 [root@localhost ~]# chown -R oracle:oinstall /opt/u01/app/oracle
[root@localhost ~]# chmod -R 775 /opt/u01
[root@localhost ~]# passwd oracle
设置环境变量
设置oracle环境变量
[root@localhost ~]# su oracle
[oracle@localhost ~]$ vi .bash_profile
RAC1节点
#RAC1_oracle
export ORACLE_HOME=/opt/u01/app/oracle/product/11.2.0
export ORACLE_SID=RAC1
export ORACLE_UNQNAME=RAC
export PATH=$ORACLE_HOME/bin:$PATH
export ORACLE_BASE=/opt/u01/app/oracle
export LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib
export CLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib
RAC2节点
#RAC2_oracle
export ORACLE_HOME=/opt/u01/app/oracle/product/11.2.0
export ORACLE_SID=RAC2
export ORACLE_UNQNAME=RAC
export PATH=$ORACLE_HOME/bin:$PATH
export ORACLE_BASE=/opt/u01/app/oracle
export LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib
export CLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib 设置grid环境变量
[root@localhost ~]# su - grid
[grid@localhost ~]$ vi .bash_profile
RAC1节点
#RAC1_Grid
export ORACLE_HOME=/opt/u01/app/11.2.0/grid
export ORACLE_SID=+ASM1
export PATH=$ORACLE_HOME/bin:$PATH
export ORACLE_BASE=/opt/u01/app/grid
export LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib
export CLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib
RAC2节点
#RAC2_Grid
export ORACLE_HOME=/opt/u01/app/11.2.0/grid
export ORACLE_SID=+ASM2
export PATH=$ORACLE_HOME/bin:$PATH
export ORACLE_BASE=/opt/u01/app/grid
export LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib
export CLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib 配置ASM
配置ASM
[root@localhost ~]# oracleasm configure -i
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
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
ASM初始化
[root@localhost ~]# oracleasm init
Creating /dev/oracleasm mount point: /dev/oracleasm
Loading module "oracleasm": oracleasm
Configuring "oracleasm" to use device physical block size
Mounting ASMlib driver filesystem: /dev/oracleasm
格式化磁盘
[root@localhost ~]# fdisk /dev/sdb
Device contains neither a valid DOS partition table, nor Sun, SGI or OSF disklabel
Building a new DOS disklabel with disk identifier 0x6c2f6c1f.
Changes will remain in memory only, until you decide to write them.
After that, of course, the previous content won't be recoverable.
Warning: invalid flag 0x0000 of partition table 4 will be corrected by w(rite)
WARNING: DOS-compatible mode is deprecated. It's strongly recommended to switch off the mode (command 'c') and change display units to
sectors (command 'u').
Command (m for help): n
Command action
e extended
p primary partition (1-4)
p
Partition number (1-4): 1
First cylinder (1-1305, default 1):
Using default value 1
Last cylinder, +cylinders or +size{K,M,G} (1-1305, default 1305):
Using default value 1305
Command (m for help): w
The partition table has been altered!
Calling ioctl() to re-read partition table.
Syncing disks.
重启系统
[root@localhost ~]# reboot
创建ASM磁盘
[root@rac1 ~]# oracleasm createdisk ASMDISK1 /dev/sdb1
Writing disk header: done
Instantiating disk: done
[root@rac1 ~]# oracleasm createdisk ASMDISK2 /dev/sdc1
Writing disk header: done
Instantiating disk: done
[root@rac1 ~]# oracleasm createdisk ASMDISK3 /dev/sdd1
Writing disk header: done
Instantiating disk: done
[root@rac1 ~]# oracleasm createdisk ASMDISK4 /dev/sde1
Writing disk header: done
Instantiating disk: done
检测ASM磁盘
[root@rac1 ~]# oracleasm scandisks
Reloading disk partitions: done
Cleaning any stale ASM disks...
Scanning system for ASM disks...
[root@rac1 ~]# oracleasm listdisks
ASMDISK1
ASMDISK2
ASMDISK3
ASMDISK4
安装环境检测
安装检测工具
安装cvuqdisk软件包,该包在grid软件包rpm目录下
[root@rac1 rpm]# pwd
/opt/soft/grid/rpm
[root@rac1 rpm]# ls
cvuqdisk-1.0.9-1.rpm
[root@rac1 rpm]# rpm -ivh cvuqdisk-1.0.9-1.rpm
Preparing... ########################################### [100%] Using default group oinstall to install package
1:cvuqdisk ########################################### [100%]
执行检测
执行检测在安装(该检查应该在配置完毕SSH对等性的情况下进行,可在安装Grid过程中进行检查)
[root@rac1 grid]# su - grid
[grid@rac1 ~]$ cd /opt/soft/grid/
[grid@rac1 grid]$ ./runcluvfy.sh stage -pre crsinst -n RAC1,RAC2 -fixup –verbose
安装Grid
安装准备
[root@rac1 \u684c\u9762]# su - grid [grid@rac1 ~]$ export DISPLAY=:1.0 [grid@rac1 ~]$ export LANG=en_US.UTF-8 [grid@rac1 ~]$cd /opt/soft/grid
[grid@rac1 ~]$./runInstaller
安装Grid
SCAN Name需要和hosts文件名称一致
两台集群节点的网卡名称必须一致,否则该处会报错误
密码:passw0rd
注意:/opt/u01/app/11.2.0/grid/root.sh这个脚本只有一个节点执行完成之后,才能在另外一个节点上执行。
检查集群状态
[root@rac1 disks]# su - grid
查看服务状态
[grid@rac1 ~]$ crs_stat -t
Name Type Target State Host ------------------------------------------------------------
ora.DATA.dg ora....up.type ONLINE ONLINE rac1 ora....ER.lsnr ora....er.type ONLINE ONLINE rac1 ora....N1.lsnr ora....er.type ONLINE ONLINE rac2
ora.asm ora.asm.type ONLINE ONLINE rac1 ora.cvu ora.cvu.type ONLINE ONLINE rac2 ora.gsd ora.gsd.type OFFLINE OFFLINE d7b6635c31126edb6e1a1029work ora....rk.type ONLINE ONLINE rac1 ora.oc4j ora.oc4j.type ONLINE ONLINE rac2 ora.ons ora.ons.type ONLINE ONLINE rac1 ora....SM2.asm application ONLINE ONLINE rac1 ora....C1.lsnr application ONLINE ONLINE rac1 ora.rac1.gsd application OFFLINE OFFLINE
正在阅读:
OracleLinux6.4+OracleRAC11.2.0.3安装文档04-27
二年级小学语文质量分析报告07-01
网络推广工作计划03-18
公务员面试必背06-28
婆婆跟我说从小不要习惯宝宝喝一口水05-07
景运安全小故事安全就是幸福 208-05
对联学案语文08-13
吉林省2017年养老金上调方案06-04
汽车故障判断63条03-24
- 教学能力大赛决赛获奖-教学实施报告-(完整图文版)
- 互联网+数据中心行业分析报告
- 2017上海杨浦区高三一模数学试题及答案
- 招商部差旅接待管理制度(4-25)
- 学生游玩安全注意事项
- 学生信息管理系统(文档模板供参考)
- 叉车门架有限元分析及系统设计
- 2014帮助残疾人志愿者服务情况记录
- 叶绿体中色素的提取和分离实验
- 中国食物成分表2020年最新权威完整改进版
- 推动国土资源领域生态文明建设
- 给水管道冲洗和消毒记录
- 计算机软件专业自我评价
- 高中数学必修1-5知识点归纳
- 2018-2022年中国第五代移动通信技术(5G)产业深度分析及发展前景研究报告发展趋势(目录)
- 生产车间巡查制度
- 2018版中国光热发电行业深度研究报告目录
- (通用)2019年中考数学总复习 第一章 第四节 数的开方与二次根式课件
- 2017_2018学年高中语文第二单元第4课说数课件粤教版
- 上市新药Lumateperone(卢美哌隆)合成检索总结报告
- OracleLinux
- OracleRAC
- 安装
- 文档
- 11.2
- 6.4
- 0.3
- 2.1 夏、商、西周的兴亡 教学设计 教案
- 实验 观察人血涂片
- 汽车4S店标准化管理
- 幼儿在社会性发展方面有何特点(1)
- 大学生兼职调查分析报告
- 2019年湖北大学商学院431金融学综合之金融学考研强化五套模拟题
- 基于预失真技术的射频功率放大器线性化研究
- 蛋白质的结构与功能
- 煤矿机电专业毕业设计论文
- 我国文化软实力研究
- 大学生暑期三下乡支教实践报告范文2篇
- 电动机维修保养技术标准
- 2011-2016年北京中考数学试题分类汇编
- 2017年西藏造价工程师考试造价管理:建筑安全生产管理模拟试题
- Flywireless5.1操作手册
- 大班下学期配班工作计划【三】
- 2020年班主任年度考核总结
- 市场拓展主管岗位的职责
- 文学类文本川端康城《秋雨》阅读练习及答案
- 2016年上半年内蒙古主治医师(计划生育)高级(师)资格模拟试题