Oracle RAC

2021/9/11 2:05:06

本文主要是介绍Oracle RAC,对大家解决编程问题具有一定的参考价值,需要的程序猿们随着小编来一起学习吧!

RAC异常重启分析
-----信息收集命令:
/u01/app/grid/grid_home/tfa/bin/tfactl diagcollect -from "Aug/5/2020 22:00:00" -to "Aug/5/2020 23:00:00" 
-----如果命令执行报错,使用下面命令启动tfa后再执行收集:
/u01/app/grid/grid_home/tfa/bin/tfactl start

修改KDUMP和重启
-----修改KDUMP配置
root执行,crsctl 用绝对路径:
[grid@xxxxx ~]$ which crsctl
/u01/app/grid/grid_home/bin/crsctl

【root】
/u01/app/grid/grid_home/bin/crsctl modify type ora.cssd.type -attr "ATTRIBUTE=REBOOT_OPTS, TYPE=string,DEFAULT_VALUE=,FLAGS=CONFIG" -init
/u01/app/grid/grid_home/bin/crsctl modify res ora.cssd -attr "REBOOT_OPTS=CRASHDUMP" -init
/u01/app/grid/grid_home/bin/crsctl modify type ora.cssdmonitor.type -attr "ATTRIBUTE=REBOOT_OPTS,TYPE=string,DEFAULT_VALUE=,FLAGS=CONFIG" -init
/u01/app/grid/grid_home/bin/crsctl modify res ora.cssdmonitor -attr "REBOOT_OPTS=CRASHDUMP" -init

RAC停库
srvctl stop database -d 
或者:进入每个库,shutdown immediate

停监听
srvctl stop LISTENER

取消自启动
/u01/app/grid/grid_home/bin/crsctl disable crs
/u01/app/grid/grid_home/bin/crsctl stop crs


机器重启后,开启自启动
/u01/app/grid/grid_home/bin/crsctl enable crs
/u01/app/grid/grid_home/bin/crsctl start crs

export ORACLE_SID=
startup;
export ORACLE_SID=
startup;

看集群状态
/u01/app/grid/grid_home/bin/crsctl stat res -t

启动监听
srvctl start listener -n cxdxdb1

SQL> select instance_name,startup_time,status from gv$instance;
INSTANCE_NAME    STARTUP_TIME        STATUS
---------------- ------------------- ------------
xxxxx2          2020-08-09 23:59:45 OPEN
xxxxx1          2020-01-23 07:17:03 OPEN

最后 crsctl stat res -t   中除了 gsd和oc4j,其他进程起来就ok了

查看进程:
SELECT sid, serial#, username, osuser FROM v$session;



这篇关于Oracle RAC的文章就介绍到这儿,希望我们推荐的文章对大家有所帮助,也希望大家多多支持为之网!


扫一扫关注最新编程教程