ITPub博客

首页 > 数据库 > Oracle > Oracle 11g RAC 常用命令

Oracle 11g RAC 常用命令

原创 Oracle 作者:梓沐 时间:2016-02-15 09:27:44 0 删除 编辑
1.检查集群状态

[grid@rac1 ~]$ crsctl check cluster
CRS-4537: Cluster Ready Services is online
CRS-4529: Cluster Synchronization Services is online
CRS-4533: Event Manager is online

2.检查所有实例状态

[grid@rac1 ~]$ srvctl status database -d orcl
Instance orcl1 is running on node rac1
Instance orcl2 is running on node rac2

3.节点应用程序状态

[grid@rac1 ~]$ srvctl status nodeapps
VIP rac1-vip is enabled
VIP rac1-vip is running on node: rac1
VIP rac2-vip is enabled
VIP rac2-vip is running on node: rac2
Network is enabled
Network is running on node: rac1
Network is running on node: rac2
GSD is disabled
GSD is not running on node: rac1
GSD is not running on node: rac2
ONS is enabled
ONS daemon is running on node: rac1
ONS daemon is running on node: rac2

4.数据库配置

[grid@rac1 ~]$ srvctl config database -d orcl -a
Database unique name: orcl
Database name: orcl
Oracle home: /u01/app/oracle/product/11.2.0/db_1
Oracle user: oracle
Spfile: +DATADG/orcl/spfileorcl.ora
Domain:
Start options: open
Stop options: immediate
Database role: PRIMARY
Management policy: AUTOMATIC
Server pools: orcl
Database instances: orcl1,orcl2
Disk Groups: DATADG,SYSTEMDG
Mount point paths:
Services:
Type: RAC
Database is enabled
Database is administrator managed

5.ASM状态及配置

[grid@rac1 ~]$ srvctl status asm
ASM is running on rac2,rac1

[grid@rac1 ~]$ srvctl config asm -a
ASM home: /u01/app/11.2.0/grid
ASM listener: LISTENER
ASM is enabled.

6.TNS监听状态及配置

[grid@rac1 ~]$ srvctl status listener
Listener LISTENER is enabled
Listener LISTENER is running on node(s): rac2,rac1

[grid@rac1 ~]$ srvctl config listener -a
Name: LISTENER
Network: 1, Owner: grid
Home: <CRS home>
  /u01/app/11.2.0/grid on node(s) rac1,rac2
End points: TCP:1521

7.SCAN状态及配置

[grid@rac1 ~]$ srvctl status scan
SCAN VIP scan1 is enabled
SCAN VIP scan1 is running on node rac1

[grid@rac1 ~]$ srvctl config scan
SCAN name: rac-cluster-scan, Network: 1/192.168.8.0/255.255.255.0/eth0
SCAN VIP name: scan1, IP: /rac-cluster-scan/192.168.8.225

8.VIP各个节点的状态及配置

[grid@rac1 ~]$ srvctl status vip -n rac1
VIP rac1-vip is enabled
VIP rac1-vip is running on node: rac1
[grid@rac1 ~]$ srvctl status vip -n rac2
VIP rac2-vip is enabled
VIP rac2-vip is running on node: rac2
[grid@rac1 ~]$ srvctl config vip -n rac1
VIP exists: /rac1-vip/192.168.8.222/192.168.8.0/255.255.255.0/eth0, hosting node rac1
[grid@rac1 ~]$ srvctl config vip -n rac2
VIP exists: /rac2-vip/192.168.8.224/192.168.8.0/255.255.255.0/eth0, hosting node rac2

10.验证所有集群节点间的时钟同步

[grid@rac1 ~]$ cluvfy comp clocksync -verbose

Verifying Clock Synchronization across the cluster nodes

Checking if Clusterware is installed on all nodes...
Check of Clusterware install passed

Checking if CTSS Resource is running on all nodes...
Check: CTSS Resource running on all nodes
  Node Name                             Status
  ------------------------------------  ------------------------
  rac1                                  passed
Result: CTSS resource check passed


Querying CTSS for time offset on all nodes...
Result: Query of CTSS for time offset passed

Check CTSS state started...
Check: CTSS state
  Node Name                             State
  ------------------------------------  ------------------------
  rac1                                  Active
CTSS is in Active state. Proceeding with check of clock time offsets on all nodes...
Reference Time Offset Limit: 1000.0 msecs
Check: Reference Time Offset
  Node Name     Time Offset               Status
  ------------  ------------------------  ------------------------
  rac1          0.0                       passed

Time offset is within the specified limits on the following set of nodes:
"[rac1]"
Result: Check of clock time offsets passed


Oracle Cluster Time Synchronization Services check passed

Verification of Clock Synchronization across the cluster nodes was successful.




来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/29812844/viewspace-1988790/ ,如需转载,请注明出处,否则将追究法律责任。

请登录后发表评论 登录
全部评论
擅长PLS/QL开发,SQL调优和改写,数据库设计

注册时间:2014-08-18

  • 博文量
    161
  • 访问量
    1204428