Comnnect oracle,RAC监听日志与CRS日志
RAC監聽日志:tnsname.ora
CRS日志:
位置:Oracle集群涉及的日志主要位于“$ORA_CRS_HOME/log”和“$ORACLE_HOME/log”目錄中
目錄結構:tree -d $ORA_CRS_HOME/log
tree -d $ORACLE_HOME/log
禁止Clusterware在系統重啟后自動啟動:/etc/init.d/init.crs disable
讓Clusterware在系統重啟后自動啟動: /etc/init.d/init.crs enable
啟動CRS;crsctl start crs
關閉CRS:crsctl stop crs
檢查CRS狀態:RAC1 AND RAC2: crsctl check crs
啟動數據庫:
$srvctl start nodeapps -n rac1
$srvctl start nodeapps -n rac2
$srvctl start asm -n rac1
$srvctl start asm -n rac2
$srvctl start instance -d racdb -i racdb1
$srvctl start instance -d racdb -i racdb2
oracle rac crs
格式:ora.hostname.ASM2.asm,節點1格式:ora.hostname.ASM1.asm)
Attempting to stop `ora.node2.ASM2.asm` on member `node2`
Stop of `ora.node2.ASM2.asm` on member `node2` succeeded.
node2-> crs_start ora.node2.ASM2.asm
Attempting to start `ora.node2.ASM2.asm` on member `node2`
Start of `ora.node2.ASM2.asm` on member `node2` succeeded.
2、--單獨啟動和關閉節點node2的gsd
crs_stop ora.node2.gsd?? (格式:ora.hostname.gsd)
crs_start ora.node2.gsd
3、--單獨啟動和關閉節點node2的ons
crs_stop ora.node2.ons? (格式:ora.hostname.ons)
crs_start ora.node2.ons
4.單獨啟動vip
crs_stop ora.node2.vip(格式:ora.hostname.vip)
crs_start ora.node2.vip
5.單獨啟動實例(inst)
crs_stop? ora.racdb.racdb2.inst (格式:ora.db_name.instance_name.inst)
crs_start ora.racdb.racdb2.inst
6.單獨啟動監聽(lsnr)
crs_stop ora.node1.LISTENER_NODE1.lsnr (格式:ora.hostname.listener_name.lsnr)
crs_start ora.node1.LISTENER_NODE1.lsnr
#查看crs的資源是否起來
node1-> crs_stat -t
Name?????????? Type?????????? Target??? State???? Host
------------------------------------------------------------
ora....SM1.asm application??? ONLINE??? ONLINE??? node1
ora....E1.lsnr application??? ONLINE??? ONLINE??? node1
ora.node1.gsd? application??? ONLINE??? ONLINE??? node1
ora.node1.ons? application??? ONLINE??? ONLINE??? node1
ora.node1.vip? application??? ONLINE??? ONLINE??? node1
ora....SM2.asm application??? ONLINE??? ONLINE??? node2
ora....E2.lsnr application??? ONLINE??? ONLINE??? node2
ora.node2.gsd? application??? ONLINE??? ONLINE??? node2
ora.node2.ons? application??? ONLINE??? ONLINE??? node2
ora.node2.vip? application??? ONLINE??? ONLINE??? node2
ora.racdb.db?? application??? ONLINE??? ONLINE??? node1
ora....b1.inst application??? ONLINE??? ONLINE??? node1
ora....b2.inst application??? ONLINE??? ONLINE??? node2
*********顯示resource信息*******
node2-> srvctl config database
racdb
node2-> srvctl config database -d racdb -t
node2-> srvctl config nodeapps -n node2
node2 racdb2 /opt/ora10g/product/10.2.0/db_1
# display VIP configuration
node2-> srvctl config nodeapps -n node2 -a
VIP exists.: /node2-vip/192.168.0.202/255.255.255.0/eth0
# display GSD configuration
node2-> srvctl config nodeapps -n node2 -g
GSD exists.
# display OSD configuration
node2-> srvctl config nodeapps -n node2 -s
ONS daemon exists.
# display Listener configuration
node2-> srvctl config nodeapps -n node2 -l
Listener exists.
#display database status
node2-> srvctl status database -d racdb
Instance racdb1 is running on node node1
Instance racdb2 is running on node node2
node2->
#查看Voting Disk位置
node2-> crsctl query css votedisk
0.???? 0??? /dev/raw/raw1
located 1 votedisk(s).
查看OCR存放路徑:cat /etc/oracle/ocr.loc
#顯示節點2application狀態
node2-> srvctl? status nodeapps -n node2
VIP is running on node: node2
GSD is running on node: node2
Listener is running on node: node2
ONS daemon is running on node: node2
#顯示節點2asm狀態
node2-> srvctl? status asm -n node1
ASM instance +ASM1 is running on node node1.
node2-> srvctl? status asm -n node2
ASM instance +ASM2 is running on node node2.
node2-> srvctl? status nodeapps -n node1
VIP is running on node: node1
GSD is running on node: node1
Listener is running on node: node1
ONS daemon is running on node: node1
OCR的狀態驗證
node2-> ocrcheck
Status of Oracle Cluster Registry is as follows :
Version????????????????? :????????? 2
Total space (kbytes)???? :???? 524184
Used space (kbytes)????? :?????? 3796
Available space (kbytes) :???? 520388
ID?????????????????????? : 1474691778
Device/File Name???????? : /dev/raw/raw2
Device/File integrity check succeeded
Device/File not configured
Cluster registry integrity check succeeded
#查看crs是否啟動
$ crsctl check crs
CSS appears healthy
CRS appears healthy
EVM appears healthy
關閉crs資源
# cd $ORA_CRS_HOME/bin
# ./crsctl stop crs
啟動crs資源
# cd $ORA_CRS_HOME/bin
# ./crsctl start crs
#查看/啟動/關閉數據庫實例
srvctl status|stop|start instance -d [db_name] -i [inst_name]
srvctl status|stop|start database -d [db_name]
eg:
node2-> srvctl status database -d racdb
Instance racdb1 is running on node node1
Instance racdb2 is running on node node2
#啟動/查看/關閉asm實例
srvctl status|stop|start asm -n [node_name]
eg:
node2-> srvctl status asm -n node1
ASM instance +ASM1 is running on node node1.
node2-> srvctl status asm -n node2
ASM instance +ASM2 is running on node node2.
#啟動/查看/關閉nodeapps資源
node2-> srvctl status nodeapps -n node2
VIP is running on node: node2
GSD is running on node: node2
Listener is running on node: node2
ONS daemon is running on node: node2
總結
以上是生活随笔為你收集整理的Comnnect oracle,RAC监听日志与CRS日志的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: oracle agile 性能,Orac
- 下一篇: Soulapp这个是什么(cn.soul