基于Linux的Oracle 11g RAC安装(2)



二、安装CRS

节点名称为rac01, rac02, 安装前可使用命令检查系统安装环境:

$ ./runcluvfy.sh stage -pre crsinst -n rac01,rac02 -verbose

开始安装CRS

$ ./runInstaller

一些截图:

集群配置, 这里添加集群节点.Cluster Configuration

指定网卡接口类型网卡配置 

OCR配置OCR Location

 Voting Disk配置Voting Disk Location Install 安装完成, 需要在集群每个节点以root用户运行如下脚本:
/u01/app/oraInventory/orainstRoot.sh
/u01/app/11.1.0/crs/root.sh
Configuration scripts   运行完脚本点击OK完成CRS安装.

节点rac01运行脚本输出:

[root@rac01 oraInventory]# ./orainstRoot.sh
Changing permissions of /u01/app/oraInventory to 770.
Changing groupname of /u01/app/oraInventory to oinstall.
The execution of the script is complete
[root@rac01 crs]# ./root.sh
WARNING: directory ‘/u01/app/11.1.0′ is not owned by root
WARNING: directory ‘/u01/app’ is not owned by root
Checking to see if Oracle CRS stack is already configured
/etc/oracle does not exist. Creating it now.

Setting the permissions on OCR backup directory
Setting up Network socket directories
Oracle Cluster Registry configuration upgraded successfully
The directory ‘/u01/app/11.1.0′ is not owned by root. Changing owner to root
The directory ‘/u01/app’ is not owned by root. Changing owner to root
Successfully accumulated necessary OCR keys.
Using ports: CSS=49895 CRS=49896 EVMC=49898 and EVMR=49897.
node <nodenumber>: <nodename> <private interconnect name> <hostname>
node 1: rac01 prac01 rac01
node 2: rac02 prac02 rac02
Creating OCR keys for user ‘root’, privgrp ‘root’..
Operation successful.
Now formatting voting device: /dev/raw/raw5
Now formatting voting device: /dev/raw/raw6
Now formatting voting device: /dev/raw/raw7
Format of 3 voting devices complete.
Startup will be queued to init within 30 seconds.
Adding daemons to inittab
Expecting the CRS daemons to be up within 600 seconds.

Cluster Synchronization Services is active on these nodes.
        rac01
Cluster Synchronization Services is inactive on these nodes.
        rac02
Local node checking complete. Run root.sh on remaining nodes to start CRS daemons.

节点rac02运行脚本输出:

[root@rac02 oraInventory]# ./orainstRoot.sh
Changing permissions of /u01/app/oraInventory to 770.
Changing groupname of /u01/app/oraInventory to oinstall.
The execution of the script is complete
[root@rac02 crs]# ./root.sh
WARNING: directory ‘/u01/app/11.1.0′ is not owned by root
WARNING: directory ‘/u01/app’ is not owned by root
Checking to see if Oracle CRS stack is already configured
/etc/oracle does not exist. Creating it now.

Setting the permissions on OCR backup directory
Setting up Network socket directories
Oracle Cluster Registry configuration upgraded successfully
The directory ‘/u01/app/11.1.0′ is not owned by root. Changing owner to root
The directory ‘/u01/app’ is not owned by root. Changing owner to root
clscfg: EXISTING configuration version 4 detected.
clscfg: version 4 is 11 Release 1.
Successfully accumulated necessary OCR keys.
Using ports: CSS=49895 CRS=49896 EVMC=49898 and EVMR=49897.
node <nodenumber>: <nodename> <private interconnect name> <hostname>
node 1: rac01 prac01 rac01
node 2: rac02 prac02 rac02
clscfg: Arguments check out successfully.

NO KEYS WERE WRITTEN. Supply -force parameter to override.
-force is destructive and will destroy any previous cluster
configuration.
Oracle Cluster Registry for cluster has already been initialized
Startup will be queued to init within 30 seconds.
Adding daemons to inittab
Expecting the CRS daemons to be up within 600 seconds.
Cluster Synchronization Services is active on these nodes.
        rac01
        rac02
Cluster Synchronization Services is active on all the nodes.
Waiting for the Oracle CRSD and EVMD to start
Waiting for the Oracle CRSD and EVMD to start
Oracle CRS stack installed and running under init(1M)
Running vipca(silent) for configuring nodeapps

Creating VIP application resource on (2) nodes…
Creating GSD application resource on (2) nodes…
Creating ONS application resource on (2) nodes…
Starting VIP application resource on (2) nodes…
Starting GSD application resource on (2) nodes…
Starting ONS application resource on (2) nodes…

Done.

安装完成后集群状态检查

1. 可在任意时候通过cluvfy命令检查CRS激活和配置情况:

[oracle@rac01 bin]$ ./cluvfy comp crs -n rac01,rac02

Verifying CRS integrity

Checking CRS integrity…

Checking daemon liveness…
Liveness check passed for "CRS daemon".

Checking daemon liveness…
Liveness check passed for "CSS daemon".

Checking daemon liveness…
Liveness check passed for "EVM daemon".

Checking CRS health…
CRS health check passed.

CRS integrity check passed.

Verification of CRS integrity was successful.

结果显示集群各组件都在健康的运行.

 

2. crs_stat命令提供集群状态摘要

[oracle@rac01 bin]$ ./crs_stat -t
Name           Type           Target    State     Host       
————————————————————
ora.rac01.gsd  application    ONLINE    ONLINE    rac01      
ora.rac01.ons  application    ONLINE  
0; ONLINE    rac01      
ora.rac01.vip  application    ONLINE    ONLINE    rac01      
ora.rac02.gsd  application    ONLINE    ONLINE    rac02      
ora.rac02.ons  application    ONLINE    ONLINE    rac02      
ora.rac02.vip  application    ONLINE    ONLINE    rac02   



发表评论