利用VirtualBox在Oracle Linux 7安装Oracle 19c RAC Part3-安装Oracle Grid Infrastructure 19c

上一节我们完成了Oracle 19c RAC安装环境的准备,这一节正式开始Oracle Grid Infrastructure 19c的安装。

确认虚拟机ol7-19-rac1和ol7-19-rac2处于启动状态。

解压Oracle Grid Infrastructure 19c安装包

把之前下载的Oracle Grid Infrastructure 19c压缩包文件LINUX.X64_193000_grid_home.zip上传到ol7-19-rac1的home目录下。

使用oracle用户登录到ol7-19-rac1,把安装包解压到$ORACLE_HOME下。

[[email protected] ~]$ source grid_env
[[email protected] ~]$ cd $ORACLE_HOME
[[email protected] grid]$ pwd
/u01/app/19/grid
[[email protected] grid]$ unzip ~/LINUX.X64_193000_grid_home.zip

安装Oracle Grid Infrastructure 19c

安装包解压完成后,切换到root用户,安装/u01/app/19/grid/cv目录下cvuqdisk-1.0.10-1.rpm包。

[[email protected] ~]# cd /u01/app/19/grid/cv
[[email protected] cv]# ls
admin cvdata cvutl remenv rpm
[[email protected] cv]# cd rpm
[[email protected] rpm]# rpm -Uvh cvuqdisk-1.0.10-1.rpm
Preparing… ################################# [100%]
Using default group oinstall to install package
Updating / installing…
1:cvuqdisk-1.0.10-1 ################################# [100%]
[[email protected] rpm]#

切换回oracle用户,运行gridSetup.sh进行Oracle Grid Infrastructure 19c安装。

[[email protected] ~]$ cd $ORACLE_HOME
[[email protected] grid]$ ./gridSetup.sh

Grid Setup

进入Grid Infrastructure 19c的图形安装界面。

Grid 1

选择”Configure Oracle Grid Infrastructure for a New Cluster”,点Next

接受默认的”Configure an Oracle Standalone Cluster”,Next

SCAN设置,把集群名设置为我们配置文件的名字”ol7-19″,端口选择默认的1521,点击Next

集群节点配置,点击Add,增加第二个节点ol7-19-rac2信息,OK

增加节点后,点击”SSH connectivity…“,设置节点间SSH互连。

输入操作系统用户oracle的密码,点击Setup进行设置。

 

节点间SSH连通测试通过后点OK,按Next

网络接口设置,把enp0s8的用途改为”ASM & Private”,Next

存储选择”Use Oracle Flex ASM for storage“,Next

Configure Grid Infrastructure Management Repository选择默认的No, Next

创建名为CRS的ASM磁盘组,选择/dev/asm-orc1,/dev/asm-ocr2和/dev/asm-ocr3三个磁盘,Next

输入ASM密码,Next

Failure Isolation,选择默认的不使用IPMI,Next

Management Options,不注册EM,Next

选择管理员对应的操作系统用户组,Next

安装位置,选择默认的Oracle Base,Next

安装位置,默认位置,Next

Root脚本运行方式,选择手工安装,Next

系统前提条件检查,有swap和SCAN的警告及DNS服务的失败信息,不影响安装,所以选择忽略,Next

安装信息总结,确认无误后保存响应文件,点Install进行GI安装。

正式安装GI,耐心等待文件复制及两个节点设置完成。

至执行root脚本提示出现时,分别按提示在两个节点执行orainstRoot.sh和root.sh脚本。

以下是脚本在节点一“ol7-19-rac1”的执行输出。

[[email protected] rpm]# /u01/app/oraInventory/orainstRoot.sh
Changing permissions of /u01/app/oraInventory.
Adding read,write permissions for group.
Removing read,write,execute permissions for world.Changing groupname of /u01/app/oraInventory to oinstall.
The execution of the script is complete.
[[email protected] rpm]# /u01/app/19/grid/root.sh
Performing root user operation.The following environment variables are set as:
ORACLE_OWNER= oracle
ORACLE_HOME= /u01/app/19/gridEnter 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.
Relinking oracle with rac_on option
Using configuration parameter file: /u01/app/19/grid/crs/install/crsconfig_params
The log of current session can be found at:
/u01/app/oracle/crsdata/ol7-19-rac1/crsconfig/rootcrs_ol7-19-rac1_2019-11-08_02-46-09PM.log
2019/11/08 14:49:52 CLSRSC-594: Executing installation step 1 of 19: ‘SetupTFA’.
2019/11/08 14:49:53 CLSRSC-594: Executing installation step 2 of 19: ‘ValidateEnv’.
2019/11/08 14:49:53 CLSRSC-363: User ignored prerequisites during installation
2019/11/08 14:49:53 CLSRSC-594: Executing installation step 3 of 19: ‘CheckFirstNode’.
2019/11/08 14:49:56 CLSRSC-594: Executing installation step 4 of 19: ‘GenSiteGUIDs’.
2019/11/08 14:49:57 CLSRSC-594: Executing installation step 5 of 19: ‘SetupOSD’.
2019/11/08 14:49:57 CLSRSC-594: Executing installation step 6 of 19: ‘CheckCRSConfig’.
2019/11/08 14:49:57 CLSRSC-594: Executing installation step 7 of 19: ‘SetupLocalGPNP’.
2019/11/08 14:50:22 CLSRSC-594: Executing installation step 8 of 19: ‘CreateRootCert’.
2019/11/08 14:50:28 CLSRSC-594: Executing installation step 9 of 19: ‘ConfigOLR’.
2019/11/08 14:50:32 CLSRSC-4002: Successfully installed Oracle Trace File Analyzer (TFA) Collector.
2019/11/08 14:51:08 CLSRSC-594: Executing installation step 10 of 19: ‘ConfigCHMOS’.
2019/11/08 14:51:08 CLSRSC-594: Executing installation step 11 of 19: ‘CreateOHASD’.
2019/11/08 14:51:16 CLSRSC-594: Executing installation step 12 of 19: ‘ConfigOHASD’.
2019/11/08 14:51:17 CLSRSC-330: Adding Clusterware entries to file ‘oracle-ohasd.service’
2019/11/08 14:53:53 CLSRSC-594: Executing installation step 13 of 19: ‘InstallAFD’.
2019/11/08 14:54:01 CLSRSC-594: Executing installation step 14 of 19: ‘InstallACFS’.
2019/11/08 14:56:00 CLSRSC-594: Executing installation step 15 of 19: ‘InstallKA’.
2019/11/08 14:56:08 CLSRSC-594: Executing installation step 16 of 19: ‘InitConfig’.ASM has been created and started successfully.[DBT-30001] Disk groups created successfully. Check /u01/app/oracle/cfgtoollogs/asmca/asmca-191108PM025722.log for details.

2019/11/08 15:20:15 CLSRSC-482: Running command: ‘/u01/app/19/grid/bin/ocrconfig -upgrade oracle oinstall’
CRS-4256: Updating the profile
Successful addition of voting disk b7bdb62a9f7c4f6ebf500c3ead350ca2.
Successful addition of voting disk 1142140776854f78bf2267c0f315a1ed.
Successful addition of voting disk 0816bcfc38c54fbdbf34954f90898764.
Successfully replaced voting disk group with +CRS.
CRS-4256: Updating the profile
CRS-4266: Voting file(s) successfully replaced
## STATE File Universal Id File Name Disk group
— —– —————– ——— ———
1. ONLINE b7bdb62a9f7c4f6ebf500c3ead350ca2 (/dev/asm-ocr1) [CRS]
2. ONLINE 1142140776854f78bf2267c0f315a1ed (/dev/asm-ocr2) [CRS]
3. ONLINE 0816bcfc38c54fbdbf34954f90898764 (/dev/asm-ocr3) [CRS]
Located 3 voting disk(s).
2019/11/08 15:25:32 CLSRSC-594: Executing installation step 17 of 19: ‘StartCluster’.
2019/11/08 15:29:34 CLSRSC-343: Successfully started Oracle Clusterware stack
2019/11/08 15:29:35 CLSRSC-594: Executing installation step 18 of 19: ‘ConfigNode’.
2019/11/08 15:37:07 CLSRSC-594: Executing installation step 19 of 19: ‘PostConfig’.
2019/11/08 15:38:58 CLSRSC-325: Configure Oracle Grid Infrastructure for a Cluster … succeeded
[[email protected] rpm]#

在第一个节点执行完root脚本后,继续在第二个节点执行,全部成功完成后点OK,继续GI配置。

最后成功完成GI安装,Close退出安装向导。

验证Oracle Grid Infrastructure集群状态

安装完Oracle Grid Infrastructure集群后,可以使用crsctl stat res -t命令查看集群资源状态信息。

[[email protected] ~]$ crsctl stat res -t
——————————————————————————–
Name Target State Server State details
——————————————————————————–
Local Resources
——————————————————————————–
ora.LISTENER.lsnr
ONLINE  ONLINE        ol7-19-rac1        STABLE
ONLINE  ONLINE        ol7-19-rac2        STABLE
ora.chad
ONLINE  ONLINE         ol7-19-rac1        STABLE
ONLINE  ONLINE         ol7-19-rac2        STABLE
ora.net1.network
ONLINE  ONLINE          ol7-19-rac1        STABLE
ONLINE  ONLINE          ol7-19-rac2        STABLE
ora.ons
ONLINE ONLINE           ol7-19-rac1        STABLE
ONLINE ONLINE           ol7-19-rac2        STABLE
ora.proxy_advm
OFFLINE  OFFLINE          ol7-19-rac1       STABLE
OFFLINE  OFFLINE          ol7-19-rac2       STABLE
——————————————————————————–
Cluster Resources
——————————————————————————–
ora.ASMNET1LSNR_ASM.lsnr(ora.asmgroup)
1                   ONLINE  ONLINE        ol7-19-rac1      STABLE
2                   ONLINE  ONLINE        ol7-19-rac2       STABLE
3                   OFFLINE  OFFLINE                                STABLE
ora.CRS.dg(ora.asmgroup)
1                    ONLINE  ONLINE        ol7-19-rac1       STABLE
2                    OFFLINE  OFFLINE                                STABLE
3                    OFFLINE  OFFLINE                                STABLE
ora.LISTENER_SCAN1.lsnr
1                    ONLINE  ONLINE        ol7-19-rac1        STABLE
ora.asm(ora.asmgroup)
1                    ONLINE  ONLINE         ol7-19-rac1       Started,STABLE
2                    ONLINE  OFFLINE                                  STABLE
3                    OFFLINE  OFFLINE                                 STABLE
ora.asmnet1.asmnetwork(ora.asmgroup)
1                       ONLINE  ONLINE       ol7-19-rac1        STABLE
2                       ONLINE  ONLINE       ol7-19-rac2        STABLE
3                       OFFLINE  OFFLINE                                STABLE
ora.cvu
1                       ONLINE  ONLINE        ol7-19-rac1       STABLE
ora.ol7-19-rac1.vip
1                         ONLINE ONLINE         ol7-19-rac1      STABLE
ora.ol7-19-rac2.vip
1                        ONLINE  ONLINE          ol7-19-rac2     STABLE
ora.qosmserver
1                        ONLINE  ONLINE           ol7-19-rac1     STABLE
ora.scan1.vip
1                        ONLINE  ONLINE           ol7-19-rac1      STABLE
——————————————————————————–
[[email protected]9-rac1 ~]$

确认两个节点的资源都成功启动,可以进行Oracle数据库19c软件在集群上的安装。

 

 

 

 

Leave A Comment