[20171031]How to find Cluster name on RAC instance.txt
--//如何获得Cluster name,做一个记录:
1.以grid用户登录:
SYS@+ASM1> @ &r/ver
BANNER
--------------------------------------------------------------------------------
Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production
$ which cemutlo
/u01/app/11.2.0.4/grid/bin/cemutlo
$ echo $ORACLE_HOME
/u01/app/11.2.0.4/grid
$ cemutlo
Usage: /u01/app/11.2.0.4/grid/bin/cemutlo.bin [-n] [-w]
where:
-n prints the cluster name
-w prints the clusterware version in the following format:
<major_version>:<minor_version>:<vendor_info>
$ cemutlo -n -w
xxhospital
2:1:
2.还可以使用olsnodes命令
$ which olsnodes
/u01/app/11.2.0.4/grid/bin/olsnodes
$ olsnodes -h
Usage: olsnodes [ [-n] [-i] [-s] [-t] [<node> | -l [-p]] | [-c] ] [-g] [-v]
where
-n print node number with the node name
-p print private interconnect address for the local node
-i print virtual IP address with the node name
<node> print information for the specified node
-l print information for the local node
-s print node status - active or inactive
-t print node type - pinned or unpinned
-g turn on logging
-v Run in debug mode; use at direction of Oracle Support only.
-c print clusterware name
$ olsnodes -c
xxhospital
$ olsnodes -c -v
lang init : Initializing LXL global
main: Initializing CLSS context
get cluster name: Get cluster nameprint data: Printing the node data
print data: lsdata has nodename = null
xxhospital
main: olsnodes executed successfully
term: Terminating LSF