oracle rac crsctl命令使用
oracle rac crsctl命令使用
查看crs资源状态 [grid@db1 ~]$ crs_stat -t Name Type Target State Host ------------------------------------------------------------ ora.DATA.dg ora....up.type ONLINE ONLINE db1 ora.FRA.dg ora....up.type ONLINE ONLINE db1 ora....ER.lsnr ora....er.type ONLINE ONLINE db1 ora....N1.lsnr ora....er.type ONLINE ONLINE db1 ora.OCR.dg ora....up.type ONLINE ONLINE db1 ora.asm ora.asm.type ONLINE ONLINE db1 ora.cvu ora.cvu.type ONLINE ONLINE db1 ora....SM1.asm application ONLINE ONLINE db1 ora....B1.lsnr application ONLINE ONLINE db1 ora.db1.gsd application OFFLINE OFFLINE ora.db1.ons application ONLINE ONLINE db1 ora.db1.vip ora....t1.type ONLINE ONLINE db1 ora....SM2.asm application ONLINE ONLINE db2 ora....B2.lsnr application ONLINE ONLINE db2 ora.db2.gsd application OFFLINE OFFLINE ora.db2.ons application ONLINE ONLINE db2 ora.db2.vip ora....t1.type ONLINE ONLINE db2 ora.dmzdb.db ora....se.type ONLINE ONLINE db1 ora.gsd ora.gsd.type OFFLINE OFFLINE ora....network ora....rk.type ONLINE ONLINE db1 ora.oc4j ora.oc4j.type ONLINE ONLINE db1 ora.ons ora.ons.type ONLINE ONLINE db1 ora.scan1.vip ora....ip.type ONLINE ONLINE db1 查看资源状态 [grid@db1 ~]$ crsctl stat res -t -------------------------------------------------------------------------------- NAME TARGET STATE SERVER STATE_DETAILS -------------------------------------------------------------------------------- Local Resources -------------------------------------------------------------------------------- ora.DATA.dg ONLINE ONLINE db1 ONLINE ONLINE db2 ora.FRA.dg ONLINE ONLINE db1 ONLINE ONLINE db2 ora.LISTENER.lsnr ONLINE ONLINE db1 ONLINE ONLINE db2 ora.OCR.dg ONLINE ONLINE db1 ONLINE ONLINE db2 ora.asm ONLINE ONLINE db1 Started ONLINE ONLINE db2 Started ora.gsd OFFLINE OFFLINE db1 OFFLINE OFFLINE db2 ora.net1.network ONLINE ONLINE db1 ONLINE ONLINE db2 ora.ons ONLINE ONLINE db1 ONLINE ONLINE db2 -------------------------------------------------------------------------------- Cluster Resources -------------------------------------------------------------------------------- ora.LISTENER_SCAN1.lsnr 1 ONLINE ONLINE db1 ora.cvu 1 ONLINE ONLINE db1 ora.db1.vip 1 ONLINE ONLINE db1 ora.db2.vip 1 ONLINE ONLINE db2 ora.dmzdb.db 1 ONLINE ONLINE db1 Open 2 ONLINE ONLINE db2 Open ora.oc4j 1 ONLINE ONLINE db1 ora.scan1.vip 1 ONLINE ONLINE db1 [grid@db1 ~]$ 查看资源 [grid@db1 ~]$ crs_stat NAME=ora.DATA.dg TYPE=ora.diskgroup.type TARGET=ONLINE STATE=ONLINE on db1 NAME=ora.FRA.dg TYPE=ora.diskgroup.type TARGET=ONLINE STATE=ONLINE on db1 NAME=ora.LISTENER.lsnr TYPE=ora.listener.type TARGET=ONLINE STATE=ONLINE on db1 NAME=ora.LISTENER_SCAN1.lsnr TYPE=ora.scan_listener.type TARGET=ONLINE STATE=ONLINE on db1 NAME=ora.OCR.dg TYPE=ora.diskgroup.type TARGET=ONLINE STATE=ONLINE on db1 NAME=ora.asm TYPE=ora.asm.type TARGET=ONLINE STATE=ONLINE on db1 NAME=ora.cvu TYPE=ora.cvu.type TARGET=ONLINE STATE=ONLINE on db1 NAME=ora.db1.ASM1.asm TYPE=application TARGET=ONLINE STATE=ONLINE on db1 NAME=ora.db1.LISTENER_DB1.lsnr TYPE=application TARGET=ONLINE STATE=ONLINE on db1 NAME=ora.db1.gsd TYPE=application TARGET=OFFLINE STATE=OFFLINE NAME=ora.db1.ons TYPE=application TARGET=ONLINE STATE=ONLINE on db1 NAME=ora.db1.vip TYPE=ora.cluster_vip_net1.type TARGET=ONLINE STATE=ONLINE on db1 NAME=ora.db2.ASM2.asm TYPE=application TARGET=ONLINE STATE=ONLINE on db2 NAME=ora.db2.LISTENER_DB2.lsnr TYPE=application TARGET=ONLINE STATE=ONLINE on db2 NAME=ora.db2.gsd TYPE=application TARGET=OFFLINE STATE=OFFLINE NAME=ora.db2.ons TYPE=application TARGET=ONLINE STATE=ONLINE on db2 NAME=ora.db2.vip TYPE=ora.cluster_vip_net1.type TARGET=ONLINE STATE=ONLINE on db2 NAME=ora.dmzdb.db TYPE=ora.database.type TARGET=ONLINE STATE=ONLINE on db1 NAME=ora.gsd TYPE=ora.gsd.type TARGET=OFFLINE STATE=OFFLINE NAME=ora.net1.network TYPE=ora.network.type TARGET=ONLINE STATE=ONLINE on db1 NAME=ora.oc4j TYPE=ora.oc4j.type TARGET=ONLINE STATE=ONLINE on db1 NAME=ora.ons TYPE=ora.ons.type TARGET=ONLINE STATE=ONLINE on db1 NAME=ora.scan1.vip TYPE=ora.scan_vip.type TARGET=ONLINE STATE=ONLINE on db1 [grid@db1 ~]$ check crs 状态 [grid@db1 ~]$ crsctl check crs CRS-4638: Oracle High Availability Services is online CRS-4537: Cluster Ready Services is online CRS-4529: Cluster Synchronization Services is online CRS-4533: Event Manager is online root用户下加入如下内容 export ORACLE_HOME=/u01/app/11.2.0/grid/ PATH=${PATH}:$ORACLE_HOME/bin [root@db1 ~]# cat .bash_profile # .bash_profile # Get the aliases and functions if [ -f ~/.bashrc ]; then . ~/.bashrc fi # User specific environment and startup programs PATH=$PATH:$HOME/bin export PATH export ORACLE_HOME=/u01/app/11.2.0/grid/ PATH=${PATH}:$ORACLE_HOME/bin [root@db1 ~]# 停crs之前一般要停监听,停库(先停监听,在停库,防止新会话上来) [grid@db1 ~]$ srvctl stop listener -n db1 [grid@db1 ~]$ srvctl stop instance -d dmzdb -i dmzdb1 停db1 crs [root@db1 ~]# crsctl stop crs CRS-2791: Starting shutdown of Oracle High Availability Services-managed resources on 'db1' CRS-2673: Attempting to stop 'ora.crsd' on 'db1' CRS-2790: Starting shutdown of Cluster Ready Services-managed resources on 'db1' CRS-2673: Attempting to stop 'ora.FRA.dg' on 'db1' CRS-2673: Attempting to stop 'ora.OCR.dg' on 'db1' CRS-2673: Attempting to stop 'ora.dmzdb.db' on 'db1' CRS-2673: Attempting to stop 'ora.oc4j' on 'db1' CRS-2673: Attempting to stop 'ora.LISTENER.lsnr' on 'db1' CRS-2673: Attempting to stop 'ora.cvu' on 'db1' CRS-2673: Attempting to stop 'ora.LISTENER_SCAN1.lsnr' on 'db1' CRS-2677: Stop of 'ora.LISTENER.lsnr' on 'db1' succeeded CRS-2673: Attempting to stop 'ora.db1.vip' on 'db1' CRS-2677: Stop of 'ora.LISTENER_SCAN1.lsnr' on 'db1' succeeded CRS-2673: Attempting to stop 'o
- 更多Oracle疑问解答:
- 运行exp备份oracle数据库提示oracle-12154错误
- 有没有,生产Oracle Rman 备份脚本的工具啊!
- 初学orcle,希望有大大帮忙解说一下详细步骤,从登录oracle到创建表的过程
- oracle语句问题:一张user表,三个字段,id,name,time,插入记录比如:张三2007,李四2008,张三2011
- 如何写一个ORACLE触发器同步两个表中的数据?
- oracle 如何查看一个服务器上有多少个数据库.
- oracle 创建包的时候错误 求解
- oracle 重复列的问题
- oracle 中如何查处2星期前的数据
- 请教oracle数据库安装中的问题
- 请问谁能提供给我标准的oracle ERP的数据库表结构并详细说明各表主要的作用?
- 安装oracle遇到的问题 invalid entry CRC (expected 0x3e12e795 but got 0x9db0e9fd)
- 我的是ORACLE 10G,在RMAN中如何按指定的时间恢复数据文件啊?
- oracle为什么没有自动增长列
- oracle快捷键都有哪些啊?