在oracle linux 7.2 上安装 oracle rac 11.2.0.4.0 for linux x86 64 · 2018-08-24 ·...

136
Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86_64 目录 一、官方文档中的一些介绍.............................................................................................................................................................................................................. 3 2.3.1 Memory Requirements ....................................................................................................................................................................................................... 3 2.3.3 Disk Space Requirements .................................................................................................................................................................................................... 4 2.4.3 Package Requirements ........................................................................................................................................................................................................ 4 2.4.5 Additional Software Requirements ..................................................................................................................................................................................... 6 2.4.5.1 Oracle ODBC Drivers ................................................................................................................................................................................................ 6 2.8 Installing the cvuqdisk Package for Linux ............................................................................................................................................................................... 6 二、Linux 系统的几个级别 ................................................................................................................................................................................................................ 6 三、安装 RAC ...................................................................................................................................................................................................................................... 7 1. VirtualBox 安装 Oracle Linux 7.2 For Linux x86_64 的过程此处省略,这里有几点需要注意一下 .............................................................................. 7 2. 挂载 ISO 镜像文件 ................................................................................................................................................................................................................. 9 3. 配置本地 YUM ................................................................................................................................................................................................................. 10 4. 网络命令 ifconfig 不存在,YUM 源安 net-tools 软件包解决 ......................................................................................................................................... 12 5. 安装桌面环境 ...................................................................................................................................................................................................................... 14 6. /etc/hosts 文件中增加如下内容 ..................................................................................................................................................................................... 16 7. 通过 YUM 源安装 tigervnc (图形界面远程连接工具) ....................................................................................................................................................... 16 8. 配置 VNC .............................................................................................................................................................................................................................. 36 9. 操作系统的磁盘和 ASM 共享磁盘容量规划 ..................................................................................................................................................................... 38 10. 用户 root 的密码和两节点数据库 REDO 个数................................................................................................................................................................. 38 11. 停以下服务 (两节点) ........................................................................................................................................................................................................ 39 12. 禁用 SELinux (两节点) ........................................................................................................................................................................................................ 39 1 / 136

Upload: others

Post on 29-Jun-2020

8 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

在 Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86_64

目录 一、官方文档中的一些介绍.............................................................................................................................................................................................................. 3

2.3.1 Memory Requirements ....................................................................................................................................................................................................... 3 2.3.3 Disk Space Requirements .................................................................................................................................................................................................... 4 2.4.3 Package Requirements ........................................................................................................................................................................................................ 4 2.4.5 Additional Software Requirements ..................................................................................................................................................................................... 6

2.4.5.1 Oracle ODBC Drivers ................................................................................................................................................................................................ 6 2.8 Installing the cvuqdisk Package for Linux ............................................................................................................................................................................... 6

二、Linux 系统的几个级别 ................................................................................................................................................................................................................ 6 三、安装 RAC ...................................................................................................................................................................................................................................... 7

1. 用 VirtualBox 安装 Oracle Linux 7.2 For Linux x86_64 的过程此处省略,这里有几点需要注意一下 .............................................................................. 7 2. 挂载 ISO 镜像文件 ................................................................................................................................................................................................................. 9 3. 配置本地 YUM 源 ................................................................................................................................................................................................................. 10 4. 网络命令 ifconfig 不存在,通 YUM 源安 net-tools 软件包解决 ......................................................................................................................................... 12 5. 安装桌面环境 ...................................................................................................................................................................................................................... 14 6. 在/etc/hosts 文件中增加如下内容 ..................................................................................................................................................................................... 16 7. 通过 YUM 源安装 tigervnc (图形界面远程连接工具) ....................................................................................................................................................... 16 8. 配置 VNC .............................................................................................................................................................................................................................. 36 9. 操作系统的磁盘和 ASM 共享磁盘容量规划 ..................................................................................................................................................................... 38 10. 用户 root 的密码和两节点数据库 REDO 个数 ................................................................................................................................................................. 38 11. 停以下服务 (两节点) ........................................................................................................................................................................................................ 39 12. 禁用 SELinux (两节点) ........................................................................................................................................................................................................ 39

1 / 136

Page 2: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

13. 创建用户和组 (两节点) .................................................................................................................................................................................................... 40 14. 配置 grid 用户和 oracle 用户的环境变量(两节点) .......................................................................................................................................................... 40 15. 创建所需的目录及赋予相应的权限 (两节点) ................................................................................................................................................................ 42 16. 编辑/etc/security/limits.conf 文件,增加如下内容 (两节点) ........................................................................................................................................... 43 17. 编辑/etc/pam.d/login 文件,增加如下内容 (两节点) ....................................................................................................................................................... 43 18. 编辑/etc/profile 文件,添加如下参数 (两节点) ................................................................................................................................................................ 43 19. 编辑/etc/sysctl.conf 文件,增加下列参数 (两节点) [Oracle Linux 7.2 下为这个文件 # vi /usr/lib/sysctl.d/00-system.conf] ........................................ 44 20. 配置 SSH 互信,在图形界面点击设置,此步不用命令 .................................................................................................................................................... 45 21. 将 grid 和 oracle 的软件安装包 上传到 节点一 的 /software 目录 ............................................................................................................................ 45 22. 用 YUM 源安装 RAC 必需的 RPM 软件包......................................................................................................................................................................... 46 23. 用 VirutalBox 克隆 adccrac1 为另一台主机 adccrac2,选 Full Clone,并选择“重新初始化两块网卡的 MAC 地址” .............................................. 48 24. 关闭两节点的主机,在节点一上添加 6 块磁盘并将磁盘类型设置为“可共享”,在节点二上依次添加节点一刚刚新增的磁盘,最后将 6 块磁

盘设置为共享模式,并开启两个节点的主机 ........................................................................................................................................................................ 53 25. 用 UDEV 方式绑定磁盘 (两节点) ..................................................................................................................................................................................... 54 26. 对 grid 软件打 PSU 补丁 19404309 ................................................................................................................................................................................... 56 27. 在 节点一 打开 VNC 的图形桌面 .................................................................................................................................................................................... 57 28. 由于存在 BUG 18370031,安装 Oracle Grid Infrastructure 软件,后面打完补丁后再配置 GI .................................................................................... 58

7.2.3 Oracle Grid Infrastructure Installation Issue ...................................................................................................................................................... 58 29. 给 GI 软件 打 PSU 补丁 18370031 ................................................................................................................................................................................... 61

(1) 更新 Opatch 工具 ....................................................................................................................................................................................................... 61 (2) 打补丁 18370031 ........................................................................................................................................................................................................ 62

30. 配置 Grid ............................................................................................................................................................................................................................ 66 (1) 克隆 grid 软件到节点 2 .............................................................................................................................................................................................. 66 (2) 克隆 ORACLE_HOME 配置 ......................................................................................................................................................................................... 66 (3) 进行 Cluster 配置 ........................................................................................................................................................................................................ 73

31. 检查 GI (两节点都检查) ..................................................................................................................................................................................................... 92

2 / 136

Page 3: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

32. 通过 asmca 命令 创建 ASM 磁盘的 data back arch 3 个磁盘组(只在节点一上做) ..................................................................................................... 96 33. 安装 DB (只在节点一上做) 只安装软件,不建库 ........................................................................................................................................................ 101

(1) 对 db 软件 打补丁 19404309 ................................................................................................................................................................................. 101 (2) 安装 ........................................................................................................................................................................................................................... 101

34. 在 DB 上 安装 PSU .......................................................................................................................................................................................................... 103 (1) 介质 ........................................................................................................................................................................................................................... 103 (2) 升级 Opatch 工具 ..................................................................................................................................................................................................... 104 (3) 安装 PSU .................................................................................................................................................................................................................... 105

35. 使用 DBCA 命令 在节点一,创建 RAC 数据库 racdb .................................................................................................................................................. 113 36. 设置归档目录,并重启数据库到 mount 状态,打开归档模式,最后打开数据库 .................................................................................................. 132 37. 在 grid 用户下 关闭集群服务之后,重新启动正常 .................................................................................................................................................... 134

一、官方文档中的一些介绍

https://docs.oracle.com/cd/E11882_01/install.112/e47689/pre_install.htm#LADBI1106

2.3.1 Memory Requirements

The following are the memory requirements for installing Oracle Database 11g Release 2 (11.2): Minimum: 1 GB of RAM Recommended: 2 GB of RAM or more RAM Swap Space Between 1 GB and 2 GB 1.5 times the size of the RAM Between 2 GB and 16 GB Equal to the size of the RAM

3 / 136

Page 4: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

More than 16 GB 16 GB

2.3.3 Disk Space Requirements

The following are the disk space requirements for installing Oracle Database 11g Release 2 (11.2): 1 GB of space in the /tmp directory The following tables describe the disk space requirements for software files and data files for each installation type on Linux x86-64: Installation Type Requirement for Software Files (GB) Enterprise Edition 4.7 Installation Type Disk Space for Data Files (GB) Enterprise Edition 1.7 Starting with Oracle Database 11g Release 2 (11.2.0.4), Oracle Linux 7 and Red Hat Enterprise Linux 7 are supported on Linux x86-64.

2.4.3 Package Requirements

Oracle Database Package Requirements for Linux x86-64 Oracle Linux 7 and Red Hat Enterprise Linux 7 The following packages (or later versions) must be installed: binutils-2.23.52.0.1-12.el7.x86_64 compat-libcap1-1.10-3.el7.x86_64 compat-libstdc++-33-3.2.3-71.el7.i686 compat-libstdc++-33-3.2.3-71.el7.x86_64 gcc-4.8.2-3.el7.x86_64 gcc-c++-4.8.2-3.el7.x86_64 glibc-2.17-36.el7.i686

4 / 136

Page 5: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

glibc-2.17-36.el7.x86_64 glibc-devel-2.17-36.el7.i686 glibc-devel-2.17-36.el7.x86_64 ksh libaio-0.3.109-9.el7.i686 libaio-0.3.109-9.el7.x86_64 libaio-devel-0.3.109-9.el7.i686 libaio-devel-0.3.109-9.el7.x86_64 libgcc-4.8.2-3.el7.i686 libgcc-4.8.2-3.el7.x86_64 libstdc++-4.8.2-3.el7.i686 libstdc++-4.8.2-3.el7.x86_64 libstdc++-devel-4.8.2-3.el7.i686 libstdc++-devel-4.8.2-3.el7.x86_64 libXi-1.7.2-1.el7.i686 libXi-1.7.2-1.el7.x86_64 libXtst-1.2.2-1.el7.i686 libXtst-1.2.2-1.el7.x86_64 make-3.82-19.el7.x86_64 sysstat-10.1.5-1.el7.x86_64

5 / 136

Page 6: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

2.4.5 Additional Software Requirements

2.4.5.1 Oracle ODBC Drivers

To use ODBC on Linux x86-64, the following additional ODBC RPMs are required: On Oracle Linux 7, and Red Hat Enterprise Linux 7: unixODBC-2.3.1-6.el7.x86_64 or later unixODBC-2.3.1-6.el7.i686 or later unixODBC-devel-2.3.1-6.el7.x86_64 or later unixODBC-devel-2.3.1-6.el7.i686 or later

2.8 Installing the cvuqdisk Package for Linux

# rpm -iv cvuqdisk-1.0.9-1.rpm

二、Linux 系统的几个级别

为了让 Linux 系统在启动后能直接进入到控制台字符操作模式,我们可以配置/etc/inittab 文件。更改 id:5: initdefault:这一行为 id:3:initdefault:后重新启

动系统即可。我们看到,简简单单地将 5 改为 3,就能实现启动时直接进入 X-Window 图形操作界面或控制台字符操作界面的转换,这是因为 Linux 操作

系统有六种不同的运行级别(见/etc/inittab 文件中描述),在不同的运行级下,系统有着不同的状态,这六种运行级分别为: # Default runlevel. The runlevels used by RHS are: # 0 - halt (Do NOT set initdefault to this)

6 / 136

Page 7: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

# 1 - Single user mode # 2 - Multiuser, without NFS (The same as 3, if you do not have networking) # 3 - Full multiuser mode # 4 - unused # 5 - X11 # 6 - reboot (Do NOT set initdefault to this) #

三、安装 RAC

1. 用 VirtualBox 安装 Oracle Linux 7.2 For Linux x86_64 的过程此处省略,这里有几点需要注意一下

(1) 最小化安装(大约 320 个软件包),先不安装图形界面,之后通过 YUM 源进行安装; (2) 安装过程中,设置时区(亚洲 上海)、自动分区、主机名(adccrac1,这里一定不要设置为大写,因为在后面安装 GI 软件时,SSH 互信虽然设置成功,但

是测试总是一直报错,后来查阅相关文档“[INS-06006] Passwordless SSH connectivity not set up” https://blog.csdn.net/kevin_lcc/article/details/47045713 得知,这是 11.2.0.4.0 的一个 Bug,12c 目前没有测试过)和 ROOT 密码(adccrac); (3) 设置网络,两块网卡 enp0s3 和 enp0s8 的 IP 地址和子网掩码等等; 其中 IP 地址是手动方式(不是 DHCP 自动获取)设置, 网卡 enp0s3,192.168.210.61,255.255.255.0,192.168.210.1 网卡 enp0s8,10.10.210.61,255.255.255.0,没有网关 然后将两块网卡 都选择开启 (4) 在安装成功操作系统并重新启动之后,系统默认将两块网卡设置的开机不启动(虽然上一步选择的是开启),下面对两块网卡的配置文件进行设置,让

其下次启动以后自动开启 [root@adccrac1 ~]# cat /etc/sysconfig/network-scripts/ifcfg-enp0s3 TYPE=Ethernet

7 / 136

Page 8: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

BOOTPROTO=none DEFROUTE=yes IPV4_FAILURE_FATAL=no IPV6INIT=yes IPV6_AUTOCONF=yes IPV6_DEFROUTE=yes IPV6_FAILURE_FATAL=no NAME=enp0s3 UUID=f26a2d18-32d6-4a17-88de-68127c860b82 DEVICE=enp0s3 ONBOOT=yes <<== 将这个值改为 yes,原来是 no IPADDR=192.168.210.61 PREFIX=24 GATEWAY=192.168.210.1 IPV6_PEERDNS=yes IPV6_PEERROUTES=yes IPV6_PRIVACY=no [root@adccrac1 ~]# cat /etc/sysconfig/network-scripts/ifcfg-enp0s8 TYPE=Ethernet BOOTPROTO=none DEFROUTE=yes IPV4_FAILURE_FATAL=no IPV6INIT=yes IPV6_AUTOCONF=yes IPV6_DEFROUTE=yes

8 / 136

Page 9: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

IPV6_FAILURE_FATAL=no NAME=enp0s8 UUID=973d91e4-913d-47ec-b117-9bc36190cd65 DEVICE=enp0s8 ONBOOT=yes <<== 将这个值改为 yes,原来是 no IPADDR=10.10.210.61 PREFIX=24 IPV6_PEERDNS=yes IPV6_PEERROUTES=yes IPV6_PRIVACY=no (5) 接下来就可以使用 Xshell 的 SSH 客户端工具连接到这台 Linux 服务器进行后续的操作了;

2. 挂载 ISO 镜像文件

[root@adccrac1 ~]# mkdir -p /media/OL7.2 用 xftp 上传 V100082-01.iso 到 /media/OL7.2 [root@adccrac1 ~]# mkdir -p /mnt/ISO [root@adccrac1 ~]# [root@adccrac1 ~]# mount -o loop,ro /media/OL7.2/V100082-01.iso /mnt/ISO/ [root@adccrac1 ~]# cat /etc/fstab 在最后新增一行 # # /etc/fstab # Created by anaconda on Fri Jul 27 19:10:29 2018 # # Accessible filesystems, by reference, are maintained under '/dev/disk' # See man pages fstab(5), findfs(8), mount(8) and/or blkid(8) for more info

9 / 136

Page 10: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

# /dev/mapper/ol_adcc-root / xfs defaults 0 0 UUID=54c63908-f74d-4744-9fb7-93aa684e4715 /boot xfs defaults 0 0 /dev/mapper/ol_adcc-home /home xfs defaults 0 0 /dev/mapper/ol_adcc-swap swap swap defaults 0 0 /media/OL7.2/V100082-01.iso /mnt/ISO/ iso9660 defaults,ro,loop 0 0

3. 配置本地 YUM 源

[root@adccrac1 ~]# cd /etc/yum.repos.d/ [root@adccrac1 yum.repos.d]# ls -l total 4 -rw-r--r--. 1 root root 2560 Nov 20 2015 public-yum-ol7.repo [root@adccrac1 yum.repos.d]# mv public-yum-ol7.repo public-yum-ol7.repo.bak [root@adccrac1 yum.repos.d]# vi ol7.repo 创建 repo 文件 [ol7] name=Oracle Linux Server 7.2 baseurl=file:///mnt/ISO #gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-oracle gpgcheck=0 enabled=1 [root@adccrac1 yum.repos.d]# yum clean all Loaded plugins: ulninfo Cleaning repos: ol7 Cleaning up everything

10 / 136

Page 11: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

[root@adccrac1 yum.repos.d]# [root@adccrac1 yum.repos.d]# yum makecache Loaded plugins: ulninfo ol7 | 3.6 kB 00:00:00 (1/4): ol7/group_gz | 134 kB 00:00:00 (2/4): ol7/filelists_db | 3.5 MB 00:00:00 (3/4): ol7/primary_db | 4.1 MB 00:00:00 (4/4): ol7/other_db | 1.4 MB 00:00:00 Metadata Cache Created [root@adccrac1 yum.repos.d]# yum list ...... yp-tools.x86_64 2.14-3.el7 ol7 ypbind.x86_64 3:1.37.1-7.el7 ol7 ypserv.x86_64 2.31-8.el7 ol7 yum-langpacks.noarch 0.4.2-4.el7 ol7 yum-plugin-aliases.noarch 1.1.31-34.0.1.el7 ol7 yum-plugin-changelog.noarch 1.1.31-34.0.1.el7 ol7 yum-plugin-ovl.noarch 1.1.31-34.0.1.el7 ol7 yum-plugin-tmprepo.noarch 1.1.31-34.0.1.el7 ol7 yum-plugin-verify.noarch 1.1.31-34.0.1.el7 ol7 yum-plugin-versionlock.noarch 1.1.31-34.0.1.el7 ol7 yum-utils.noarch 1.1.31-34.0.1.el7 ol7 zenity.x86_64 3.8.0-5.el7 ol7 zip.x86_64 3.0-10.el7 ol7 zlib.i686 1.2.7-15.el7 ol7

11 / 136

Page 12: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

zlib-devel.i686 1.2.7-15.el7 ol7 zlib-devel.x86_64 1.2.7-15.el7 ol7 zsh.x86_64 5.0.2-14.el7 ol7 zziplib.i686 0.13.62-5.el7 ol7 zziplib.x86_64 0.13.62-5.el7 ol7

4. 网络命令 ifconfig 不存在,通 YUM 源安 net-tools 软件包解决

[root@adccrac ~]# ifconfig -bash: ifconfig: command not found [root@adccrac1 ~]# yum install -y net-tools Loaded plugins: ulninfo Resolving Dependencies --> Running transaction check ---> Package net-tools.x86_64 0:2.0-0.17.20131004git.el7 will be installed --> Finished Dependency Resolution Dependencies Resolved ================================================================================================== Package Arch Version Repository Size ================================================================================================== Installing: net-tools x86_64 2.0-0.17.20131004git.el7 ol7 303 k

12 / 136

Page 13: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

Transaction Summary ================================================================================================== Install 1 Package Total download size: 303 k Installed size: 917 k Downloading packages: Running transaction check Running transaction test Transaction test succeeded Running transaction Installing : net-tools-2.0-0.17.20131004git.el7.x86_64 1/1 Verifying : net-tools-2.0-0.17.20131004git.el7.x86_64 1/1 Installed: net-tools.x86_64 0:2.0-0.17.20131004git.el7 Complete! [root@adccrac1 ~]# ifconfig enp0s3: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500 inet 192.168.210.61 netmask 255.255.255.0 broadcast 192.168.210.255 inet6 fe80::a00:27ff:fef4:e8b0 prefixlen 64 scopeid 0x20<link> ether 08:00:27:f4:e8:b0 txqueuelen 1000 (Ethernet) RX packets 3283737 bytes 4656605240 (4.3 GiB)

13 / 136

Page 14: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

RX errors 0 dropped 0 overruns 0 frame 0 TX packets 361274 bytes 33222076 (31.6 MiB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0 enp0s8: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500 inet 10.10.210.61 netmask 255.255.255.0 broadcast 10.10.210.255 inet6 fe80::a00:27ff:fe03:6ffb prefixlen 64 scopeid 0x20<link> ether 08:00:27:03:6f:fb txqueuelen 1000 (Ethernet) RX packets 71 bytes 9814 (9.5 KiB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 8 bytes 564 (564.0 B) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0 lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536 inet 127.0.0.1 netmask 255.0.0.0 inet6 ::1 prefixlen 128 scopeid 0x10<host> loop txqueuelen 0 (Local Loopback) RX packets 12 bytes 1032 (1.0 KiB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 12 bytes 1032 (1.0 KiB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

5. 安装桌面环境

[root@adccrac1 ~]# yum grouplist

14 / 136

Page 15: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

Loaded plugins: ulninfo There is no installed groups file. Maybe run: yum groups mark convert (see man yum) Available Environment Groups: Minimal Install Infrastructure Server File and Print Server Basic Web Server Virtualization Host Server with GUI <<== 安装这个软件包的组 Available Groups: Compatibility Libraries Console Internet Tools Development Tools Graphical Administration Tools Legacy UNIX Compatibility Scientific Support Security Tools Smart Card Support System Administration Tools System Management Done [root@adccrac1 ~]# yum -y groupinstall "Server with GUI" ...... yajl.x86_64 0:2.0.4-4.el7

15 / 136

Page 16: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

yelp-libs.x86_64 1:3.14.2-1.el7 yelp-xsl.noarch 0:3.14.0-1.el7 zenity.x86_64 0:3.8.0-5.el7 Complete! 现在,GNOME 的图形界面就安装成功了。

6. 在/etc/hosts 文件中增加如下内容

#public-ip 192.168.210.61 adccrac1 192.168.210.62 adccrac2 #private-ip 10.10.210.61 adccrac1-priv 10.10.210.62 adccrac2-priv #vip 192.168.210.81 adccrac1-vip 192.168.210.82 adccrac2-vip #scan-ip 192.168.210.80 adccrac-scan

7. 通过 YUM 源安装 tigervnc (图形界面远程连接工具)

[root@adccrac1 ~]# yum install -y tigervnc

16 / 136

Page 17: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

Loaded plugins: ulninfo Resolving Dependencies --> Running transaction check ---> Package tigervnc.x86_64 0:1.3.1-3.el7 will be installed --> Processing Dependency: tigervnc-license for package: tigervnc-1.3.1-3.el7.x86_64 --> Processing Dependency: tigervnc-icons for package: tigervnc-1.3.1-3.el7.x86_64 --> Processing Dependency: libjpeg.so.62(LIBJPEG_6.2)(64bit) for package: tigervnc-1.3.1-3.el7.x86_64 --> Processing Dependency: hicolor-icon-theme for package: tigervnc-1.3.1-3.el7.x86_64 --> Processing Dependency: libjpeg.so.62()(64bit) for package: tigervnc-1.3.1-3.el7.x86_64 --> Processing Dependency: libfontconfig.so.1()(64bit) for package: tigervnc-1.3.1-3.el7.x86_64 --> Processing Dependency: libfltk_images.so.1.3()(64bit) for package: tigervnc-1.3.1-3.el7.x86_64 --> Processing Dependency: libfltk.so.1.3()(64bit) for package: tigervnc-1.3.1-3.el7.x86_64 --> Processing Dependency: libXinerama.so.1()(64bit) for package: tigervnc-1.3.1-3.el7.x86_64 --> Processing Dependency: libXft.so.2()(64bit) for package: tigervnc-1.3.1-3.el7.x86_64 --> Processing Dependency: libXfixes.so.3()(64bit) for package: tigervnc-1.3.1-3.el7.x86_64 --> Processing Dependency: libXext.so.6()(64bit) for package: tigervnc-1.3.1-3.el7.x86_64 --> Processing Dependency: libX11.so.6()(64bit) for package: tigervnc-1.3.1-3.el7.x86_64 --> Processing Dependency: libSM.so.6()(64bit) for package: tigervnc-1.3.1-3.el7.x86_64 --> Processing Dependency: libICE.so.6()(64bit) for package: tigervnc-1.3.1-3.el7.x86_64 --> Running transaction check ---> Package fltk.x86_64 0:1.3.0-13.el7 will be installed --> Processing Dependency: libpng15.so.15(PNG15_0)(64bit) for package: fltk-1.3.0-13.el7.x86_64 --> Processing Dependency: libpng15.so.15()(64bit) for package: fltk-1.3.0-13.el7.x86_64 --> Processing Dependency: libXcursor.so.1()(64bit) for package: fltk-1.3.0-13.el7.x86_64 --> Processing Dependency: libGLU.so.1()(64bit) for package: fltk-1.3.0-13.el7.x86_64 --> Processing Dependency: libGL.so.1()(64bit) for package: fltk-1.3.0-13.el7.x86_64

17 / 136

Page 18: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

---> Package fontconfig.x86_64 0:2.10.95-7.el7 will be installed --> Processing Dependency: fontpackages-filesystem for package: fontconfig-2.10.95-7.el7.x86_64 ---> Package hicolor-icon-theme.noarch 0:0.12-7.el7 will be installed ---> Package libICE.x86_64 0:1.0.9-2.el7 will be installed ---> Package libSM.x86_64 0:1.2.2-2.el7 will be installed ---> Package libX11.x86_64 0:1.6.3-2.el7 will be installed --> Processing Dependency: libX11-common >= 1.6.3-2.el7 for package: libX11-1.6.3-2.el7.x86_64 --> Processing Dependency: libxcb.so.1()(64bit) for package: libX11-1.6.3-2.el7.x86_64 ---> Package libXext.x86_64 0:1.3.3-3.el7 will be installed ---> Package libXfixes.x86_64 0:5.0.1-2.1.el7 will be installed ---> Package libXft.x86_64 0:2.3.2-2.el7 will be installed --> Processing Dependency: libXrender.so.1()(64bit) for package: libXft-2.3.2-2.el7.x86_64 ---> Package libXinerama.x86_64 0:1.1.3-2.1.el7 will be installed ---> Package libjpeg-turbo.x86_64 0:1.2.90-5.el7 will be installed ---> Package tigervnc-icons.noarch 0:1.3.1-3.el7 will be installed ---> Package tigervnc-license.noarch 0:1.3.1-3.el7 will be installed --> Running transaction check ---> Package fontpackages-filesystem.noarch 0:1.44-8.el7 will be installed ---> Package libX11-common.noarch 0:1.6.3-2.el7 will be installed ---> Package libXcursor.x86_64 0:1.1.14-2.1.el7 will be installed ---> Package libXrender.x86_64 0:0.9.8-2.1.el7 will be installed ---> Package libpng.x86_64 2:1.5.13-5.el7 will be installed ---> Package libxcb.x86_64 0:1.11-4.el7 will be installed --> Processing Dependency: libXau.so.6()(64bit) for package: libxcb-1.11-4.el7.x86_64 ---> Package mesa-libGL.x86_64 0:10.6.5-3.20150824.el7 will be installed --> Processing Dependency: mesa-libglapi = 10.6.5-3.20150824.el7 for package: mesa-libGL-10.6.5-3.20150824.el7.x86_64

18 / 136

Page 19: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

--> Processing Dependency: libxshmfence.so.1()(64bit) for package: mesa-libGL-10.6.5-3.20150824.el7.x86_64 --> Processing Dependency: libglapi.so.0()(64bit) for package: mesa-libGL-10.6.5-3.20150824.el7.x86_64 --> Processing Dependency: libXxf86vm.so.1()(64bit) for package: mesa-libGL-10.6.5-3.20150824.el7.x86_64 --> Processing Dependency: libXdamage.so.1()(64bit) for package: mesa-libGL-10.6.5-3.20150824.el7.x86_64 ---> Package mesa-libGLU.x86_64 0:9.0.0-4.el7 will be installed --> Running transaction check ---> Package libXau.x86_64 0:1.0.8-2.1.el7 will be installed ---> Package libXdamage.x86_64 0:1.1.4-4.1.el7 will be installed ---> Package libXxf86vm.x86_64 0:1.1.3-2.1.el7 will be installed ---> Package libxshmfence.x86_64 0:1.2-1.el7 will be installed ---> Package mesa-libglapi.x86_64 0:10.6.5-3.20150824.el7 will be installed --> Finished Dependency Resolution Dependencies Resolved ================================================================================================== Package Arch Version Repository Size ================================================================================================== Installing: tigervnc x86_64 1.3.1-3.el7 ol7 209 k Installing for dependencies: fltk x86_64 1.3.0-13.el7 ol7 648 k fontconfig x86_64 2.10.95-7.el7 ol7 226 k fontpackages-filesystem noarch 1.44-8.el7 ol7 9.4 k hicolor-icon-theme noarch 0.12-7.el7 ol7 42 k libICE x86_64 1.0.9-2.el7 ol7 64 k

19 / 136

Page 20: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

libSM x86_64 1.2.2-2.el7 ol7 39 k libX11 x86_64 1.6.3-2.el7 ol7 605 k libX11-common noarch 1.6.3-2.el7 ol7 161 k libXau x86_64 1.0.8-2.1.el7 ol7 28 k libXcursor x86_64 1.1.14-2.1.el7 ol7 29 k libXdamage x86_64 1.1.4-4.1.el7 ol7 20 k libXext x86_64 1.3.3-3.el7 ol7 38 k libXfixes x86_64 5.0.1-2.1.el7 ol7 17 k libXft x86_64 2.3.2-2.el7 ol7 58 k libXinerama x86_64 1.1.3-2.1.el7 ol7 13 k libXrender x86_64 0.9.8-2.1.el7 ol7 24 k libXxf86vm x86_64 1.1.3-2.1.el7 ol7 17 k libjpeg-turbo x86_64 1.2.90-5.el7 ol7 135 k libpng x86_64 2:1.5.13-5.el7 ol7 210 k libxcb x86_64 1.11-4.el7 ol7 189 k libxshmfence x86_64 1.2-1.el7 ol7 6.5 k mesa-libGL x86_64 10.6.5-3.20150824.el7 ol7 184 k mesa-libGLU x86_64 9.0.0-4.el7 ol7 193 k mesa-libglapi x86_64 10.6.5-3.20150824.el7 ol7 39 k tigervnc-icons noarch 1.3.1-3.el7 ol7 34 k tigervnc-license noarch 1.3.1-3.el7 ol7 25 k Transaction Summary ================================================================================================== Install 1 Package (+26 Dependent packages)

20 / 136

Page 21: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

Total download size: 3.2 M Installed size: 9.0 M Downloading packages: -------------------------------------------------------------------------------------------------- Total 5.7 MB/s | 3.2 MB 00:00:00 Running transaction check Running transaction test Transaction test succeeded Running transaction Installing : libICE-1.0.9-2.el7.x86_64 1/27 Installing : libjpeg-turbo-1.2.90-5.el7.x86_64 2/27 Installing : libSM-1.2.2-2.el7.x86_64 3/27 Installing : libXau-1.0.8-2.1.el7.x86_64 4/27 Installing : libxcb-1.11-4.el7.x86_64 5/27 Installing : mesa-libglapi-10.6.5-3.20150824.el7.x86_64 6/27 Installing : libxshmfence-1.2-1.el7.x86_64 7/27 Installing : libX11-common-1.6.3-2.el7.noarch 8/27 Installing : libX11-1.6.3-2.el7.x86_64 9/27 Installing : libXext-1.3.3-3.el7.x86_64 10/27 Installing : libXfixes-5.0.1-2.1.el7.x86_64 11/27 Installing : libXinerama-1.1.3-2.1.el7.x86_64 12/27 Installing : libXrender-0.9.8-2.1.el7.x86_64 13/27 Installing : libXcursor-1.1.14-2.1.el7.x86_64 14/27 Installing : libXdamage-1.1.4-4.1.el7.x86_64 15/27 Installing : libXxf86vm-1.1.3-2.1.el7.x86_64 16/27 Installing : mesa-libGL-10.6.5-3.20150824.el7.x86_64 17/27

21 / 136

Page 22: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

Installing : mesa-libGLU-9.0.0-4.el7.x86_64 18/27 Installing : tigervnc-license-1.3.1-3.el7.noarch 19/27 Installing : 2:libpng-1.5.13-5.el7.x86_64 20/27 Installing : tigervnc-icons-1.3.1-3.el7.noarch 21/27 Installing : hicolor-icon-theme-0.12-7.el7.noarch 22/27 Installing : fontpackages-filesystem-1.44-8.el7.noarch 23/27 Installing : fontconfig-2.10.95-7.el7.x86_64 24/27 Installing : libXft-2.3.2-2.el7.x86_64 25/27 Installing : fltk-1.3.0-13.el7.x86_64 26/27 Installing : tigervnc-1.3.1-3.el7.x86_64 27/27 Verifying : libXext-1.3.3-3.el7.x86_64 1/27 Verifying : libjpeg-turbo-1.2.90-5.el7.x86_64 2/27 Verifying : libXxf86vm-1.1.3-2.1.el7.x86_64 3/27 Verifying : libxcb-1.11-4.el7.x86_64 4/27 Verifying : mesa-libGLU-9.0.0-4.el7.x86_64 5/27 Verifying : fontpackages-filesystem-1.44-8.el7.noarch 6/27 Verifying : hicolor-icon-theme-0.12-7.el7.noarch 7/27 Verifying : tigervnc-1.3.1-3.el7.x86_64 8/27 Verifying : libXcursor-1.1.14-2.1.el7.x86_64 9/27 Verifying : libX11-1.6.3-2.el7.x86_64 10/27 Verifying : tigervnc-icons-1.3.1-3.el7.noarch 11/27 Verifying : 2:libpng-1.5.13-5.el7.x86_64 12/27 Verifying : libXinerama-1.1.3-2.1.el7.x86_64 13/27 Verifying : libXft-2.3.2-2.el7.x86_64 14/27 Verifying : tigervnc-license-1.3.1-3.el7.noarch 15/27 Verifying : libXrender-0.9.8-2.1.el7.x86_64 16/27

22 / 136

Page 23: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

Verifying : libX11-common-1.6.3-2.el7.noarch 17/27 Verifying : libICE-1.0.9-2.el7.x86_64 18/27 Verifying : fltk-1.3.0-13.el7.x86_64 19/27 Verifying : libxshmfence-1.2-1.el7.x86_64 20/27 Verifying : mesa-libglapi-10.6.5-3.20150824.el7.x86_64 21/27 Verifying : libXfixes-5.0.1-2.1.el7.x86_64 22/27 Verifying : libXau-1.0.8-2.1.el7.x86_64 23/27 Verifying : libSM-1.2.2-2.el7.x86_64 24/27 Verifying : fontconfig-2.10.95-7.el7.x86_64 25/27 Verifying : mesa-libGL-10.6.5-3.20150824.el7.x86_64 26/27 Verifying : libXdamage-1.1.4-4.1.el7.x86_64 27/27 Installed: tigervnc.x86_64 0:1.3.1-3.el7 Dependency Installed: fltk.x86_64 0:1.3.0-13.el7 fontconfig.x86_64 0:2.10.95-7.el7 fontpackages-filesystem.noarch 0:1.44-8.el7 hicolor-icon-theme.noarch 0:0.12-7.el7 libICE.x86_64 0:1.0.9-2.el7 libSM.x86_64 0:1.2.2-2.el7 libX11.x86_64 0:1.6.3-2.el7 libX11-common.noarch 0:1.6.3-2.el7 libXau.x86_64 0:1.0.8-2.1.el7 libXcursor.x86_64 0:1.1.14-2.1.el7 libXdamage.x86_64 0:1.1.4-4.1.el7 libXext.x86_64 0:1.3.3-3.el7 libXfixes.x86_64 0:5.0.1-2.1.el7 libXft.x86_64 0:2.3.2-2.el7 libXinerama.x86_64 0:1.1.3-2.1.el7 libXrender.x86_64 0:0.9.8-2.1.el7 libXxf86vm.x86_64 0:1.1.3-2.1.el7 libjpeg-turbo.x86_64 0:1.2.90-5.el7 libpng.x86_64 2:1.5.13-5.el7 libxcb.x86_64 0:1.11-4.el7

23 / 136

Page 24: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

libxshmfence.x86_64 0:1.2-1.el7 mesa-libGL.x86_64 0:10.6.5-3.20150824.el7 mesa-libGLU.x86_64 0:9.0.0-4.el7 mesa-libglapi.x86_64 0:10.6.5-3.20150824.el7 tigervnc-icons.noarch 0:1.3.1-3.el7 tigervnc-license.noarch 0:1.3.1-3.el7 Complete! [root@adccrac1 ~]# yum install -y tigervnc-server Loaded plugins: ulninfo Resolving Dependencies --> Running transaction check ---> Package tigervnc-server.x86_64 0:1.3.1-3.el7 will be installed --> Processing Dependency: xorg-x11-xinit for package: tigervnc-server-1.3.1-3.el7.x86_64 --> Processing Dependency: xorg-x11-xauth for package: tigervnc-server-1.3.1-3.el7.x86_64 --> Processing Dependency: tigervnc-server-minimal for package: tigervnc-server-1.3.1-3.el7.x86_64 --> Processing Dependency: perl for package: tigervnc-server-1.3.1-3.el7.x86_64 --> Processing Dependency: /usr/bin/perl for package: tigervnc-server-1.3.1-3.el7.x86_64 --> Processing Dependency: libXtst.so.6()(64bit) for package: tigervnc-server-1.3.1-3.el7.x86_64 --> Running transaction check ---> Package libXtst.x86_64 0:1.2.2-2.1.el7 will be installed --> Processing Dependency: libXi.so.6()(64bit) for package: libXtst-1.2.2-2.1.el7.x86_64 ---> Package perl.x86_64 4:5.16.3-286.el7 will be installed --> Processing Dependency: perl-libs = 4:5.16.3-286.el7 for package: 4:perl-5.16.3-286.el7.x86_64 --> Processing Dependency: perl(Socket) >= 1.3 for package: 4:perl-5.16.3-286.el7.x86_64 --> Processing Dependency: perl(Scalar::Util) >= 1.10 for package: 4:perl-5.16.3-286.el7.x86_64 --> Processing Dependency: perl-macros for package: 4:perl-5.16.3-286.el7.x86_64 --> Processing Dependency: perl-libs for package: 4:perl-5.16.3-286.el7.x86_64

24 / 136

Page 25: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

--> Processing Dependency: perl(threads::shared) for package: 4:perl-5.16.3-286.el7.x86_64 --> Processing Dependency: perl(threads) for package: 4:perl-5.16.3-286.el7.x86_64 --> Processing Dependency: perl(constant) for package: 4:perl-5.16.3-286.el7.x86_64 --> Processing Dependency: perl(Time::Local) for package: 4:perl-5.16.3-286.el7.x86_64 --> Processing Dependency: perl(Time::HiRes) for package: 4:perl-5.16.3-286.el7.x86_64 --> Processing Dependency: perl(Storable) for package: 4:perl-5.16.3-286.el7.x86_64 --> Processing Dependency: perl(Socket) for package: 4:perl-5.16.3-286.el7.x86_64 --> Processing Dependency: perl(Scalar::Util) for package: 4:perl-5.16.3-286.el7.x86_64 --> Processing Dependency: perl(Pod::Simple::XHTML) for package: 4:perl-5.16.3-286.el7.x86_64 --> Processing Dependency: perl(Pod::Simple::Search) for package: 4:perl-5.16.3-286.el7.x86_64 --> Processing Dependency: perl(Getopt::Long) for package: 4:perl-5.16.3-286.el7.x86_64 --> Processing Dependency: perl(Filter::Util::Call) for package: 4:perl-5.16.3-286.el7.x86_64 --> Processing Dependency: perl(File::Temp) for package: 4:perl-5.16.3-286.el7.x86_64 --> Processing Dependency: perl(File::Spec::Unix) for package: 4:perl-5.16.3-286.el7.x86_64 --> Processing Dependency: perl(File::Spec::Functions) for package: 4:perl-5.16.3-286.el7.x86_64 --> Processing Dependency: perl(File::Spec) for package: 4:perl-5.16.3-286.el7.x86_64 --> Processing Dependency: perl(File::Path) for package: 4:perl-5.16.3-286.el7.x86_64 --> Processing Dependency: perl(Exporter) for package: 4:perl-5.16.3-286.el7.x86_64 --> Processing Dependency: perl(Cwd) for package: 4:perl-5.16.3-286.el7.x86_64 --> Processing Dependency: perl(Carp) for package: 4:perl-5.16.3-286.el7.x86_64 --> Processing Dependency: libperl.so()(64bit) for package: 4:perl-5.16.3-286.el7.x86_64 ---> Package tigervnc-server-minimal.x86_64 0:1.3.1-3.el7 will be installed --> Processing Dependency: xorg-x11-xkb-utils for package: tigervnc-server-minimal-1.3.1-3.el7.x86_64 --> Processing Dependency: xkeyboard-config for package: tigervnc-server-minimal-1.3.1-3.el7.x86_64 --> Processing Dependency: mesa-dri-drivers for package: tigervnc-server-minimal-1.3.1-3.el7.x86_64 --> Processing Dependency: libpixman-1.so.0()(64bit) for package: tigervnc-server-minimal-1.3.1-3.el7.x86_64

25 / 136

Page 26: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

--> Processing Dependency: libXfont.so.1()(64bit) for package: tigervnc-server-minimal-1.3.1-3.el7.x86_64 --> Processing Dependency: libXdmcp.so.6()(64bit) for package: tigervnc-server-minimal-1.3.1-3.el7.x86_64 ---> Package xorg-x11-xauth.x86_64 1:1.0.9-1.el7 will be installed --> Processing Dependency: libXmuu.so.1()(64bit) for package: 1:xorg-x11-xauth-1.0.9-1.el7.x86_64 ---> Package xorg-x11-xinit.x86_64 0:1.3.4-1.el7 will be installed --> Processing Dependency: xorg-x11-server-utils for package: xorg-x11-xinit-1.3.4-1.el7.x86_64 --> Running transaction check ---> Package libXdmcp.x86_64 0:1.1.1-6.1.el7 will be installed ---> Package libXfont.x86_64 0:1.5.1-2.el7 will be installed --> Processing Dependency: libfontenc.so.1()(64bit) for package: libXfont-1.5.1-2.el7.x86_64 ---> Package libXi.x86_64 0:1.7.4-2.el7 will be installed ---> Package libXmu.x86_64 0:1.1.2-2.el7 will be installed --> Processing Dependency: libXt.so.6()(64bit) for package: libXmu-1.1.2-2.el7.x86_64 ---> Package mesa-dri-drivers.x86_64 0:10.6.5-3.20150824.el7 will be installed --> Processing Dependency: mesa-filesystem(x86-64) for package: mesa-dri-drivers-10.6.5-3.20150824.el7.x86_64 --> Processing Dependency: libLLVM-3.6-mesa.so(libLLVM-3.6-mesa.so)(64bit) for package: mesa-dri-drivers-10.6.5-3.20150824.el7.x86_64 --> Processing Dependency: libLLVM-3.6-mesa.so()(64bit) for package: mesa-dri-drivers-10.6.5-3.20150824.el7.x86_64 ---> Package perl-Carp.noarch 0:1.26-244.el7 will be installed ---> Package perl-Exporter.noarch 0:5.68-3.el7 will be installed ---> Package perl-File-Path.noarch 0:2.09-2.el7 will be installed ---> Package perl-File-Temp.noarch 0:0.23.01-3.el7 will be installed ---> Package perl-Filter.x86_64 0:1.49-3.el7 will be installed ---> Package perl-Getopt-Long.noarch 0:2.40-2.el7 will be installed --> Processing Dependency: perl(Pod::Usage) >= 1.14 for package: perl-Getopt-Long-2.40-2.el7.noarch --> Processing Dependency: perl(Text::ParseWords) for package: perl-Getopt-Long-2.40-2.el7.noarch ---> Package perl-PathTools.x86_64 0:3.40-5.el7 will be installed

26 / 136

Page 27: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

---> Package perl-Pod-Simple.noarch 1:3.28-4.el7 will be installed --> Processing Dependency: perl(Pod::Escapes) >= 1.04 for package: 1:perl-Pod-Simple-3.28-4.el7.noarch --> Processing Dependency: perl(Encode) for package: 1:perl-Pod-Simple-3.28-4.el7.noarch ---> Package perl-Scalar-List-Utils.x86_64 0:1.27-248.el7 will be installed ---> Package perl-Socket.x86_64 0:2.010-3.el7 will be installed ---> Package perl-Storable.x86_64 0:2.45-3.el7 will be installed ---> Package perl-Time-HiRes.x86_64 4:1.9725-3.el7 will be installed ---> Package perl-Time-Local.noarch 0:1.2300-2.el7 will be installed ---> Package perl-constant.noarch 0:1.27-2.el7 will be installed ---> Package perl-libs.x86_64 4:5.16.3-286.el7 will be installed ---> Package perl-macros.x86_64 4:5.16.3-286.el7 will be installed ---> Package perl-threads.x86_64 0:1.87-4.el7 will be installed ---> Package perl-threads-shared.x86_64 0:1.43-6.el7 will be installed ---> Package pixman.x86_64 0:0.32.6-3.el7 will be installed ---> Package xkeyboard-config.noarch 0:2.14-1.el7 will be installed ---> Package xorg-x11-server-utils.x86_64 0:7.7-14.el7 will be installed --> Processing Dependency: libXxf86misc.so.1()(64bit) for package: xorg-x11-server-utils-7.7-14.el7.x86_64 --> Processing Dependency: libXrandr.so.2()(64bit) for package: xorg-x11-server-utils-7.7-14.el7.x86_64 ---> Package xorg-x11-xkb-utils.x86_64 0:7.7-12.el7 will be installed --> Processing Dependency: libxkbfile.so.1()(64bit) for package: xorg-x11-xkb-utils-7.7-12.el7.x86_64 --> Running transaction check ---> Package libXrandr.x86_64 0:1.4.2-2.el7 will be installed ---> Package libXt.x86_64 0:1.1.4-6.1.el7 will be installed ---> Package libXxf86misc.x86_64 0:1.0.3-7.1.el7 will be installed ---> Package libfontenc.x86_64 0:1.1.2-3.el7 will be installed ---> Package libxkbfile.x86_64 0:1.0.8-5.el7 will be installed

27 / 136

Page 28: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

---> Package mesa-filesystem.x86_64 0:10.6.5-3.20150824.el7 will be installed ---> Package mesa-private-llvm.x86_64 0:3.6.2-2.el7 will be installed ---> Package perl-Encode.x86_64 0:2.51-7.el7 will be installed ---> Package perl-Pod-Escapes.noarch 1:1.04-286.el7 will be installed ---> Package perl-Pod-Usage.noarch 0:1.63-3.el7 will be installed --> Processing Dependency: perl(Pod::Text) >= 3.15 for package: perl-Pod-Usage-1.63-3.el7.noarch --> Processing Dependency: perl-Pod-Perldoc for package: perl-Pod-Usage-1.63-3.el7.noarch ---> Package perl-Text-ParseWords.noarch 0:3.29-4.el7 will be installed --> Running transaction check ---> Package perl-Pod-Perldoc.noarch 0:3.20-4.el7 will be installed --> Processing Dependency: perl(parent) for package: perl-Pod-Perldoc-3.20-4.el7.noarch --> Processing Dependency: perl(HTTP::Tiny) for package: perl-Pod-Perldoc-3.20-4.el7.noarch ---> Package perl-podlators.noarch 0:2.5.1-3.el7 will be installed --> Running transaction check ---> Package perl-HTTP-Tiny.noarch 0:0.033-3.el7 will be installed ---> Package perl-parent.noarch 1:0.225-244.el7 will be installed --> Finished Dependency Resolution Dependencies Resolved ================================================================================================== Package Arch Version Repository Size ================================================================================================== Installing: tigervnc-server x86_64 1.3.1-3.el7 ol7 202 k Installing for dependencies:

28 / 136

Page 29: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

libXdmcp x86_64 1.1.1-6.1.el7 ol7 31 k libXfont x86_64 1.5.1-2.el7 ol7 150 k libXi x86_64 1.7.4-2.el7 ol7 39 k libXmu x86_64 1.1.2-2.el7 ol7 70 k libXrandr x86_64 1.4.2-2.el7 ol7 25 k libXt x86_64 1.1.4-6.1.el7 ol7 167 k libXtst x86_64 1.2.2-2.1.el7 ol7 19 k libXxf86misc x86_64 1.0.3-7.1.el7 ol7 19 k libfontenc x86_64 1.1.2-3.el7 ol7 30 k libxkbfile x86_64 1.0.8-5.el7 ol7 79 k mesa-dri-drivers x86_64 10.6.5-3.20150824.el7 ol7 4.6 M mesa-filesystem x86_64 10.6.5-3.20150824.el7 ol7 22 k mesa-private-llvm x86_64 3.6.2-2.el7 ol7 6.5 M perl x86_64 4:5.16.3-286.el7 ol7 8.0 M perl-Carp noarch 1.26-244.el7 ol7 19 k perl-Encode x86_64 2.51-7.el7 ol7 1.5 M perl-Exporter noarch 5.68-3.el7 ol7 28 k perl-File-Path noarch 2.09-2.el7 ol7 26 k perl-File-Temp noarch 0.23.01-3.el7 ol7 56 k perl-Filter x86_64 1.49-3.el7 ol7 76 k perl-Getopt-Long noarch 2.40-2.el7 ol7 55 k perl-HTTP-Tiny noarch 0.033-3.el7 ol7 38 k perl-PathTools x86_64 3.40-5.el7 ol7 82 k perl-Pod-Escapes noarch 1:1.04-286.el7 ol7 50 k perl-Pod-Perldoc noarch 3.20-4.el7 ol7 86 k perl-Pod-Simple noarch 1:3.28-4.el7 ol7 216 k

29 / 136

Page 30: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

perl-Pod-Usage noarch 1.63-3.el7 ol7 26 k perl-Scalar-List-Utils x86_64 1.27-248.el7 ol7 35 k perl-Socket x86_64 2.010-3.el7 ol7 48 k perl-Storable x86_64 2.45-3.el7 ol7 76 k perl-Text-ParseWords noarch 3.29-4.el7 ol7 13 k perl-Time-HiRes x86_64 4:1.9725-3.el7 ol7 44 k perl-Time-Local noarch 1.2300-2.el7 ol7 24 k perl-constant noarch 1.27-2.el7 ol7 18 k perl-libs x86_64 4:5.16.3-286.el7 ol7 687 k perl-macros x86_64 4:5.16.3-286.el7 ol7 42 k perl-parent noarch 1:0.225-244.el7 ol7 12 k perl-podlators noarch 2.5.1-3.el7 ol7 111 k perl-threads x86_64 1.87-4.el7 ol7 48 k perl-threads-shared x86_64 1.43-6.el7 ol7 38 k pixman x86_64 0.32.6-3.el7 ol7 254 k tigervnc-server-minimal x86_64 1.3.1-3.el7 ol7 1.0 M xkeyboard-config noarch 2.14-1.el7 ol7 758 k xorg-x11-server-utils x86_64 7.7-14.el7 ol7 175 k xorg-x11-xauth x86_64 1:1.0.9-1.el7 ol7 29 k xorg-x11-xinit x86_64 1.3.4-1.el7 ol7 58 k xorg-x11-xkb-utils x86_64 7.7-12.el7 ol7 102 k Transaction Summary ================================================================================================== Install 1 Package (+47 Dependent packages)

30 / 136

Page 31: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

Total download size: 26 M Installed size: 83 M Downloading packages: -------------------------------------------------------------------------------------------------- Total 68 MB/s | 26 MB 00:00:00 Running transaction check Running transaction test Transaction test succeeded Running transaction Installing : libXi-1.7.4-2.el7.x86_64 1/48 Installing : libXt-1.1.4-6.1.el7.x86_64 2/48 Installing : libXmu-1.1.2-2.el7.x86_64 3/48 Installing : 1:xorg-x11-xauth-1.0.9-1.el7.x86_64 4/48 Installing : libXtst-1.2.2-2.1.el7.x86_64 5/48 Installing : 1:perl-parent-0.225-244.el7.noarch 6/48 Installing : perl-HTTP-Tiny-0.033-3.el7.noarch 7/48 Installing : perl-podlators-2.5.1-3.el7.noarch 8/48 Installing : perl-Pod-Perldoc-3.20-4.el7.noarch 9/48 Installing : 1:perl-Pod-Escapes-1.04-286.el7.noarch 10/48 Installing : perl-Text-ParseWords-3.29-4.el7.noarch 11/48 Installing : perl-Encode-2.51-7.el7.x86_64 12/48 Installing : perl-Pod-Usage-1.63-3.el7.noarch 13/48 Installing : 4:perl-libs-5.16.3-286.el7.x86_64 14/48 Installing : 4:perl-macros-5.16.3-286.el7.x86_64 15/48 Installing : perl-Storable-2.45-3.el7.x86_64 16/48 Installing : perl-Exporter-5.68-3.el7.noarch 17/48

31 / 136

Page 32: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

Installing : perl-constant-1.27-2.el7.noarch 18/48 Installing : perl-Time-Local-1.2300-2.el7.noarch 19/48 Installing : perl-Socket-2.010-3.el7.x86_64 20/48 Installing : perl-Carp-1.26-244.el7.noarch 21/48 Installing : 4:perl-Time-HiRes-1.9725-3.el7.x86_64 22/48 Installing : perl-PathTools-3.40-5.el7.x86_64 23/48 Installing : perl-Scalar-List-Utils-1.27-248.el7.x86_64 24/48 Installing : perl-File-Temp-0.23.01-3.el7.noarch 25/48 Installing : perl-File-Path-2.09-2.el7.noarch 26/48 Installing : perl-threads-shared-1.43-6.el7.x86_64 27/48 Installing : perl-threads-1.87-4.el7.x86_64 28/48 Installing : perl-Filter-1.49-3.el7.x86_64 29/48 Installing : 1:perl-Pod-Simple-3.28-4.el7.noarch 30/48 Installing : perl-Getopt-Long-2.40-2.el7.noarch 31/48 Installing : 4:perl-5.16.3-286.el7.x86_64 32/48 Installing : libfontenc-1.1.2-3.el7.x86_64 33/48 Installing : libXfont-1.5.1-2.el7.x86_64 34/48 Installing : mesa-private-llvm-3.6.2-2.el7.x86_64 35/48 Installing : libxkbfile-1.0.8-5.el7.x86_64 36/48 Installing : xorg-x11-xkb-utils-7.7-12.el7.x86_64 37/48 Installing : xkeyboard-config-2.14-1.el7.noarch 38/48 Installing : mesa-filesystem-10.6.5-3.20150824.el7.x86_64 39/48 Installing : mesa-dri-drivers-10.6.5-3.20150824.el7.x86_64 40/48 Installing : libXdmcp-1.1.1-6.1.el7.x86_64 41/48 Installing : libXrandr-1.4.2-2.el7.x86_64 42/48 Installing : pixman-0.32.6-3.el7.x86_64 43/48

32 / 136

Page 33: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

Installing : tigervnc-server-minimal-1.3.1-3.el7.x86_64 44/48 Installing : libXxf86misc-1.0.3-7.1.el7.x86_64 45/48 Installing : xorg-x11-server-utils-7.7-14.el7.x86_64 46/48 Installing : xorg-x11-xinit-1.3.4-1.el7.x86_64 47/48 Installing : tigervnc-server-1.3.1-3.el7.x86_64 48/48 Verifying : perl-HTTP-Tiny-0.033-3.el7.noarch 1/48 Verifying : libXxf86misc-1.0.3-7.1.el7.x86_64 2/48 Verifying : perl-threads-shared-1.43-6.el7.x86_64 3/48 Verifying : perl-Storable-2.45-3.el7.x86_64 4/48 Verifying : pixman-0.32.6-3.el7.x86_64 5/48 Verifying : perl-Exporter-5.68-3.el7.noarch 6/48 Verifying : perl-constant-1.27-2.el7.noarch 7/48 Verifying : perl-PathTools-3.40-5.el7.x86_64 8/48 Verifying : xorg-x11-xkb-utils-7.7-12.el7.x86_64 9/48 Verifying : 4:perl-libs-5.16.3-286.el7.x86_64 10/48 Verifying : 4:perl-macros-5.16.3-286.el7.x86_64 11/48 Verifying : tigervnc-server-minimal-1.3.1-3.el7.x86_64 12/48 Verifying : 1:perl-parent-0.225-244.el7.noarch 13/48 Verifying : libXrandr-1.4.2-2.el7.x86_64 14/48 Verifying : tigervnc-server-1.3.1-3.el7.x86_64 15/48 Verifying : mesa-dri-drivers-10.6.5-3.20150824.el7.x86_64 16/48 Verifying : 4:perl-5.16.3-286.el7.x86_64 17/48 Verifying : xorg-x11-xinit-1.3.4-1.el7.x86_64 18/48 Verifying : perl-File-Temp-0.23.01-3.el7.noarch 19/48 Verifying : 1:perl-Pod-Simple-3.28-4.el7.noarch 20/48 Verifying : perl-Time-Local-1.2300-2.el7.noarch 21/48

33 / 136

Page 34: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

Verifying : xorg-x11-server-utils-7.7-14.el7.x86_64 22/48 Verifying : perl-Pod-Perldoc-3.20-4.el7.noarch 23/48 Verifying : libXdmcp-1.1.1-6.1.el7.x86_64 24/48 Verifying : perl-Socket-2.010-3.el7.x86_64 25/48 Verifying : mesa-filesystem-10.6.5-3.20150824.el7.x86_64 26/48 Verifying : perl-Carp-1.26-244.el7.noarch 27/48 Verifying : libXtst-1.2.2-2.1.el7.x86_64 28/48 Verifying : xkeyboard-config-2.14-1.el7.noarch 29/48 Verifying : libXfont-1.5.1-2.el7.x86_64 30/48 Verifying : 4:perl-Time-HiRes-1.9725-3.el7.x86_64 31/48 Verifying : libXmu-1.1.2-2.el7.x86_64 32/48 Verifying : perl-Scalar-List-Utils-1.27-248.el7.x86_64 33/48 Verifying : 1:perl-Pod-Escapes-1.04-286.el7.noarch 34/48 Verifying : perl-Pod-Usage-1.63-3.el7.noarch 35/48 Verifying : 1:xorg-x11-xauth-1.0.9-1.el7.x86_64 36/48 Verifying : libXt-1.1.4-6.1.el7.x86_64 37/48 Verifying : libxkbfile-1.0.8-5.el7.x86_64 38/48 Verifying : perl-Encode-2.51-7.el7.x86_64 39/48 Verifying : libXi-1.7.4-2.el7.x86_64 40/48 Verifying : perl-podlators-2.5.1-3.el7.noarch 41/48 Verifying : perl-Getopt-Long-2.40-2.el7.noarch 42/48 Verifying : mesa-private-llvm-3.6.2-2.el7.x86_64 43/48 Verifying : perl-File-Path-2.09-2.el7.noarch 44/48 Verifying : libfontenc-1.1.2-3.el7.x86_64 45/48 Verifying : perl-threads-1.87-4.el7.x86_64 46/48 Verifying : perl-Filter-1.49-3.el7.x86_64 47/48

34 / 136

Page 35: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

Verifying : perl-Text-ParseWords-3.29-4.el7.noarch 48/48 Installed: tigervnc-server.x86_64 0:1.3.1-3.el7 Dependency Installed: libXdmcp.x86_64 0:1.1.1-6.1.el7 libXfont.x86_64 0:1.5.1-2.el7 libXi.x86_64 0:1.7.4-2.el7 libXmu.x86_64 0:1.1.2-2.el7 libXrandr.x86_64 0:1.4.2-2.el7 libXt.x86_64 0:1.1.4-6.1.el7 libXtst.x86_64 0:1.2.2-2.1.el7 libXxf86misc.x86_64 0:1.0.3-7.1.el7 libfontenc.x86_64 0:1.1.2-3.el7 libxkbfile.x86_64 0:1.0.8-5.el7 mesa-dri-drivers.x86_64 0:10.6.5-3.20150824.el7 mesa-filesystem.x86_64 0:10.6.5-3.20150824.el7 mesa-private-llvm.x86_64 0:3.6.2-2.el7 perl.x86_64 4:5.16.3-286.el7 perl-Carp.noarch 0:1.26-244.el7 perl-Encode.x86_64 0:2.51-7.el7 perl-Exporter.noarch 0:5.68-3.el7 perl-File-Path.noarch 0:2.09-2.el7 perl-File-Temp.noarch 0:0.23.01-3.el7 perl-Filter.x86_64 0:1.49-3.el7 perl-Getopt-Long.noarch 0:2.40-2.el7 perl-HTTP-Tiny.noarch 0:0.033-3.el7 perl-PathTools.x86_64 0:3.40-5.el7 perl-Pod-Escapes.noarch 1:1.04-286.el7 perl-Pod-Perldoc.noarch 0:3.20-4.el7 perl-Pod-Simple.noarch 1:3.28-4.el7 perl-Pod-Usage.noarch 0:1.63-3.el7 perl-Scalar-List-Utils.x86_64 0:1.27-248.el7 perl-Socket.x86_64 0:2.010-3.el7 perl-Storable.x86_64 0:2.45-3.el7 perl-Text-ParseWords.noarch 0:3.29-4.el7 perl-Time-HiRes.x86_64 4:1.9725-3.el7 perl-Time-Local.noarch 0:1.2300-2.el7 perl-constant.noarch 0:1.27-2.el7 perl-libs.x86_64 4:5.16.3-286.el7 perl-macros.x86_64 4:5.16.3-286.el7 perl-parent.noarch 1:0.225-244.el7 perl-podlators.noarch 0:2.5.1-3.el7 perl-threads.x86_64 0:1.87-4.el7 perl-threads-shared.x86_64 0:1.43-6.el7

35 / 136

Page 36: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

pixman.x86_64 0:0.32.6-3.el7 tigervnc-server-minimal.x86_64 0:1.3.1-3.el7 xkeyboard-config.noarch 0:2.14-1.el7 xorg-x11-server-utils.x86_64 0:7.7-14.el7 xorg-x11-xauth.x86_64 1:1.0.9-1.el7 xorg-x11-xinit.x86_64 0:1.3.4-1.el7 xorg-x11-xkb-utils.x86_64 0:7.7-12.el7 Complete!

8. 配置 VNC

[root@adccrac1 ~]# vncserver You will require a password to access your desktops. Password: <<== 输入 adccrac Verify: <<== 输入 adccrac xauth: file /root/.Xauthority does not exist New 'adccrac1:1 (root)' desktop is adccrac1:1 Creating default startup script /root/.vnc/xstartup Starting applications specified in /root/.vnc/xstartup Log file is /root/.vnc/adccrac1:1.log [root@adccrac1 ~]# vncserver -list TigerVNC server sessions:

36 / 136

Page 37: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

X DISPLAY # PROCESS ID :1 16959 [root@adccrac1 ~]# ps -ef | grep vnc root 16959 1 0 12:41 ? 00:00:00 /usr/bin/Xvnc :1 -desktop adccrac1:1 (root) -auth /root/.Xauthority -geometry 1024x768 -rfbwait 30000 -rfbauth /root/.vnc/passwd -rfbport 5901 -fp catalogue:/etc/X11/fontpath.d -pn root 16964 1 0 12:41 ? 00:00:00 /usr/bin/vncconfig -iconic root 17509 17470 0 12:44 pts/0 00:00:00 grep --color=auto vnc [root@adccrac1 ~]# vncserver -kill :1 Killing Xvnc process ID 16959 [root@adccrac1 ~]# [root@adccrac1 ~]# vncserver :1 New 'adccrac1:1 (root)' desktop is adccrac1:1 Starting applications specified in /root/.vnc/xstartup Log file is /root/.vnc/adccrac1:1.log [root@adccrac1 ~]# vncserver -list TigerVNC server sessions: X DISPLAY # PROCESS ID :1 17533

37 / 136

Page 38: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

之后就可以使用 vncviewer 命令登录 VNC 桌面,不过由于没有安装图形界面,里面的命令行工具没有,最后还是建议安装图形界面,只是开机只启

动命令行界面就可以 将步骤 5 和 6 的操作顺序调换了一下,现在是先安装图形界面再安装 VNC,否则再配置完 VNC 以后,登录 VNC 弹不出图形界面,

应该是没有预先安装好图形界面的原因。

9. 操作系统的磁盘和 ASM 共享磁盘容量规划

操作系统磁盘: /dev/sda 共 200g, 关于如何分区,在安装操作系统时 选择自动分区选项 ASM 共享磁盘: (在 VitualBox 里的磁盘大小必须是固定的,否则无法从"正常"模式变为"共享"模式) /dev/sdb OCRVOTE1 2g /dev/sdc OCRVOTE2 2g /dev/sdd OCRVOTE3 2g /dev/sde DATA 15g /dev/sdf BACK 4g /dev/sdg ARCH 4g

10. 用户 root 的密码和两节点数据库 REDO 个数

adccrac1 root 密码: adccrac adccrac2 root 密码: adccrac REDO LOG 的大小设为 256M 共设 6 组

38 / 136

Page 39: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

线程 1 是 3 组 线程 2 也是 3 组

11. 停以下服务 (两节点)

systemctl stop NetworkManager.service systemctl disable NetworkManager.service systemctl stop firewalld.service systemctl disable firewalld.service --没有 ntpd 的软件包 [root@adccrac1 ~]# rpm -qa | grep ntp fontpackages-filesystem-1.44-8.el7.noarch ntpdate-4.2.6p5-22.el7.x86_64 python-ntplib-0.3.2-1.el7.noarch CentOS7.2 默认使用 firewalld; iptables 默认无法被 systemctl 控制, 需要安装 iptables-services、iptables-devel 这两个依赖包 [root@adccrac1 ~]# rpm -qa | grep iptables iptables-1.4.21-16.el7.x86_64

12. 禁用 SELinux (两节点)

vi /etc/sysconfig/selinux

39 / 136

Page 40: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

SELINUX=disabled 然后重启主机

13. 创建用户和组 (两节点)

groupadd -g 1100 oinstall groupadd -g 1200 dba groupadd -g 1300 oper groupadd -g 2100 asmadmin groupadd -g 2200 asmdba groupadd -g 2300 asmoper useradd -u 777 -g oinstall -G dba,oper,asmadmin,asmdba -d /home/oracle -s /bin/bash -c "Oracle Software Owner" oracle echo "oracle" | passwd --stdin oracle useradd -u 888 -g oinstall -G dba,asmadmin,asmdba,asmoper -d /home/grid -s /bin/bash -c "grid Infrastructure Owner" grid echo "grid" | passwd --stdin grid

14. 配置 grid 用户和 oracle 用户的环境变量(两节点)

节点一, su - oracle vim .bash_profile export ORACLE_BASE=/app/oracle export ORACLE_HOME=$ORACLE_BASE/product/11.2.0/db_1

40 / 136

Page 41: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

export ORACLE_SID=racdb1 export LD_LIBRARY_PATH=$ORACLE_HOME/lib:$LD_LIBRARY_PATH export PATH=$ORACLE_HOME/bin:$PATH export LANG=en_US.UTF-8 export DISPLAY=192.168.210.1:0.0 su - oracle vim .bash_profile export ORACLE_BASE=/app/oracle export ORACLE_HOME=$ORACLE_BASE/product/11.2.0/db_1 export ORACLE_SID=racdb2 export LD_LIBRARY_PATH=$ORACLE_HOME/lib:$LD_LIBRARY_PATH export PATH=$ORACLE_HOME/bin:$PATH export LANG=en_US.UTF-8 export DISPLAY=192.168.210.1:0.0 保存退出,用 source .bash_profile 重读一下配置文件 节点二, su - grid vim .bash_profile export ORACLE_BASE=/app/grid export ORACLE_HOME=/app/11.2.0/grid export ORACLE_SID=+ASM1 export LD_LIBRARY_PATH=$ORACLE_HOME/lib:$LD_LIBRARY_PATH export PATH=$ORACLE_HOME/bin:$PATH export LANG=en_US.UTF-8

41 / 136

Page 42: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

export DISPLAY=192.168.210.1:0.0 su - grid vim .bash_profile export ORACLE_BASE=/app/grid export ORACLE_HOME=/app/11.2.0/grid export ORACLE_SID=+ASM2 export LD_LIBRARY_PATH=$ORACLE_HOME/lib:$LD_LIBRARY_PATH export PATH=$ORACLE_HOME/bin:$PATH export LANG=en_US.UTF-8 export DISPLAY=192.168.210.1:0.0 保存退出,用 source .bash_profile 重读一下配置文件

15. 创建所需的目录及赋予相应的权限 (两节点)

mkdir -p /app/grid mkdir -p /app/11.2.0/grid mkdir -p /app/oracle chown -R oracle:oinstall /app chown -R grid:oinstall /app/grid chown -R grid:oinstall /app/11.2.0 chmod -R 775 /app

42 / 136

Page 43: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

16. 编辑/etc/security/limits.conf 文件,增加如下内容 (两节点)

oracle soft nproc 2047 oracle hard nproc 16384 oracle soft nofile 1024 oracle hard nofile 65536 grid soft nproc 2047 grid hard nproc 16384 grid soft nofile 1024 grid hard nofile 65536

17. 编辑/etc/pam.d/login 文件,增加如下内容 (两节点)

session required /lib64/security/pam_limits.so session required pam_limits.so

18. 编辑/etc/profile 文件,添加如下参数 (两节点)

if [ $USER = "oracle" ]||[ $USER = "grid" ]; then if [ $SHELL = "/bin/ksh" ]; then ulimit -p 16384 ulimit -n 65536 else

43 / 136

Page 44: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

ulimit -u 16384 -n 65536 fi fi 保存退出,用 source /etc/profile 重读一下配置文件

19. 编辑 /etc/sysctl.conf 文件 ,增加下列参数 (两节点 ) [Oracle Linux 7.2 下为这个文件 # vi

/usr/lib/sysctl.d/00-system.conf]

就在文件/etc/sysctl.conf 的行尾 增加就可以,这样到最后安装形界面的预检测时不会出现内核参数的警告提示;如果将下面的参数写到文件

/usr/lib/sysctl.d/00-system.conf 就会有警告提示。 kernel.msgmnb = 65536 kernel.msgmax = 65536 kernel.shmmax = 4294967295 kernel.shmall = 2097152 kernel.shmmni = 4096 fs.aio-max-nr = 1048576 fs.file-max = 6815744 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

44 / 136

Page 45: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

保存退出,之后别忘了用 sysctl -p 命令使参数生效 [Oracle Linux 7.2 下 # sysctl -p /usr/lib/sysctl.d/00-system.conf]

20. 配置 SSH 互信,在图形界面点击设置,此步不用命令

21. 将 grid 和 oracle 的软件安装包 上传到 节点一 的 /software 目录

[root@adccrac1 ~]# mkdir /software [root@adccrac1 ~]# cd /software/ [root@adccrac1 software]# ls -lrht total 3.5G -rw-r--r-- 1 root root 1.1G Aug 15 09:50 p13390677_112040_Linux-x86-64_2of7.zip -rw-r--r-- 1 root root 1.3G Aug 15 09:51 p13390677_112040_Linux-x86-64_1of7.zip -rw-r--r-- 1 root root 1.2G Aug 15 09:53 p13390677_112040_Linux-x86-64_3of7.zip 解压软件包 [root@adccrac1 ~]# chown -R oracle:oinstall /software/ [root@adccrac1 ~]# su - grid Last login: Tue Aug 14 15:06:22 CST 2018 on pts/0 [grid@adccrac1 ~]$ cp /software/p13390677_112040_Linux-x86-64_3of7.zip ./ [grid@adccrac1 ~]$ unzip p13390677_112040_Linux-x86-64_3of7.zip [root@adccrac1 ~]# su - oracle Last login: Wed Aug 15 12:24:47 CST 2018 on pts/0

45 / 136

Page 46: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

[oracle@adccrac1 ~]$ cp /software/p13390677_112040_Linux-x86-64_1of7.zip ./ [oracle@adccrac1 ~]$ cp /software/p13390677_112040_Linux-x86-64_2of7.zip ./ [oracle@adccrac1 ~]$ ls p13390677_112040_Linux-x86-64_1of7.zip p13390677_112040_Linux-x86-64_2of7.zip [oracle@adccrac1 ~]$ unzip p13390677_112040_Linux-x86-64_1of7.zip; unzip p13390677_112040_Linux-x86-64_2of7.zip

22. 用 YUM 源安装 RAC 必需的 RPM 软件包

yum install -y binutils yum install -y compat-libcap1 yum install -y compat-libstdc++-33-3.2.3-72.el7.i686 yum install -y compat-libstdc++-33 yum install -y elfutils-libelf-devel yum install -y gcc yum install -y gcc-c++ yum install -y glibc-2.17-105.0.1.el7.i686 yum install -y glibc yum install -y glibc-devel-2.17-105.0.1.el7.i686 yum install -y glibc-devel yum install -y ksh yum install -y libaio-0.3.109-13.el7.i686 yum install -y libaio yum install -y libaio-devel-0.3.109-13.el7.i686 yum install -y libaio-devel yum install -y libgcc-4.8.5-4.el7.i686

46 / 136

Page 47: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

yum install -y libgcc yum install -y libstdc++-4.8.5-4.el7.i686 yum install -y libstdc++ yum install -y libstdc++-devel-4.8.5-4.el7.i686 yum install -y libstdc++-devel yum install -y libXi-1.7.4-2.el7.i686 yum install -y libXi yum install -y libXtst-1.2.2-2.1.el7.i686 yum install -y libXtst yum install -y make yum install -y sysstat yum install -y unixODBC yum install -y unixODBC-2.3.1-11.el7.i686 yum install -y unixODBC-devel yum install -y unixODBC-devel-2.3.1-11.el7.i686 yum remove –y ksh 上传这个 RPM 软件包 pdksh-5.2.14-37.el5.x86_64.rpm 到 /software rpm –ivh /software/ pdksh-5.2.14-37.el5.x86_64.rpm 切换到 grid 用户,进入 grid/rpm 目录,有一个 RPM 文件 cvuqdisk-1.0.9-1.rpm,不完全切换到 root 用户进行安装 [grid@adccrac1 ~]$ cd grid/ [grid@adccrac1 grid]$ ls

47 / 136

Page 48: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

install readme.html response rpm runcluvfy.sh runInstaller sshsetup stage welcome.html [grid@adccrac1 grid]$ cd rpm [grid@adccrac1 rpm]$ ls cvuqdisk-1.0.9-1.rpm [grid@adccrac1 rpm]$ su Password: [root@adccrac1 rpm]# rpm -ivh cvuqdisk-1.0.9-1.rpm Preparing... ################################# [100%] Using default group oinstall to install package Updating / installing... 1:cvuqdisk-1.0.9-1 ################################# [100%]

23. 用 VirutalBox 克隆 adccrac1 为另一台主机 adccrac2,选 Full Clone,并选择“重新初始化两块网

卡的 MAC 地址”

之后启动 adccrac2, 更改主机名为 adccrac2, [root@adccrac1 ~]# hostnamectl Static hostname: adccrac1 Icon name: computer-vm Chassis: vm Machine ID: cd4b43fc434a4b949feedc2c31f0da3f Boot ID: e977d29e2a764a80b14a5aa68f18627d Virtualization: kvm Operating System: Oracle Linux Server 7.2

48 / 136

Page 49: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

CPE OS Name: cpe:/o:oracle:linux:7:2:server Kernel: Linux 3.8.13-98.7.1.el7uek.x86_64 Architecture: x86-64 [root@adccrac1 ~]# hostnamectl status Static hostname: adccrac1 Icon name: computer-vm Chassis: vm Machine ID: cd4b43fc434a4b949feedc2c31f0da3f Boot ID: e977d29e2a764a80b14a5aa68f18627d Virtualization: kvm Operating System: Oracle Linux Server 7.2 CPE OS Name: cpe:/o:oracle:linux:7:2:server Kernel: Linux 3.8.13-98.7.1.el7uek.x86_64 Architecture: x86-64 [root@adccrac1 ~]# hostnamectl set-hostname adccrac2 --static [root@adccrac1 ~]# hostname adccrac2 用 Xshell 重新连接,发现主机名已变为 adccrac2 Last login: Wed Aug 15 09:04:03 2018 from 192.168.210.1 [root@adccrac2 ~]# 更改网卡 enp0s3 和 enp0s8 的 IP 地址 [root@adccrac1 ~]# cat /etc/sysconfig/network-scripts/ifcfg-enp0s3

49 / 136

Page 50: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

TYPE=Ethernet BOOTPROTO=none DEFROUTE=yes IPV4_FAILURE_FATAL=no IPV6INIT=yes IPV6_AUTOCONF=yes IPV6_DEFROUTE=yes IPV6_FAILURE_FATAL=no NAME=enp0s3 UUID=f26a2d18-32d6-4a17-88de-68127c860b82 DEVICE=enp0s3 ONBOOT=yes IPADDR=192.168.210.62 <<== 改为 62 PREFIX=24 GATEWAY=192.168.210.1 IPV6_PEERDNS=yes IPV6_PEERROUTES=yes IPV6_PRIVACY=no [root@adccrac1 ~]# cat /etc/sysconfig/network-scripts/ifcfg-enp0s8 TYPE=Ethernet BOOTPROTO=none DEFROUTE=yes IPV4_FAILURE_FATAL=no IPV6INIT=yes IPV6_AUTOCONF=yes

50 / 136

Page 51: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

IPV6_DEFROUTE=yes IPV6_FAILURE_FATAL=no NAME=enp0s8 UUID=973d91e4-913d-47ec-b117-9bc36190cd65 DEVICE=enp0s8 ONBOOT=yes IPADDR=10.10.210.62 <<== 改为 62 PREFIX=24 IPV6_PEERDNS=yes IPV6_PEERROUTES=yes IPV6_PRIVACY=no 重启网络服务,使配置生效 [root@adccrac1 ~]# systemctl restart network.service [root@adccrac1 ~]# [root@adccrac1 ~]# systemctl status network.service ?.network.service - LSB: Bring up/down networking Loaded: loaded (/etc/rc.d/init.d/network) Active: active (exited) since Wed 2018-08-15 09:06:32 CST; 8s ago Docs: man:systemd-sysv-generator(8) Process: 3535 ExecStop=/etc/rc.d/init.d/network stop (code=exited, status=0/SUCCESS) Process: 3781 ExecStart=/etc/rc.d/init.d/network start (code=exited, status=0/SUCCESS) Aug 15 09:06:27 adccrac1 systemd[1]: Starting LSB: Bring up/down networking... Aug 15 09:06:27 adccrac1 network[3781]: Bringing up loopback interface: [ OK ]

51 / 136

Page 52: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

Aug 15 09:06:29 adccrac1 network[3781]: Bringing up interface enp0s3: [ OK ] Aug 15 09:06:32 adccrac1 network[3781]: Bringing up interface enp0s8: [ OK ] Aug 15 09:06:32 adccrac1 systemd[1]: Started LSB: Bring up/down networking. [root@adccrac1 ~]# ifconfig enp0s3 enp0s3: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500 inet 192.168.210.62 netmask 255.255.255.0 broadcast 192.168.210.255 inet6 fe80::a00:27ff:fe25:e0f1 prefixlen 64 scopeid 0x20<link> ether 08:00:27:25:e0:f1 txqueuelen 1000 (Ethernet) RX packets 394 bytes 39968 (39.0 KiB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 279 bytes 37006 (36.1 KiB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0 [root@adccrac1 ~]# ifconfig enp0s8 enp0s8: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500 inet 10.10.210.62 netmask 255.255.255.0 broadcast 10.10.210.255 inet6 fe80::a00:27ff:fe69:ed64 prefixlen 64 scopeid 0x20<link> ether 08:00:27:69:ed:64 txqueuelen 1000 (Ethernet) RX packets 18 bytes 2830 (2.7 KiB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 64 bytes 10515 (10.2 KiB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0 更改用户 oracle 和 grid 的 .bash_profile 中的 实例名为节点二的名称

52 / 136

Page 53: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

[root@adccrac2 ~]# su - oracle Last login: Tue Aug 14 15:05:33 CST 2018 on pts/0 [oracle@adccrac2 ~]$ [oracle@adccrac2 ~]$ vi .bash_profile ...... export ORACLE_SID=racdb2 <<== 改为 racdb2 [oracle@adccrac2 ~]$ [oracle@adccrac2 ~]$ source .bash_profile [oracle@adccrac2 ~]$ exit logout [root@adccrac2 ~]# [root@adccrac2 ~]# su - grid Last login: Tue Aug 14 15:06:22 CST 2018 on pts/0 [grid@adccrac2 ~]$ [grid@adccrac2 ~]$ vi .bash_profile ...... export ORACLE_SID=+ASM2 <<== 改为 +ASM2 [grid@adccrac2 ~]$ [grid@adccrac2 ~]$ source .bash_profile

24. 关闭两节点的主机,在节点一上添加 6 块磁盘并将磁盘类型设置为“可共享”,在节点二上依次

添加节点一刚刚新增的磁盘,最后将 6 块磁盘设置为共享模式,并开启两个节点的主机

OCRVOTE1 2g

53 / 136

Page 54: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

OCRVOTE2 2g OCRVOTE3 2g DATA 15g BACK 4g ARCH 4g

25. 用 UDEV 方式绑定磁盘 (两节点)

[root@adccrac1 ~]# for disk in `ls /dev/sd*` > do > echo $disk > /usr/lib/udev/scsi_id --whitelisted --replace-whitespace --device=$disk > done /dev/sdb 1ATA_VBOX_HARDDISK_VB8423dba6-263dd03e /dev/sdc 1ATA_VBOX_HARDDISK_VB4163a8df-b665ad13 /dev/sdd 1ATA_VBOX_HARDDISK_VB1d5f72c3-023cb880 /dev/sde 1ATA_VBOX_HARDDISK_VBd0feeeb6-de5ed8a4 /dev/sdf 1ATA_VBOX_HARDDISK_VBd2542fa2-9f0c4e98 /dev/sdg 1ATA_VBOX_HARDDISK_VBa0072bca-68bf2cbb

54 / 136

Page 55: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

# vi /etc/udev/rules.d/99-oracle-asmdevices.rules KERNEL=="sd*", SUBSYSTEM=="block", PROGRAM=="/usr/lib/udev/scsi_id --whitelisted --replace-whitespace --device=/dev/$name", RESULT=="1ATA_VBOX_HARDDISK_VB8423dba6-263dd03e", SYMLINK+="asm-ocrvote1", OWNER="grid", GROUP="asmadmin", MODE="0660" KERNEL=="sd*", SUBSYSTEM=="block", PROGRAM=="/usr/lib/udev/scsi_id --whitelisted --replace-whitespace --device=/dev/$name", RESULT=="1ATA_VBOX_HARDDISK_VB4163a8df-b665ad13", SYMLINK+="asm-ocrvote2", OWNER="grid", GROUP="asmadmin", MODE="0660" KERNEL=="sd*", SUBSYSTEM=="block", PROGRAM=="/usr/lib/udev/scsi_id --whitelisted --replace-whitespace --device=/dev/$name", RESULT=="1ATA_VBOX_HARDDISK_VB1d5f72c3-023cb880", SYMLINK+="asm-ocrvote3", OWNER="grid", GROUP="asmadmin", MODE="0660" KERNEL=="sd*", SUBSYSTEM=="block", PROGRAM=="/usr/lib/udev/scsi_id --whitelisted --replace-whitespace --device=/dev/$name", RESULT=="1ATA_VBOX_HARDDISK_VBd0feeeb6-de5ed8a4", SYMLINK+="asm-data", OWNER="grid", GROUP="asmadmin", MODE="0660" KERNEL=="sd*", SUBSYSTEM=="block", PROGRAM=="/usr/lib/udev/scsi_id --whitelisted --replace-whitespace --device=/dev/$name", RESULT=="1ATA_VBOX_HARDDISK_VBd2542fa2-9f0c4e98", SYMLINK+="asm-back", OWNER="grid", GROUP="asmadmin", MODE="0660" KERNEL=="sd*", SUBSYSTEM=="block", PROGRAM=="/usr/lib/udev/scsi_id --whitelisted --replace-whitespace --device=/dev/$name", RESULT=="1ATA_VBOX_HARDDISK_VBa0072bca-68bf2cbb", SYMLINK+="asm-arch", OWNER="grid", GROUP="asmadmin", MODE="0660" 重启 UDEV 服务 # udevadm control --reload systemctl restart systemd-udev-trigger.service 已整合到 UDEV 后台服务中了. systemd-udev-settle.service loaded active exited udev Wait for Complete Device Initialization systemd-udev-trigger.service loaded active exited udev Coldplug all Devices systemd-udevd.service loaded active running udev Kernel Device Manager systemd-udevd-control.socket loaded active running udev Control Socket systemd-udevd-kernel.socket loaded active running udev Kernel Socket 查看组和权限 [root@adccrac1 ~]# ls -ld /dev/asm-*

55 / 136

Page 56: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

ls: cannot access /dev/asm-*: No such file or directory [root@adccrac1 ~]# systemctl restart systemd-udev-trigger.service [root@adccrac1 ~]# ls -ld /dev/asm-* lrwxrwxrwx 1 root root 3 Aug 15 16:38 /dev/asm-arch -> sdg lrwxrwxrwx 1 root root 3 Aug 15 16:38 /dev/asm-back -> sdf lrwxrwxrwx 1 root root 3 Aug 15 16:38 /dev/asm-data -> sde lrwxrwxrwx 1 root root 3 Aug 15 16:38 /dev/asm-ocrvote1 -> sdb lrwxrwxrwx 1 root root 3 Aug 15 16:38 /dev/asm-ocrvote2 -> sdc lrwxrwxrwx 1 root root 3 Aug 15 16:38 /dev/asm-ocrvote3 -> sdd [root@adccrac1 ~]# ls -ld /dev/sd* brw-rw---- 1 root disk 8, 0 Aug 15 16:38 /dev/sda brw-rw---- 1 root disk 8, 1 Aug 15 16:38 /dev/sda1 brw-rw---- 1 root disk 8, 2 Aug 15 16:38 /dev/sda2 brw-rw---- 1 grid asmadmin 8, 16 Aug 15 16:38 /dev/sdb brw-rw---- 1 grid asmadmin 8, 32 Aug 15 16:38 /dev/sdc brw-rw---- 1 grid asmadmin 8, 48 Aug 15 16:38 /dev/sdd brw-rw---- 1 grid asmadmin 8, 64 Aug 15 16:38 /dev/sde brw-rw---- 1 grid asmadmin 8, 80 Aug 15 16:38 /dev/sdf brw-rw---- 1 grid asmadmin 8, 96 Aug 15 16:38 /dev/sdg

26. 对 grid 软件打 PSU 补丁 19404309

[grid@adccrac1 ~]$ unzip /software/p19404309_112040_Linux-x86-64.zip -d /tmp/

56 / 136

Page 57: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

Archive: /software/p19404309_112040_Linux-x86-64.zip creating: /tmp/b19404309/ creating: /tmp/b19404309/client/ inflating: /tmp/b19404309/client/cvu_prereq.xml inflating: /tmp/b19404309/client/oracle.client_InstantClient.xml creating: /tmp/b19404309/grid/ inflating: /tmp/b19404309/grid/cvu_prereq.xml creating: /tmp/b19404309/examples/ inflating: /tmp/b19404309/examples/cvu_prereq.xml creating: /tmp/b19404309/database/ inflating: /tmp/b19404309/database/cvu_prereq.xml inflating: /tmp/b19404309/README_b19404309.txt inflating: /tmp/PatchSearch.xml [grid@adccrac1 ~]$ cp /tmp/b19404309/grid/cvu_prereq.xml ./grid/stage/cvu/ [grid@adccrac1 ~]$ cd ./grid/stage/cvu/ [grid@adccrac1 cvu]$ ls -lrht total 48K drwxr-xr-x 5 grid oinstall 44 Aug 26 2013 cv -rwxr-xr-x 1 grid oinstall 45K Aug 22 10:36 cvu_prereq.xml

27. 在 节点一 打开 VNC 的图形桌面

[root@adccrac1 ~]# vncserver –kill :1 [root@adccrac1 ~]# vncserver :1 [root@adccrac1 ~]# vi .bash_profile 在行尾增加

57 / 136

Page 58: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

export DISPLAY=192.168.210.1:0.0 保存退出 [root@adccrac1 ~]# source .bash_profile [root@adccrac1 ~]# vncviewer TigerVNC Viewer 64-bit v1.3.1 (20151119) Built on Nov 19 2015 at 22:10:59 Copyright (C) 1999-2011 TigerVNC Team and many others (see README.txt) See http://www.tigervnc.org for information on TigerVNC.

28. 由于存在 BUG 18370031,安装 Oracle Grid Infrastructure 软件,后面打完补丁后再配置 GI

在 Oracle 的官方文档 https://docs.oracle.com/cd/E11882_01/relnotes.112/e23558/toc.htm#CJADCGGG 中的 7.2.3 有如下的一段描述:

7.2.3 Oracle Grid Infrastructure Installation Issue

During the Oracle Grid Infrastructure installation, you must apply patch 18370031 before configuring the software that is installed. The timing of applying the patch is important and is described in detail in the Note 1951613.1 on My Oracle Support. This patch ensures that the clusterware stack is configured to use systemd for clusterware processes, as Oracle Linux 7 uses systemd for all services.

This issue is tracked with Oracle bug 18370031, which was logged for release 12.1.0.2, but the patch is for release 11.2.0.4.

所以,在步骤 27 当中的 VNC 桌面窗口 打开一个 terminal 窗口,切换到 grid 用户 执行下面的命令 [grid@adccrac1 grid]$ ./runInstaller Starting Oracle Universal Installer...

58 / 136

Page 59: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

Checking Temp space: must be greater than 120 MB. Actual 39216 MB Passed Checking swap space: must be greater than 150 MB. Actual 4991 MB Passed Checking monitor: must be configured to display at least 256 colors. Actual 16777216 Passed Preparing to launch Oracle Universal Installer from /tmp/OraInstall2018-08-22_10-43-34AM. Please wait ...[grid@adccrac1 grid]$ 弹出图形界面 在第二个界面时,选择第四个选项,只安装 GI 软件 最后弹出 执行 2 个脚本的对话框 这里,实际上 grid 软件只安装到节点 1,只在节点 1 上执行: # /app/oraInventory/orainstRoot.sh # /app/11.2.0/grid/root.sh [root@adccrac1 ~]# /app/oraInventory/orainstRoot.sh Changing permissions of /app/oraInventory. Adding read,write permissions for group. Removing read,write,execute permissions for world. Changing groupname of /app/oraInventory to oinstall. The execution of the script is complete. [root@adccrac1 ~]#

59 / 136

Page 60: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

[root@adccrac1 ~]# /app/11.2.0/grid/root.sh Performing root user operation for Oracle 11g The following environment variables are set as: ORACLE_OWNER= grid ORACLE_HOME= /app/11.2.0/grid Enter the full pathname of the local bin directory: [/usr/local/bin]: Copying dbhome to /usr/local/bin ... Copying oraenv to /usr/local/bin ... Copying coraenv to /usr/local/bin ... Creating /etc/oratab file... Entries will be added to the /etc/oratab file as needed by Database Configuration Assistant when a database is created Finished running generic part of root script. Now product-specific root actions will be performed. To configure Grid Infrastructure for a Stand-Alone Server run the following command as the root user: /app/11.2.0/grid/perl/bin/perl -I/app/11.2.0/grid/perl/lib -I/app/11.2.0/grid/crs/install /app/11.2.0/grid/crs/install/roothas.pl To configure Grid Infrastructure for a Cluster execute the following command: /app/11.2.0/grid/crs/config/config.sh This command launches the Grid Infrastructure Configuration Wizard. The wizard also supports silent operation, and the parameters can be passed through the

60 / 136

Page 61: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

response file that is available in the installation media. [root@adccrac1 ~]#

29. 给 GI 软件 打 PSU 补丁 18370031

以下操作只需要在节点 1 上完成,节点 2 上还没有 grid 软件

(1) 更新 Opatch 工具

[root@adccrac1 ~]# ls -ld /app/11.2.0/grid/ drwxrwxr-x 57 grid oinstall 4096 Aug 22 10:52 /app/11.2.0/grid/ [grid@adccrac1 ~]$ /app/11.2.0/grid/OPatch/opatch version OPatch Version: 11.2.0.3.4 OPatch succeeded. [grid@adccrac1 ~]$ mv $ORACLE_HOME/OPatch $ORACLE_HOME/OPatch_112034 [grid@adccrac1 ~]$ unzip -q /software/p6880880_112000_Linux-x86-64.zip -d $ORACLE_HOME [grid@adccrac1 ~]$ ls -l $ORACLE_HOME | grep OPatch drwxr-x--- 15 grid oinstall 4096 Apr 16 16:20 OPatch drwxr-xr-x 8 grid oinstall 4096 Aug 22 10:50 OPatch_112034

61 / 136

Page 62: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

[grid@adccrac1 ~]$ $ORACLE_HOME/OPatch/opatch version OPatch Version: 11.2.0.3.19 OPatch succeeded.

(2) 打补丁 18370031

[grid@adccrac1 ~]$ unzip /software/p18370031_112040_Linux-x86-64.zip -d /tmp/ [grid@adccrac1 ~]$ cd /tmp [grid@adccrac1 tmp]$ [grid@adccrac1 tmp]$ $ORACLE_HOME/OPatch/ocm/bin/emocmrsp OCM Installation Response Generator 10.3.7.0.0 - Production Copyright (c) 2005, 2012, Oracle and/or its affiliates. All rights reserved. Provide your email address to be informed of security issues, install and initiate Oracle Configuration Manager. Easier for you if you use your My Oracle Support Email address/User Name. Visit http://www.oracle.com/support/policies.html for details. Email address/User Name: 回车 You have not provided an email address for notification of security issues. Do you wish to remain uninformed of security issues ([Y]es, [N]o) [N]: Y The OCM configuration response file (ocm.rsp) was successfully created.

62 / 136

Page 63: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

[grid@adccrac1 18370031]$ $ORACLE_HOME/OPatch/opatch apply /tmp/18370031/ -oh $ORACLE_HOME -ocmrf /tmp/ocm.rsp Oracle Interim Patch Installer version 11.2.0.3.19 Copyright (c) 2018, Oracle Corporation. All rights reserved. Oracle Home : /app/11.2.0/grid Central Inventory : /app/oraInventory from : /app/11.2.0/grid/oraInst.loc OPatch version : 11.2.0.3.19 OUI version : 11.2.0.4.0 Log file location : /app/11.2.0/grid/cfgtoollogs/opatch/opatch2018-08-22_11-22-53AM_1.log Verifying environment and performing prerequisite checks... OPatch continues with these patches: 18370031 Do you want to proceed? [y|n] y User Responded with: Y All checks passed. Please shutdown Oracle instances running out of this ORACLE_HOME on the local system. (Oracle Home = '/app/11.2.0/grid') Is the local system ready for patching? [y|n]

63 / 136

Page 64: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

y User Responded with: Y Backing up files... Applying interim patch '18370031' to OH '/app/11.2.0/grid' Patching component oracle.crs, 11.2.0.4.0... Patch 18370031 successfully applied. Log file location: /app/11.2.0/grid/cfgtoollogs/opatch/opatch2018-08-22_11-22-53AM_1.log OPatch succeeded. [grid@adccrac1 18370031]$ [grid@adccrac1 18370031]$ $ORACLE_HOME/OPatch/opatch lsinventory Oracle Interim Patch Installer version 11.2.0.3.19 Copyright (c) 2018, Oracle Corporation. All rights reserved. Oracle Home : /app/11.2.0/grid Central Inventory : /app/oraInventory from : /app/11.2.0/grid/oraInst.loc OPatch version : 11.2.0.3.19 OUI version : 11.2.0.4.0 Log file location : /app/11.2.0/grid/cfgtoollogs/opatch/opatch2018-08-22_11-26-48AM_1.log Lsinventory Output file location : /app/11.2.0/grid/cfgtoollogs/opatch/lsinv/lsinventory2018-08-22_11-26-48AM.txt --------------------------------------------------------------------------------

64 / 136

Page 65: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

Local Machine Information:: Hostname: adccrac1 ARU platform id: 226 ARU platform description:: Linux x86-64 Installed Top-level Products (1): Oracle Grid Infrastructure 11g 11.2.0.4.0 There are 1 products installed in this Oracle Home. Interim patches (1) : Patch 18370031 : applied on Wed Aug 22 11:25:38 CST 2018 Unique Patch ID: 17950825 Patch description: "Grid Infrastructure Patch Set Update : 11.2.0.4.x (gibugno)" Created on 15 Aug 2014, 16:14:40 hrs PST8PDT Bugs fixed: 18370031 -------------------------------------------------------------------------------- OPatch succeeded. [grid@adccrac1 18370031]$

65 / 136

Page 66: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

30. 配置 Grid

(1) 克隆 grid 软件到节点 2

节点一操作, # tar -cvpf grid_soft.tar /app/11.2.0/grid/ 节点二操作, # scp grid@adccrac1:/grid_soft.tar ./ # tar -xvf grid_soft.tar 节点二 执行下面两个脚本 # /app/oraInventory/orainstRoot.sh # /app/11.2.0/grid/root.sh

(2) 克隆 ORACLE_HOME 配置

节点 1: [root@adccrac1 ~]# cd /app/oraInventory/ [root@adccrac1 oraInventory]# rm -rf * [root@adccrac1 oraInventory]# su - grid Last login: Wed Aug 22 11:09:37 CST 2018 on pts/3 [grid@adccrac1 ~]$ [grid@adccrac1 ~]$ cd $ORACLE_HOME/clone/bin [grid@adccrac1 bin]$ perl clone.pl -silent -debug ORACLE_BASE=/app/grid ORACLE_HOME=/app/11.2.0/grid ORACLE_HOME_NAME=Ora11g_gridinfrahome1

66 / 136

Page 67: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

INVENTORY_LOCATION=/app/oraInventory OSDBA_GROUP=oinstall OSOPER_GROUP=dba -O'"CLUSTER_NODES={adccrac1,adccrac2}"' -O'"LOCAL_NODE=adccrac1"' CRS=TRUE -ignoreSysPrereqs ./runInstaller -clone -waitForCompletion "ORACLE_BASE=/app/grid" "ORACLE_HOME=/app/11.2.0/grid" "ORACLE_HOME_NAME=Ora11g_gridinfrahome1" "INVENTORY_LOCATION=/app/oraInventory" "oracle_install_OSDBA=oinstall" "oracle_install_OSOPER=dba" "CLUSTER_NODES={adccrac1,adccrac2}" "LOCAL_NODE=adccrac1" "CRS=TRUE" -ignoreSysPrereqs -debug -silent -noConfig -nowait Starting Oracle Universal Installer... Checking swap space: must be greater than 500 MB. Actual 4991 MB Passed Preparing to launch Oracle Universal Installer from /tmp/OraInstall2018-08-22_12-37-03PM. Please wait ... LD_LIBRARY_PATH environment variable : ------------------------------------------------------- Total args: 36 Command line argument array elements ... Arg:0:/tmp/OraInstall2018-08-22_12-37-03PM/jre/bin/java: Arg:1:-Doracle.installer.library_loc=/tmp/OraInstall2018-08-22_12-37-03PM/oui/lib/linux64: Arg:2:-Doracle.installer.oui_loc=/tmp/OraInstall2018-08-22_12-37-03PM/oui: Arg:3:-Doracle.installer.bootstrap=TRUE: Arg:4:-Doracle.installer.startup_location=/app/11.2.0/grid/oui/bin: Arg:5:-Doracle.installer.jre_loc=../../jre: Arg:6:-Doracle.installer.custom_inventory=/app/oraInventory: Arg:7:-Doracle.installer.nlsEnabled="TRUE": Arg:8:-Doracle.installer.prereqConfigLoc= : Arg:9:-Doracle.installer.unixVersion=3.8.13-98.7.1.el7uek.x86_64: Arg:10:-mx150m: Arg:11:-cp: Arg:12:/tmp/OraInstall2018-08-22_12-37-03PM::/tmp/OraInstall2018-08-22_12-37-03PM/ext/jlib/instcommon.jar:/tmp/OraInstall2018-08-22_12-37-

67 / 136

Page 68: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

03PM/ext/jlib/cvu.jar:/tmp/OraInstall2018-08-22_12-37-03PM/ext/jlib/installcommons_1.0.0b.jar:/tmp/OraInstall2018-08-22_12-37-03PM/ext/jlib/OraPrereq.jar:/tmp/OraInstall2018-08-22_12-37-03PM/ext/jlib/OraPrereqChecks.jar:/tmp/OraInstall2018-08-22_12-37-03PM/ext/jlib/jsch.jar:/tmp/OraInstall2018-08-22_12-37-03PM/ext/jlib/orai18n-mapping.jar:/tmp/OraInstall2018-08-22_12-37-03PM/ext/jlib/orai18n-utility.jar:/tmp/OraInstall2018-08-22_12-37-03PM/ext/jlib/prov_fixup.jar:/tmp/OraInstall2018-08-22_12-37-03PM/ext/jlib/ojdbc5.jar:/tmp/OraInstall2018-08-22_12-37-03PM/ext/jlib/instcrs.jar:/tmp/OraInstall2018-08-22_12-37-03PM/ext/jlib/remoteinterfaces.jar:/tmp/OraInstall2018-08-22_12-37-03PM/ext/jlib/ssh.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/OraInstaller.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/oneclick.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/xmlparserv2.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/share.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/OraInstallerNet.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/emCfg.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/emocmutl.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/OraPrereq.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/jsch.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/ssh.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/remoteinterfaces.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/http_client.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/OraSuiteInstaller.jar:/tmp/OraInstall2018-08-22_12-37-03PM/OPatch/jlib/opatch.jar:/tmp/OraInstall2018-08-22_12-37-03PM/OPatch/jlib/opatchactions.jar:/tmp/OraInstall2018-08-22_12-37-03PM/OPatch/jlib/opatchprereq.jar:/tmp/OraInstall2018-08-22_12-37-03PM/OPatch/jlib/opatchutil.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/OraCheckPoint.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/InstImages.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/InstHelp.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/InstHelp_de.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/InstHelp_es.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/InstHelp_fr.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/InstHelp_it.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/InstHelp_ja.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/InstHelp_ko.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/InstHelp_pt_BR.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/InstHelp_zh_CN.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/InstHelp_zh_TW.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/oracle_ice.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/help4.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/help4-nls.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/ewt3.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/ewt3-swingaccess.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/ewt3-nls.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/swingaccess.jar::/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/jewt4.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/jewt4-nls.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/orai18n-collation.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/orai18n-mapping.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/ojmisc.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/xml.jar:/tmp/OraInstall2018-08-22_12-37-03PM/oui/jlib/srvm.jar:/tmp/OraInstall2018-

68 / 136

Page 69: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

08-22_12-37-03PM/oui/jlib/srvmasm.jar: Arg:13:oracle.sysman.oii.oiic.OiicInstaller: Arg:14:-scratchPath: Arg:15:/tmp/OraInstall2018-08-22_12-37-03PM: Arg:16:-sourceType: Arg:17:network: Arg:18:-timestamp: Arg:19:2018-08-22_12-37-03PM: Arg:20:-clone: Arg:21:-waitForCompletion: Arg:22:ORACLE_BASE=/app/grid: Arg:23:ORACLE_HOME=/app/11.2.0/grid: Arg:24:ORACLE_HOME_NAME=Ora11g_gridinfrahome1: Arg:25:INVENTORY_LOCATION=/app/oraInventory: Arg:26:oracle_install_OSDBA=oinstall: Arg:27:oracle_install_OSOPER=dba: Arg:28:CLUSTER_NODES={adccrac1,adccrac2}: Arg:29:LOCAL_NODE=adccrac1: Arg:30:CRS=TRUE: Arg:31:-ignoreSysPrereqs: Arg:32:-debug: Arg:33:-silent: Arg:34:-noConfig: Arg:35:-nowait: ------------------------------------------------------- Initializing Java Virtual Machine from /tmp/OraInstall2018-08-22_12-37-03PM/jre/bin/java. Please wait...

69 / 136

Page 70: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

Oracle Universal Installer, Version 11.2.0.4.0 Production Copyright (C) 1999, 2013, Oracle. All rights reserved. You can find the log of this install session at: /app/oraInventory/logs/cloneActions2018-08-22_12-37-03PM.log .................................................................................................[main] [ 2018-08-22 12:37:34.621 CST ] [QueryCluster.<init>:56] No Cluster detected [main] [ 2018-08-22 12:37:34.633 CST ] [QueryCluster.isCluster:65] Cluster existence check = false ... 100% Done. Installation in progress (Wednesday, August 22, 2018 12:37:41 PM CST) ..................................................................... 69% Done. Install successful Linking in progress (Wednesday, August 22, 2018 12:37:49 PM CST) Link successful Setup in progress (Wednesday, August 22, 2018 12:39:14 PM CST) ................ 100% Done. Setup successful End of install phases.(Wednesday, August 22, 2018 12:39:53 PM CST) WARNING: The following configuration scripts need to be executed as the "root" user in each new cluster node. Each script in the list below is followed by a list of nodes. /app/11.2.0/grid/root.sh #On nodes adccrac1

70 / 136

Page 71: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

To execute the configuration scripts: 1. Open a terminal window 2. Log in as "root" 3. Run the scripts in each cluster node Run the script on the local node first. After successful completion, you can run the script in parallel on all the other nodes. The cloning of Ora11g_gridinfrahome1 was successful. Please check '/app/oraInventory/logs/cloneActions2018-08-22_12-37-03PM.log' for more details. copying /app/oraInventory/logs/cloneActions2018-08-22_12-37-03PM.log to /app/11.2.0/grid/cfgtoollogs/oui/cloneActions2018-08-22_12-37-03PM.log copying /app/oraInventory/logs/oraInstall2018-08-22_12-37-03PM.out to /app/11.2.0/grid/cfgtoollogs/oui/oraInstall2018-08-22_12-37-03PM.out copying /app/oraInventory/logs/oraInstall2018-08-22_12-37-03PM.err to /app/11.2.0/grid/cfgtoollogs/oui/oraInstall2018-08-22_12-37-03PM.err copying /app/oraInventory/logs/silentInstall2018-08-22_12-37-03PM.log to /app/11.2.0/grid/cfgtoollogs/oui/silentInstall2018-08-22_12-37-03PM.log 配置完成执行:# /app/11.2.0/grid/root.sh [root@adccrac1 ~]# /app/11.2.0/grid/root.sh Check /app/11.2.0/grid/install/root_adccrac1_2018-08-22_12-45-00.log for the output of root script [root@adccrac1 ~]# cat /app/11.2.0/grid/install/root_adccrac1_2018-08-22_12-45-00.log Performing root user operation for Oracle 11g The following environment variables are set as: ORACLE_OWNER= grid ORACLE_HOME= /app/11.2.0/grid Copying dbhome to /usr/local/bin ... Copying oraenv to /usr/local/bin ...

71 / 136

Page 72: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

Copying coraenv to /usr/local/bin ... Entries will be added to the /etc/oratab file as needed by Database Configuration Assistant when a database is created Finished running generic part of root script. Now product-specific root actions will be performed. To configure Grid Infrastructure for a Stand-Alone Server run the following command as the root user: /app/11.2.0/grid/perl/bin/perl -I/app/11.2.0/grid/perl/lib -I/app/11.2.0/grid/crs/install /app/11.2.0/grid/crs/install/roothas.pl To configure Grid Infrastructure for a Cluster execute the following command: /app/11.2.0/grid/crs/config/config.sh This command launches the Grid Infrastructure Configuration Wizard. The wizard also supports silent operation, and the parameters can be passed through the response file that is available in the installation media. [root@adccrac1 ~]# 节点 2: [root@adccrac2 ~]# cd /app/oraInventory/ [root@adccrac2 oraInventory]# rm -rf * [root@adccrac2 oraInventory]# su - grid Last login: Wed Aug 22 11:15:37 CST 2018 on pts/3 [grid@adccrac2~]$ [grid@adccrac2 ~]$ cd $ORACLE_HOME/clone/bin

72 / 136

Page 73: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

[grid@adccrac2 bin]$ perl clone.pl -silent -debug ORACLE_BASE=/app/grid ORACLE_HOME=/app/11.2.0/grid ORACLE_HOME_NAME=Ora11g_gridinfrahome1 INVENTORY_LOCATION=/app/oraInventory OSDBA_GROUP=oinstall OSOPER_GROUP=dba -O'"CLUSTER_NODES={adccrac1,adccrac2}"' -O'"LOCAL_NODE=adccrac2"' CRS=TRUE -ignoreSysPrereqs 执行过程和节点一的相同,此处省略…… 配置完成执行:# /app/11.2.0/grid/root.sh

(3) 进行 Cluster 配置

根据上一步,最后日志的提示: 如果是要配置单节点的 RAC,需要在 root 用户下执行: /app/11.2.0/grid/perl/bin/perl -I/app/11.2.0/grid/perl/lib -I/app/11.2.0/grid/crs/install /app/11.2.0/grid/crs/install/roothas.pl 如果是要配置集群,需要执行在 grid 用户下执行: /app/11.2.0/grid/crs/config/config.sh 这里先选择配置单节点的 RAC,看是什么提示? [grid@adccrac1 ~]$ /app/11.2.0/grid/perl/bin/perl -I/app/11.2.0/grid/perl/lib -I/app/11.2.0/grid/crs/install /app/11.2.0/grid/crs/install/roothas.pl You must be logged in as root to run this script. Log in as root and rerun this script. 2018-08-22 12:59:20: Not running as authorized user

73 / 136

Page 74: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

Insufficient privileges to execute this script [root@adccrac1 grid]# /app/11.2.0/grid/perl/bin/perl -I/app/11.2.0/grid/perl/lib -I/app/11.2.0/grid/crs/install /app/11.2.0/grid/crs/install/roothas.pl Using configuration parameter file: /app/11.2.0/grid/crs/install/crsconfig_params User ignored Prerequisites during installation The oracle binary is currently linked with RAC enabled. Please execute the following steps to relink oracle binary and rerun the command with RAC disabled: setenv ORACLE_HOME <oracle_restart_home> cd <oracle_restart_home>/rdbms/lib make -f ins_rdbms.mk rac_off ioracle 现在选择集群的 RAC, [grid@adccrac1 ~]$ /app/11.2.0/grid/crs/config/config.sh 回车 弹出图形界面

74 / 136

Page 75: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

75 / 136

Page 76: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

76 / 136

Page 77: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

77 / 136

Page 78: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

78 / 136

Page 79: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

79 / 136

Page 80: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

80 / 136

Page 81: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

81 / 136

Page 82: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

82 / 136

Page 83: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

83 / 136

Page 84: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

84 / 136

Page 85: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

85 / 136

Page 86: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

86 / 136

Page 87: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

经过一系列的配置,最后在 15%的进度条时,弹出 执行脚本 /app/11.2.0/grid/root.sh 的对话框 [root@adccrac1 ~]# /app/11.2.0/grid/root.sh Check /app/11.2.0/grid/install/root_adccrac1_2018-08-22_13-11-02.log for the output of root script [root@adccrac1 ~]# tail -f /app/11.2.0/grid/install/root_adccrac1_2018-08-22_13-11-02.log Copying coraenv to /usr/local/bin ... Entries will be added to the /etc/oratab file as needed by Database Configuration Assistant when a database is created Finished running generic part of root script. Now product-specific root actions will be performed. Relinking oracle with rac_on option Using configuration parameter file: /app/11.2.0/grid/crs/install/crsconfig_params User ignored Prerequisites during installation Installing Trace File Analyzer OLR initialization - successful root wallet root wallet cert root cert export peer wallet profile reader wallet pa wallet peer wallet keys pa wallet keys

87 / 136

Page 88: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

peer cert request pa cert request peer cert pa cert peer root cert TP profile reader root cert TP pa root cert TP peer pa cert TP pa peer cert TP profile reader pa cert TP profile reader peer cert TP peer user cert pa user cert Adding Clusterware entries to oracle-ohasd.service <<== 当出现这一行信息时,打开另一个 session 窗口,查看 CRS-2672: Attempting to start 'ora.mdnsd' on 'adccrac1' CRS-2676: Start of 'ora.mdnsd' on 'adccrac1' succeeded CRS-2672: Attempting to start 'ora.gpnpd' on 'adccrac1' CRS-2676: Start of 'ora.gpnpd' on 'adccrac1' succeeded CRS-2672: Attempting to start 'ora.cssdmonitor' on 'adccrac1' CRS-2672: Attempting to start 'ora.gipcd' on 'adccrac1' CRS-2676: Start of 'ora.cssdmonitor' on 'adccrac1' succeeded CRS-2676: Start of 'ora.gipcd' on 'adccrac1' succeeded CRS-2672: Attempting to start 'ora.cssd' on 'adccrac1' CRS-2672: Attempting to start 'ora.diskmon' on 'adccrac1' CRS-2676: Start of 'ora.diskmon' on 'adccrac1' succeeded CRS-2676: Start of 'ora.cssd' on 'adccrac1' succeeded

88 / 136

Page 89: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

ASM created and started successfully. Disk Group OCRVOTE created successfully. clscfg: -install mode specified Successfully accumulated necessary OCR keys. Creating OCR keys for user 'root', privgrp 'root'.. Operation successful. CRS-4256: Updating the profile Successful addition of voting disk 6742c5d7880c4fd2bf2301e08582435b. Successfully replaced voting disk group with +OCRVOTE. CRS-4256: Updating the profile CRS-4266: Voting file(s) successfully replaced ## STATE File Universal Id File Name Disk group --- -------- --------------------------------------------------- --------------------------- --------------- 1. ONLINE 6742c5d7880c4fd2bf2301e08582435b (/dev/asm-ocrvote1) [OCRVOTE] Located 1 voting disk(s). CRS-2672: Attempting to start 'ora.asm' on 'adccrac1' CRS-2676: Start of 'ora.asm' on 'adccrac1' succeeded CRS-2672: Attempting to start 'ora.OCRVOTE.dg' on 'adccrac1' CRS-2676: Start of 'ora.OCRVOTE.dg' on 'adccrac1' succeeded Configure Oracle Grid Infrastructure for a Cluster ... succeeded [root@adccrac1 ~]# ls -ld /etc/init.d/* -rw-r--r--. 1 root root 13948 Sep 16 2015 /etc/init.d/functions

89 / 136

Page 90: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

-rwxr-xr-x. 1 root root 2989 Sep 16 2015 /etc/init.d/netconsole -rwxr-xr-x. 1 root root 6630 Sep 16 2015 /etc/init.d/network -rw-r--r--. 1 root root 1160 Nov 23 2015 /etc/init.d/README -rwxr-xr-x. 1 root root 2437 Nov 21 2015 /etc/init.d/rhnsd [root@adccrac1 ~]# ls -ld /etc/init.d/* -rw-r--r--. 1 root root 13948 Sep 16 2015 /etc/init.d/functions -rwxr-xr-x 1 root root 8758 Aug 22 13:14 /etc/init.d/init.ohasd <<== 已有这一行,刚才没有 -rwxr-xr-x. 1 root root 2989 Sep 16 2015 /etc/init.d/netconsole -rwxr-xr-x. 1 root root 6630 Sep 16 2015 /etc/init.d/network -rwxr-xr-x 1 root root 6709 Aug 22 13:14 /etc/init.d/ohasd <<== 已有这一行,刚才没有 -rw-r--r--. 1 root root 1160 Nov 23 2015 /etc/init.d/README -rwxr-xr-x. 1 root root 2437 Nov 21 2015 /etc/init.d/rhnsd [root@adccrac1 ~]# systemctl status ohasd ?.ohasd.service - (null) Loaded: loaded (/etc/rc.d/init.d/ohasd) Active: inactive (dead) Docs: man:systemd-sysv-generator(8) [root@adccrac1 ~]# ps -ef | grep ohasd root 20096 1 0 13:14 ? 00:00:00 /bin/sh /etc/init.d/init.ohasd run >/dev/null 2>&1 </dev/null root 20123 1 1 13:14 ? 00:00:04 /app/11.2.0/grid/bin/ohasd.bin reboot root 22411 18969 0 13:18 pts/2 00:00:00 grep --color=auto ohasd

90 / 136

Page 91: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

[root@adccrac1 ~]# ps -ef | grep d.bin root 20123 1 1 13:14 ? 00:00:05 /app/11.2.0/grid/bin/ohasd.bin reboot grid 21568 1 0 13:16 ? 00:00:00 /app/11.2.0/grid/bin/oraagent.bin grid 21579 1 0 13:16 ? 00:00:00 /app/11.2.0/grid/bin/mdnsd.bin grid 21593 1 0 13:16 ? 00:00:00 /app/11.2.0/grid/bin/gpnpd.bin root 21610 1 0 13:16 ? 00:00:00 /app/11.2.0/grid/bin/cssdmonitor grid 21612 1 0 13:16 ? 00:00:01 /app/11.2.0/grid/bin/gipcd.bin root 21633 1 0 13:16 ? 00:00:00 /app/11.2.0/grid/bin/cssdagent grid 21658 1 0 13:16 ? 00:00:01 /app/11.2.0/grid/bin/ocssd.bin root 21878 1 0 13:17 ? 00:00:00 /app/11.2.0/grid/bin/orarootagent.bin root 21889 1 0 13:17 ? 00:00:00 /app/11.2.0/grid/bin/octssd.bin root 21912 1 2 13:17 ? 00:00:02 /app/11.2.0/grid/bin/osysmond.bin root 21932 1 1 13:17 ? 00:00:01 /app/11.2.0/grid/bin/ologgerd -M -d /app/11.2.0/grid/crf/db/adccrac1 root 22062 1 3 13:18 ? 00:00:02 /app/11.2.0/grid/bin/crsd.bin reboot grid 22086 1 0 13:18 ? 00:00:00 /app/11.2.0/grid/bin/evmd.bin grid 22167 22086 0 13:18 ? 00:00:00 /app/11.2.0/grid/bin/evmlogger.bin -o /app/11.2.0/grid/evm/log/evmlogger.info -l /app/11.2.0/grid/evm/log/evmlogger.log grid 22454 1 0 13:18 ? 00:00:00 /app/11.2.0/grid/bin/oraagent.bin root 22741 1 1 13:19 ? 00:00:00 /app/11.2.0/grid/bin/orarootagent.bin grid 22865 1 0 13:19 ? 00:00:00 /app/11.2.0/grid/bin/tnslsnr LISTENER_SCAN1 -inherit root 22909 18669 0 13:19 pts/0 00:00:00 sh -c /bin/su grid -c ' /app/11.2.0/grid/bin/srvctl start oc4j ' 2>&1 root 22910 22909 0 13:19 pts/0 00:00:00 /bin/su grid -c /app/11.2.0/grid/bin/srvctl start oc4j grid 22911 22910 0 13:19 ? 00:00:00 /bin/sh /app/11.2.0/grid/bin/srvctl start oc4j grid 22931 1 0 13:19 ? 00:00:00 /app/11.2.0/grid/bin/scriptagent.bin grid 22941 22931 0 13:19 ? 00:00:00 /bin/sh /app/11.2.0/grid/bin/oc4jctl start grid 22944 22941 0 13:19 ? 00:00:00 /app/11.2.0/grid/perl/bin/perl -I/app/11.2.0/grid/lib /app/11.2.0/grid/bin/oc4jctl.pl start

91 / 136

Page 92: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

root 22950 18969 0 13:19 pts/2 00:00:00 grep --color=auto d.bin

31. 检查 GI (两节点都检查)

# su - grid $ crsctl check crs $ crs_stat -t $ olsnodes -n $ srvctl status listener $ srvctl status asm -a $ ocrcheck $ crsctl query css votedisk ===================================================================================================== [grid@adccrac1 ~]$ crsctl check crs CRS-4638: Oracle High Availability Services is online CRS-4537: Cluster Ready Services is online CRS-4529: Cluster Synchronization Services is online CRS-4533: Event Manager is online [grid@adccrac1 ~]$ [grid@adccrac1 ~]$ crs_stat -t Name Type Target State Host ------------------------------------------------------------ ora.ARCH.dg ora....up.type ONLINE ONLINE adccrac1 ora.BACK.dg ora....up.type ONLINE ONLINE adccrac1

92 / 136

Page 93: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

ora.DATA.dg ora....up.type ONLINE ONLINE adccrac1 ora....ER.lsnr ora....er.type ONLINE ONLINE adccrac1 ora....N1.lsnr ora....er.type ONLINE ONLINE adccrac1 ora.OCRVOTE.dg ora....up.type ONLINE ONLINE adccrac1 ora....SM1.asm application ONLINE ONLINE adccrac1 ora....C1.lsnr application ONLINE ONLINE adccrac1 ora....ac1.gsd application OFFLINE OFFLINE ora....ac1.ons application ONLINE ONLINE adccrac1 ora....ac1.vip ora....t1.type ONLINE ONLINE adccrac1 ora....SM2.asm application ONLINE ONLINE adccrac2 ora....C2.lsnr application ONLINE ONLINE adccrac2 ora....ac2.gsd application OFFLINE OFFLINE ora....ac2.ons application ONLINE ONLINE adccrac2 ora....ac2.vip ora....t1.type ONLINE ONLINE adccrac2 ora.asm ora.asm.type ONLINE ONLINE adccrac1 ora.cvu ora.cvu.type ONLINE ONLINE adccrac1 ora.gsd ora.gsd.type OFFLINE OFFLINE ora....network ora....rk.type ONLINE ONLINE adccrac1 ora.oc4j ora.oc4j.type ONLINE ONLINE adccrac1 ora.ons ora.ons.type ONLINE ONLINE adccrac1 ora.scan1.vip ora....ip.type ONLINE ONLINE adccrac1 [grid@adccrac1 ~]$ [grid@adccrac1 ~]$ olsnodes -n adccrac1 1 adccrac2 2 [grid@adccrac1 ~]$

93 / 136

Page 94: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

[grid@adccrac1 ~]$ srvctl status listener Listener LISTENER is enabled Listener LISTENER is running on node(s): adccrac2,adccrac1 [grid@adccrac1 ~]$ [grid@adccrac1 ~]$ srvctl status asm -a ASM is running on adccrac2,adccrac1 ASM is enabled. [grid@adccrac1 ~]$ [grid@adccrac1 ~]$ ocrcheck Status of Oracle Cluster Registry is as follows : Version : 3 Total space (kbytes) : 262120 Used space (kbytes) : 2644 Available space (kbytes) : 259476 ID : 1449608842 Device/File Name : +OCRVOTE Device/File integrity check succeeded Device/File not configured Device/File not configured Device/File not configured Device/File not configured

94 / 136

Page 95: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

Cluster registry integrity check succeeded Logical corruption check bypassed due to non-privileged user [grid@adccrac1 ~]$ [grid@adccrac1 ~]$ crsctl query css votedisk ## STATE File Universal Id File Name Disk group --- -------- --------------------------------------------------- --------------------------- --------------- 1. ONLINE 6742c5d7880c4fd2bf2301e08582435b (/dev/asm-ocrvote1) [OCRVOTE] Located 1 voting disk(s).

95 / 136

Page 96: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

32. 通过 asmca 命令 创建 ASM 磁盘的 data back arch 3 个磁盘组(只在节点一上做)

96 / 136

Page 97: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

97 / 136

Page 98: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

98 / 136

Page 99: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

99 / 136

Page 100: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

100 / 136

Page 101: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

33. 安装 DB (只在节点一上做) 只安装软件,不建库

(1) 对 db 软件 打补丁 19404309

[root@adccrac1 ~]# su - oracle Last login: Wed Aug 22 13:05:07 CST 2018 on pts/0 [oracle@adccrac1 ~]$ [oracle@adccrac1 ~]$ cd /tmp/b19404309/ [oracle@adccrac1 b19404309]$ cp database/cvu_prereq.xml ~/database/stage/cvu/

(2) 安装

[root@adccrac1 ~]# su - oracle Last login: Wed Aug 22 13:32:35 CST 2018 on pts/5 [oracle@adccrac1 ~]$ [oracle@adccrac1 ~]$ cd database/ [oracle@adccrac1 database]$ ls -lrht total 48K …… -rwxr-xr-x 1 oracle oinstall 3.2K Aug 27 2013 runInstaller …… [oracle@adccrac1 database]$ ./runInstaller 到 56%的进度条时,弹出一个报错对话框

101 / 136

Page 102: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

这个问题是 Bug 19692824,参考 Installation of Oracle 11.2.0.4 Database Software on OL7 fails with “undefined reference to symbol ‘B_DestroyKeyObject’” error (文档 ID 1965691.1)。Oracle 建议 Ignore,安装完后打 Patch 19692824。其实不用,另开一个窗口,或者 直接修改 ins_emagent.mk 文件

102 / 136

Page 103: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

给文件 ins_emagent.mk 的 MK_EMAGENT_NMECTL 行尾 增加参数 -lnnz11 $ vi $ORACLE_HOME/sysman/lib/ins_emagent.mk #=========================== # emdctl #=========================== $(SYSMANBIN)emdctl: $(MK_EMAGENT_NMECTL) 修改为: #=========================== # emdctl #=========================== $(SYSMANBIN)emdctl: $(MK_EMAGENT_NMECTL) -lnnz11 然后点击 Retry 继续安装,最后成功。

34. 在 DB 上 安装 PSU

(1) 介质

p6880880_112000_Linux-x86-64.zip p18370031_112040_Linux-x86-64.zip p23274134_112040_Linux-x86-64.zip

103 / 136

Page 104: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

都已上传到 /software 目录 由于 grid 软件 Opatch 已打,此处不需要再升级 Grid 的 Opatch,只需要升级 Db 的 OPatch

(2) 升级 Opatch 工具

[oracle@adccrac1 ~]$ $ORACLE_HOME/OPatch/opatch version OPatch Version: 11.2.0.3.4 OPatch succeeded. [oracle@adccrac1 ~]$ mv $ORACLE_HOME/OPatch $ORACLE_HOME/OPatch_112034 [oracle@adccrac1 ~]$ unzip -q /software/p6880880_112000_Linux-x86-64.zip -d $ORACLE_HOME [oracle@adccrac1 ~]$ [oracle@adccrac1 ~]$ $ORACLE_HOME/OPatch/opatch version OPatch Version: 11.2.0.3.19 OPatch succeeded.

104 / 136

Page 105: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

(3) 安装 PSU

先安装 PSU 18370031 [oracle@adccrac1 ~]$ $ORACLE_HOME/OPatch/opatch apply /tmp/18370031/ -oh $ORACLE_HOME -ocmrf /tmp/ocm.rsp Oracle Interim Patch Installer version 11.2.0.3.19 Copyright (c) 2018, Oracle Corporation. All rights reserved. Oracle Home : /app/oracle/product/11.2.0/db_1 Central Inventory : /app/oraInventory from : /app/oracle/product/11.2.0/db_1/oraInst.loc OPatch version : 11.2.0.3.19 OUI version : 11.2.0.4.0 Log file location : /app/oracle/product/11.2.0/db_1/cfgtoollogs/opatch/opatch2018-08-22_14-20-55PM_1.log Verifying environment and performing prerequisite checks... UtilSession failed: Patch 18370031 requires component(s) that are not installed in OracleHome. These not-installed components are oracle.crs:11.2.0.4.0, Log file location: /app/oracle/product/11.2.0/db_1/cfgtoollogs/opatch/opatch2018-08-22_14-20-55PM_1.log OPatch failed with error code 73 [oracle@adccrac1 ~]$ $ORACLE_HOME/OPatch/opatch apply /tmp/18370031/custom/server/18370031/ -oh $ORACLE_HOME -ocmrf /tmp/ocm.rsp Oracle Interim Patch Installer version 11.2.0.3.19 Copyright (c) 2018, Oracle Corporation. All rights reserved.

105 / 136

Page 106: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

Oracle Home : /app/oracle/product/11.2.0/db_1 Central Inventory : /app/oraInventory from : /app/oracle/product/11.2.0/db_1/oraInst.loc OPatch version : 11.2.0.3.19 OUI version : 11.2.0.4.0 Log file location : /app/oracle/product/11.2.0/db_1/cfgtoollogs/opatch/opatch2018-08-22_14-25-45PM_1.log Verifying environment and performing prerequisite checks... OPatch continues with these patches: 18370031 Do you want to proceed? [y|n] y User Responded with: Y All checks passed. Please shutdown Oracle instances running out of this ORACLE_HOME on the local system. (Oracle Home = '/app/oracle/product/11.2.0/db_1') Is the local system ready for patching? [y|n] y User Responded with: Y Backing up files... Applying interim patch '18370031' to OH '/app/oracle/product/11.2.0/db_1'

106 / 136

Page 107: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

Patching component oracle.rdbms, 11.2.0.4.0... Patch 18370031 successfully applied. Log file location: /app/oracle/product/11.2.0/db_1/cfgtoollogs/opatch/opatch2018-08-22_14-25-45PM_1.log OPatch succeeded. [oracle@adccrac1 ~]$ $ORACLE_HOME/OPatch/opatch lsinventory Oracle Interim Patch Installer version 11.2.0.3.19 Copyright (c) 2018, Oracle Corporation. All rights reserved. Oracle Home : /app/oracle/product/11.2.0/db_1 Central Inventory : /app/oraInventory from : /app/oracle/product/11.2.0/db_1/oraInst.loc OPatch version : 11.2.0.3.19 OUI version : 11.2.0.4.0 Log file location : /app/oracle/product/11.2.0/db_1/cfgtoollogs/opatch/opatch2018-08-22_14-28-16PM_1.log Lsinventory Output file location : /app/oracle/product/11.2.0/db_1/cfgtoollogs/opatch/lsinv/lsinventory2018-08-22_14-28-16PM.txt -------------------------------------------------------------------------------- Local Machine Information:: Hostname: adccrac1 ARU platform id: 226 ARU platform description:: Linux x86-64

107 / 136

Page 108: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

Installed Top-level Products (1): Oracle Database 11g 11.2.0.4.0 There are 1 products installed in this Oracle Home. Interim patches (1) : Patch 18370031 : applied on Wed Aug 22 14:27:38 CST 2018 Unique Patch ID: 17950825 Patch description: "Grid Infrastructure Patch Set Update : 11.2.0.4.x (gibugno)" Created on 15 Aug 2014, 16:14:32 hrs PST8PDT Bugs fixed: 18370031 -------------------------------------------------------------------------------- OPatch succeeded. 再安装 PSU 23274134 使用 grid 用户解压

108 / 136

Page 109: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

[grid@adccrac1 ~]$ unzip -q /software/p23274134_112040_Linux-x86-64.zip -d /tmp/ replace /tmp/PatchSearch.xml? [y]es, [n]o, [A]ll, [N]one, [r]ename: y [root@adccrac1 tmp]# ls -lrht total 272K drwxr-xr-x 6 grid oinstall 87 Aug 14 2014 b19404309 -rw-r--r-- 1 grid oinstall 267 Aug 16 2014 bundle.xml -rw-r--r-- 1 grid oinstall 50K Aug 16 2014 README.txt -rw-r--r-- 1 grid oinstall 90K Aug 16 2014 README.html drwxr-xr-x 5 grid oinstall 41 Aug 16 2014 18370031 drwxr-xr-x 5 grid oinstall 125 Jul 16 2016 23274134 <<== 这个补丁目录 -rw-rw-r-- 1 grid oinstall 109K Jul 20 2016 PatchSearch.xml drwxr-xr-x 2 grid oinstall 6 Aug 22 10:43 logs -rw-r--r-- 1 grid oinstall 621 Aug 22 11:14 ocm.rsp drwxr-xr-x 2 grid oinstall 54 Aug 22 12:22 Logs drwxr-xr-x 2 root root 6 Aug 22 13:19 hsperfdata_root drwxr-xr-x 3 grid oinstall 4.0K Aug 22 13:21 CVU_11.2.0.4.0_grid drwxr-xr-x 2 grid oinstall 18 Aug 22 13:24 hsperfdata_grid drwxr-xr-x 3 oracle oinstall 4.0K Aug 22 13:42 CVU_11.2.0.4.0_oracle drwxr-xr-x 2 oracle oinstall 6 Aug 22 14:28 hsperfdata_oracle [grid@adccrac1 ~]$ $ORACLE_HOME/OPatch/ocm/bin/emocmrsp -output /tmp/23274134/ocm.rsp OCM Installation Response Generator 10.3.7.0.0 - Production Copyright (c) 2005, 2012, Oracle and/or its affiliates. All rights reserved.

109 / 136

Page 110: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

Provide your email address to be informed of security issues, install and initiate Oracle Configuration Manager. Easier for you if you use your My Oracle Support Email address/User Name. Visit http://www.oracle.com/support/policies.html for details. Email address/User Name: 回车 You have not provided an email address for notification of security issues. Do you wish to remain uninformed of security issues ([Y]es, [N]o) [N]: y The OCM configuration response file (/tmp/23274134/ocm.rsp) was successfully created. [root@adccrac1 23274134]# ls -lrht total 152K drwxr-xr-x 5 grid oinstall 58 Feb 17 2016 22502505 drwxrwxr-x 13 grid oinstall 4.0K Jun 16 2016 23054359 -rw-rw-r-- 1 grid oinstall 71K Jun 28 2016 PatchSearch.xml drwxr-xr-x 5 grid oinstall 58 Jul 16 2016 23054319 -rw-r--r-- 1 grid oinstall 549 Jul 16 2016 bundle.xml -rw-rw-r-- 1 grid oinstall 63K Jul 19 2016 README.html -rw-rw-r-- 1 grid oinstall 24 Jul 19 2016 README.txt -rw-r--r-- 1 grid oinstall 621 Aug 22 14:53 ocm.rsp <<== 刚刚生成的 ocm.rsp 文件 检查补丁冲突 [grid@adccrac1 ~]$ opatch prereq CheckConflictAgainstOHWithDetail -ph /tmp/23274134/ Oracle Interim Patch Installer version 11.2.0.3.19 Copyright (c) 2018, Oracle Corporation. All rights reserved.

110 / 136

Page 111: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

PREREQ session Oracle Home : /app/11.2.0/grid Central Inventory : /app/oraInventory from : /app/11.2.0/grid/oraInst.loc OPatch version : 11.2.0.3.19 OUI version : 11.2.0.4.0 Log file location : /app/11.2.0/grid/cfgtoollogs/opatch/opatch2018-08-22_17-24-30PM_1.log Invoking prereq "checkconflictagainstohwithdetail" Prereq "checkConflictAgainstOHWithDetail" passed. OPatch succeeded. 在 grid 用户下 使用 opatch auto 命令 自动 打 PSU 23274134 [grid@adccrac1 ~]$ su Password: [root@adccrac1 grid]# $ORACLE_HOME/OPatch/opatch auto /tmp/23274134/ -ocmrf /tmp/23274134/ocm.rsp Executing /app/11.2.0/grid/perl/bin/perl /app/11.2.0/grid/OPatch/crs/patch11203.pl -patchdir /tmp -patchn 23274134 -ocmrf /tmp/23274134/ocm.rsp -paramfile /app/11.2.0/grid/crs/install/crsconfig_params This is the main log file: /app/11.2.0/grid/cfgtoollogs/opatchauto2018-08-22_14-56-13.log

111 / 136

Page 112: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

This file will show your detected configuration and all the steps that opatchauto attempted to do on your system: /app/11.2.0/grid/cfgtoollogs/opatchauto2018-08-22_14-56-13.report.log 2018-08-22 14:56:13: Starting Clusterware Patch Setup Using configuration parameter file: /app/11.2.0/grid/crs/install/crsconfig_params Stopping CRS... Stopped CRS successfully patch /tmp/23274134/23054359 apply successful for home /app/11.2.0/grid patch /tmp/23274134/23054319 apply successful for home /app/11.2.0/grid patch /tmp/23274134/22502505 apply successful for home /app/11.2.0/grid Starting CRS... Installing Trace File Analyzer 最后,查看 PSU 补丁信息 [grid@adccrac1 ~]$ opatch lspatches 22502505;ACFS Patch Set Update : 11.2.0.4.160419 (22502505) 23054319;OCW Patch Set Update : 11.2.0.4.160719 (23054319) 23054359;Database Patch Set Update : 11.2.0.4.160719 (23054359) OPatch succeeded.

112 / 136

Page 113: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

35. 使用 DBCA 命令 在节点一,创建 RAC 数据库 racdb

113 / 136

Page 114: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

114 / 136

Page 115: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

115 / 136

Page 116: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

116 / 136

Page 117: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

117 / 136

Page 118: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

118 / 136

Page 119: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

119 / 136

Page 120: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

120 / 136

Page 121: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

121 / 136

Page 122: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

122 / 136

Page 123: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

123 / 136

Page 124: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

124 / 136

Page 125: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

125 / 136

Page 126: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

126 / 136

Page 127: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

127 / 136

Page 128: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

128 / 136

Page 129: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

129 / 136

Page 130: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

130 / 136

Page 131: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

131 / 136

Page 132: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

36. 设置归档目录,并重启数据库到 mount 状态,打开归档模式,最后打开数据库

[oracle@adccrac1 ~]$ sqlplus / as sysdba SQL> alter system set log_archive_dest_1='location=+ARCH'; System altered. 在 节点一 和 节点二 上查看,已经发现 归档目录 已经设置好 NAME TYPE VALUE ------------------------------------ ---------------------- --------------------------------------- log_archive_dest_1 string location=+ARCH 现在关闭数据库,依次在两个节点上 进行操作,确保 整个集群 数据库 正常关闭 节点一, SQL> shutdown immediate; 节点二, SQL> shutdown immediate; 在节点一,启动数据库到 mount 状态,开启归档模式,最后正常打开数据库 SQL> startup mount; SQL> archive log list; SQL> alter database archivelog; SQL> archive log list;

132 / 136

Page 133: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

SQL> alter database open; 此时,在节点二上 直接打开数据库 SQL> startup;

133 / 136

Page 134: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

37. 在 grid 用户下 关闭集群服务之后,重新启动正常

134 / 136

Page 135: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

135 / 136

Page 136: 在Oracle Linux 7.2 上安装 Oracle RAC 11.2.0.4.0 for Linux x86 64 · 2018-08-24 · 安装过程中,设置时区(亚洲 上海)、自动分区、主机名 (adccrac1 ,这里一定不要设置为大写,因为在后面安装

136 / 136