如果安装过10g以后的RAC环境,应该对这个工具并不陌生。在安装Cluster和Database之前通常会执行runcluvfy.sh脚本来检查当前系统是否满足安装条件。
这篇介绍stage相关选项。
可以通过stage �Clist来列出所有cluvfy工具支持的部署组件:
bash-2.03$ cluvfy stage -list
USAGE:
cluvfy stage {-pre|-post} <stage-name> <stage-specific options> [-verbose]
Valid stage options and stage names are:
-post hwos : post-check for hardware and operating system
-pre crsinst : pre-check for CRS installation
-post crsinst : post-check for CRS installation
-pre dbinst : pre-check for database installation
-pre dbcfg : pre-check for database configuration
其中-pre crsinst、-post crsinst和-pre dbinst都是RAC安装常用的验证选项:
bash-2.03$ cluvfy stage -pre crsinst -n racnode1,racnode2 -r 10gR2 -c /dev/rac/ocr -q /dev/rac/vot -osdba dba
Performing pre-checks for cluster services setup
Checking node reachability...
Node reachability check passed from node "racnode1".
Checking user equivalence...
User equivalence check passed for user "oracle".
Checking administrative privileges...
User existence check passed for "oracle".
Group existence check passed for "oinstall".
Membership check for user "oracle" in group "oinstall" [as Primary] passed.
Administrative privileges check passed.
Checking node connectivity...
Node connectivity check passed for subnet "172.25.0.0" with node(s) racnode2,racnode1.
Node connectivity check passed for subnet "172.25.198.0" with node(s) racnode2,racnode1.
Node connectivity check passed for subnet "10.0.0.0" with node(s) racnode2,racnode1.
Suitable interfaces for the private interconnect on subnet "172.25.0.0":
racnode2 ce0:172.25.198.223
racnode1 ce0:172.25.198.222
Suitable interfaces for the private interconnect on subnet "172.25.198.0":
racnode2 ce0:172.25.198.225
racnode1 ce0:172.25.198.224
Suitable interfaces for the private interconnect on subnet "10.0.0.0":
racnode2 ce1:10.0.0.2
racnode1 ce1:10.0.0.1
ERROR:
Could not find a suitable set of interfaces for VIPs.
Node connectivity check failed.
Checking shared storage accessibility...
ERROR: /dev/rac/ocr
Could not get the type of storage
Shared storage check failed on nodes "racnode2,racnode1".
Checking shared storage accessibility...
ERROR: /dev/rac/vot
Could not get the type of storage
Shared storage check failed on nodes "racnode2,racnode1".
Checking system requirements for 'crs'...
Total memory check passed.
Free disk space check passed.
Swap space check passed.
System architecture check passed.
Operating system version check passed.
Operating system patch check failed for "112760-05".
Check failed on nodes:
racnode2,racnode1
Operating system patch check passed for "108993-45".
Operating system patch check failed for "112763-13".
Check failed on nodes:
racnode2,racnode1
Package existence check passed for "SUNWarc".
Package existence check passed for "SUNWbtool".
Package existence check passed for "SUNWhea".
Package existence check passed for "SUNWlibm".
Package existence check passed for "SUNWlibms".
Package existence check passed for "SUNWsprot".
Package existence check passed for "SUNWsprox".
Package existence check passed for "SUNWtoo".
Package existence check passed for "SUNWi1of".
Package existence check passed for "SUNWi1cs".
Package existence check passed for "SUNWi15cs".
Package existence check passed for "SUNWxwfnt".
Package existence check passed for "SUNWlibC".
Group existence check passed for "dba".
Group existence check passed for "oinstall".
User existence check passed for "nobody".
System requirement failed for 'crs'
Pre-check for cluster services setup was unsuccessful on all the nodes.
pre选项主要检查是否满足安装的需要,而post选择则检查安装后的组件是否正常:
bash-2.03$ cluvfy stage -post crsinst -n racnode1,racnode2 -verbose
Performing post-checks for cluster services setup
Checking node reachability...
Check: Node reachability from node "racnode1"
Destination Node Reachable?
------------------------------------ ------------------------
racnode1 yes
racnode2 yes
Result: Node reachability check passed from node "racnode1".
Checking user equivalence...
Check: User equivalence for user "oracle"
Node Name Comment
------------------------------------ ------------------------
racnode2 passed
racnode1 passed
Result: User equivalence check passed for user "oracle".
Checking Cluster manager integrity...
Checking CSS daemon...
Node Name Status
------------------------------------ ------------------------
racnode2 running
racnode1 running
Result: Daemon status check passed for "CSS daemon".
Cluster manager integrity check passed.
Checking cluster integrity...
Node Name
------------------------------------
racnode1
racnode2
Cluster integrity check passed
Checking OCR integrity...
Checking the absence of a non-clustered configuration...
All nodes free of non-clustered, local-only configurations.
Uniqueness check for OCR device passed.
Checking the version of OCR...
OCR of correct Version "2" exists.
Checking data integrity of OCR...
Data integrity check for OCR passed.
OCR integrity check passed.
Checking CRS integrity...
Checking daemon liveness...
Check: Liveness for "CRS daemon"
Node Name Running
------------------------------------ ------------------------
racnode2 yes
racnode1 yes
Result: Liveness check passed for "CRS daemon".
Checking daemon liveness...
Check: Liveness for "CSS daemon"
Node Name Running
------------------------------------ ------------------------
racnode2 yes
racnode1 yes
Result: Liveness check passed for "CSS daemon".
Checking daemon liveness...
Check: Liveness for "EVM daemon"
Node Name Running
------------------------------------ ------------------------
racnode2 yes
racnode1 yes
Result: Liveness check passed for "EVM daemon".
Liveness of all the daemons
Node Name CRS daemon CSS daemon EVM daemon
------------ ------------------------ ------------------------ ----------
racnode2 yes yes yes
racnode1 yes yes yes
Checking CRS health...
Check: Health of CRS
Node Name CRS OK?
------------------------------------ ------------------------
racnode2 yes
racnode1 yes
Result: CRS health check passed.
CRS integrity check passed.
Checking node application existence...
Checking existence of VIP node application
Node Name Required Status Comment
------------ ------------------------ ------------------------ ----------
racnode2 yes exists passed
racnode1 yes exists passed
Result: Check passed.
Checking existence of ONS node application
Node Name Required Status Comment
------------ ------------------------ ------------------------ ----------
racnode2 no exists passed
racnode1 no exists passed
Result: Check passed.
Checking existence of GSD node application
Node Name Required Status Comment
------------ ------------------------ ------------------------ ----------
racnode2 no exists passed
racnode1 no exists passed
Result: Check passed.
Post-check for cluster services setup was successful.
很明显二者验证的方面有很大的区别。
bash-2.03$ cluvfy stage -pre dbinst -n racnode1,racnode2
Performing pre-checks for database installation
Checking node reachability...
Node reachability check passed from node "racnode1".
Checking user equivalence...
User equivalence check passed for user "oracle".
Checking administrative privileges...
User existence check passed for "oracle".
Group existence check passed for "oinstall".
Membership check for user "oracle" in group "oinstall" [as Primary] passed.
Group existence check passed for "dba".
Membership check for user "oracle" in group "dba" passed.
Administrative privileges check passed.
Checking node connectivity...
Node connectivity check passed for subnet "172.25.0.0" with node(s) racnode2,racnode1.
Node connectivity check passed for subnet "172.25.198.0" with node(s) racnode2,racnode1.
Node connectivity check passed for subnet "10.0.0.0" with node(s) racnode2,racnode1.
Suitable interfaces for the private interconnect on subnet "172.25.0.0":
racnode2 ce0:172.25.198.223
racnode1 ce0:172.25.198.222
Suitable interfaces for the private interconnect on subnet "172.25.198.0":
racnode2 ce0:172.25.198.225
racnode1 ce0:172.25.198.224
Suitable interfaces for the private interconnect on subnet "10.0.0.0":
racnode2 ce1:10.0.0.2
racnode1 ce1:10.0.0.1
ERROR:
Could not find a suitable set of interfaces for VIPs.
Node connectivity check failed.
Checking system requirements for 'database'...
Total memory check passed.
Free disk space check passed.
Swap space check passed.
System architecture check passed.
Operating system version check passed.
Operating system patch check failed for "112760-05".
Check failed on nodes:
racnode2,racnode1
Operating system patch check passed for "108993-45".
Operating system patch check failed for "112763-13".
Check failed on nodes:
racnode2,racnode1
Package existence check passed for "SUNWarc".
Package existence check passed for "SUNWbtool".
Package existence check passed for "SUNWhea".
Package existence check passed for "SUNWlibm".
Package existence check passed for "SUNWlibms".
Package existence check passed for "SUNWsprot".
Package existence check passed for "SUNWsprox".
Package existence check passed for "SUNWtoo".
Package existence check passed for "SUNWi1of".
Package existence check passed for "SUNWi1cs".
Package existence check passed for "SUNWi15cs".
Package existence check passed for "SUNWxwfnt".
Package existence check passed for "SUNWlibC".
Kernel parameter check failed for "noexec_user_stack".
Check failed on nodes:
racnode2,racnode1
Kernel parameter check passed for "SEMMNI".
Kernel parameter check passed for "SEMMNS".
Kernel parameter check passed for "SEMMSL".
Kernel parameter check passed for "SEMVMX".
Kernel parameter check passed for "SHMMAX".
Kernel parameter check passed for "SHMMIN".
Kernel parameter check passed for "SHMMNI".
Kernel parameter check passed for "SHMSEG".
Group existence check passed for "dba".
User existence check passed for "nobody".
System requirement failed for 'database'
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.
Checking node application existence...
Checking existence of VIP node application (required)
Check passed.
Checking existence of ONS node application (optional)
Check passed.
Checking existence of GSD node application (optional)
Check passed.
Pre-check for database installation was unsuccessful on all the nodes.
除了这些常见的验证外,stage还提供了创建数据库的验证:
bash-2.03$ cluvfy stage -pre dbcfg -n racnode1,racnode2
ERROR:
Oracle Home must be specified. See usage for detail.
USAGE:
cluvfy stage -pre dbcfg -n <node_list> -d <oracle_home> [-verbose]
<node_list> is the comma separated list of non-domain qualified nodenames, on which the test should be conducted. If "all" is specified, then all the nodes in the cluster will be used for verification.
<oracle_home> is the location of the oracle home.
DESCRIPTION:
Performs the appropriate checks on all the nodes in the nodelist before configuring a RAC database.
bash-2.03$ cluvfy stage -pre dbcfg -n racnode1,racnode2 -d /data/oracle/product/10.2/database
Performing pre-checks for database configuration
Checking node reachability...
Node reachability check passed from node "racnode1".
Checking user equivalence...
User equivalence check passed for user "oracle".
Checking administrative privileges...
User existence check passed for "oracle".
Group existence check passed for "oinstall".
Membership check for user "oracle" in group "oinstall" [as Primary] passed.
Group existence check passed for "dba".
Membership check for user "oracle" in group "dba" passed.
Administrative privileges check passed.
Checking node connectivity...
Node connectivity check passed for subnet "172.25.0.0" with node(s) racnode2,racnode1.
Node connectivity check passed for subnet "172.25.198.0" with node(s) racnode2,racnode1.
Node connectivity check passed for subnet "10.0.0.0" with node(s) racnode2,racnode1.
Suitable interfaces for the private interconnect on subnet "172.25.0.0":
racnode2 ce0:172.25.198.223
racnode1 ce0:172.25.198.222
Suitable interfaces for the private interconnect on subnet "172.25.198.0":
racnode2 ce0:172.25.198.225
racnode1 ce0:172.25.198.224
Suitable interfaces for the private interconnect on subnet "10.0.0.0":
racnode2 ce1:10.0.0.2
racnode1 ce1:10.0.0.1
ERROR:
Could not find a suitable set of interfaces for VIPs.
Node connectivity check failed.
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.
Pre-check for database configuration was unsuccessful on all the nodes.
oracle视频教程请关注:http://u.youku.com/user_video/id_UMzAzMjkxMjE2.html