这篇文章主要为大家展示了“RAC日常运行中基本启停命令有哪些”,内容简而易懂,条理清晰,希望能够帮助大家解决疑惑,下面让小编带领大家一起研究并学习一下“RAC日常运行中基本启停命令有哪些”这篇文章吧。RAC日常运行中一些基本启停命令总结
设置cluster不随着操作系统自动启动[root@rac01 u01]# crsctl disable crs CRS-4621: Oracle High Availability Services autostart is disabled.免费主机域名
设置cluster随着操作系统自动启动,默认是启动的[root@rac01 u01]# crsctl enable crs CRS-4622: Oracle High Availability Services autostart is enabled.
启动cluster,两个节点分别执行[root@rac01 u01]# crsctl start crs CRS-4123: Oracle High Availability Services has been started.[root@rac02 u01]# crsctl start crs CRS-4123: Oracle High Availability Services has been started.
查看cluster资源状态,在两个节点都可以查看。[root@rac01 u01]# crsctl status resource -t ——————————————————————————–NAME TARGET STATE SERVER STATE_DETAILS——————————————————————————–Local Resources——————————————————————————–ora.DATA.dgOFFLINE OFFLINE rac01OFFLINE OFFLINE rac02ora.LISTENER.lsnrONLINE ONLINE rac01ONLINE ONLINE rac02ora.OCR.dgONLINE ONLINE rac01ONLINE ONLINE rac02ora.asmONLINE ONLINE rac01 StartedONLINE ONLINE rac02 Startedora.eonsONLINE ONLINE rac01ONLINE ONLINE rac02ora.gsdOFFLINE OFFLINE rac01OFFLINE OFFLINE rac02ora.net1.networkONLINE ONLINE rac01ONLINE ONLINE rac02ora.onsONLINE ONLINE rac01ONLINE ONLINE rac02ora.registry.acfsONLINE ONLINE rac01ONLINE ONLINE rac02——————————————————————————–Cluster Resources——————————————————————————–ora.LISTENER_SCAN1.lsnr1 ONLINE ONLINE rac01ora.oc4j1 ONLINE ONLINE rac01ora.rac01.vip1 ONLINE ONLINE rac01ora.rac02.vip1 ONLINE ONLINE rac02ora.sap.db1 OFFLINE OFFLINE2 OFFLINE OFFLINEora.scan1.vip1 ONLINE ONLINE rac01
启动数据库实例,数据库实例名字为sap,在一个实例上执行即可[root@rac01 u01]# srvctl start database -d sap
查看cluster资源状态ora.sap.db状态为open[root@rac01 u01]# crsctl status resource -t ——————————————————————————–NAME TARGET STATE SERVER STATE_DETAILS——————————————————————————–Local Resources——————————————————————————–ora.DATA.dgONLINE ONLINE rac01ONLINE ONLINE rac02ora.LISTENER.lsnrONLINE ONLINE rac01ONLINE ONLINE rac02ora.OCR.dgONLINE ONLINE rac01ONLINE ONLINE rac02ora.asmONLINE ONLINE rac01 StartedONLINE ONLINE rac02 Startedora.eonsONLINE ONLINE rac01ONLINE ONLINE rac02ora.gsdOFFLINE OFFLINE r免费主机域名ac01OFFLINE OFFLINE rac02ora.net1.networkONLINE ONLINE rac01ONLINE ONLINE rac02ora.onsONLINE ONLINE rac01ONLINE ONLINE rac02ora.registry.acfsONLINE ONLINE rac01ONLINE ONLINE rac02——————————————————————————–Cluster Resources——————————————————————————–ora.LISTENER_SCAN1.lsnr1 ONLINE ONLINE rac01ora.oc4j1 ONLINE ONLINE rac01ora.rac01.vip1 ONLINE ONLINE rac01ora.rac02.vip1 ONLINE ONLINE rac02ora.sap.db1 ONLINE ONLINE rac01 Open 2 ONLINE ONLINE rac02 Open ora.scan1.vip1 ONLINE ONLINE rac01
查看数据库实例状态[root@rac02 u01]# srvctl status database -d sap Instance sap1 is running on node rac01Instance sap2 is running on node rac02查看nodeapps资源状态[root@rac01 rac01]# srvctl status nodeapps VIP rac01-vip is enabledVIP rac01-vip is running on node: rac01VIP rac02-vip is enabledVIP rac02-vip is running on node: rac02Network is enabledNetwork is running on node: rac01Network is running on node: rac02GSD is disabledGSD is not running on node: rac01GSD is not running on node: rac02ONS is enabledONS daemon is running on node: rac01ONS daemon is running on node: rac02eONS is enabledeONS daemon is running on node: rac01eONS daemon is running on node: rac02
查看listener状态[root@rac01 rac01]# srvctl status listener Listener LISTENER is enabledListener LISTENER is running on node(s): rac01,rac02
查看ASM状态[root@rac01 rac01]# srvctl status asm ASM is running on rac01,rac02
查看scan状态[root@rac01 rac01]# srvctl status scan SCAN VIP scan1 is enabledSCAN VIP scan1 is running on node rac01
查看ASM diskgroup状态[root@rac01 rac01]# srvctl status diskgroup PRKO-2082 : Missing mandatory option -g
[root@rac01 rac01]# srvctl status diskgroup -g data Disk Group data is running on rac01,rac02
停掉rac一个节点,例如停掉rac021、先停掉数据库实例,使用以下命令[root@rac01 rac01]# srvctl stop instance -d sap -n rac02 -o immediate
也可以使用以下命令,[root@rac01 rac01]# srvctl stop instance -d sap -i sap2 -o immediate
查看voting disk[root@rac01 rac01]# crsctl query css votedisk ## STATE File Universal Id File Name Disk group– —– —————– ——— ———1. ONLINE aeeaa395bb2b4fe0bff37dd0eaafe2c1 (/dev/disk/by-id/scsi-14f504e46494c4552667a507877412d6d616f452d63583051-part1) [OCR]Located 1 voting disk(s).
查看OCR[root@rac01 rac01]# ocrcheck Status of Oracle Cluster Registry is as follows :Version : 3Total space (kbytes) : 262120Used space (kbytes) : 2700Available space (kbytes) : 259420ID : 1248966756Device/File Name : +OCRDevice/File integrity check succeededDevice/File not configuredDevice/File not configuredDevice/File not configuredDevice/File not configuredCluster registry integrity check succeededLogical corruption check succeeded以上是“RAC日常运行中基本启停命令有哪些”这篇文章的所有内容,感谢各位的阅读!相信大家都有了一定的了解,希望分享的内容对大家有所帮助,如果还想学习更多知识,欢迎关注云技术行业资讯频道!
这篇文章主要介绍如何查询数据库数据量的大小,文中介绍的非常详细,具有一定的参考价值,感兴趣的小伙伴们一定要看完!查询一下数据库的数据量的大小,自己做了个脚免费主机域名本:以上是“如何查询数据库数据量的大小”这篇文章的所有内容,感谢各位的阅读!希望分享的内容对大…