您好,登錄后才能下訂單哦!
這篇文章主要講解了“RAC日常運(yùn)維怎么查看服務(wù)器iptables是否關(guān)閉”,文中的講解內(nèi)容簡單清晰,易于學(xué)習(xí)與理解,下面請大家跟著小編的思路慢慢深入,一起來研究和學(xué)習(xí)“RAC日常運(yùn)維怎么查看服務(wù)器iptables是否關(guān)閉”吧!
查看服務(wù)器iptables是否關(guān)閉(每個(gè)節(jié)點(diǎn)都要查看)
[root@its032 ~]# chkconfig --list | grep tables
ip6tables 0:off 1:off 2:off 3:off 4:off 5:off 6:off
iptables 0:off 1:off 2:off 3:off 4:off 5:off 6:off
查看asm共享盤信息(每個(gè)節(jié)點(diǎn)都要查看)
[root@its032 ~]# oracleasm listdisks
ARCH1
DATA1
DATA2
DATA3
OCRVOTE
列出配置的所有數(shù)據(jù)庫
[root@node1 ~]# srvctl config database
NOVADB
所有實(shí)例和服務(wù)的狀態(tài)
[root@node1 ~]# srvctl status database -d NOVADB
Instance NOVADB1 is running on node node1
Instance NOVADB2 is running on node node2
單個(gè)實(shí)例的狀態(tài)
[root@node1 ~]# srvctl status instance -d NOVADB -i NOVADB1
Instance NOVADB1 is running on node node1
在數(shù)據(jù)庫全局命名服務(wù)的狀態(tài)
$ srvctl status service -d orcl -s orcltest
Service orcltest is running on instance(s) orcl2, orcl1
特定節(jié)點(diǎn)上節(jié)點(diǎn)應(yīng)用程序的狀態(tài)
[root@node1 ~]# 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
ASM 實(shí)例的狀態(tài)
[root@node1 ~]# srvctl status asm -n node1
ASM instance +ASM1 is running on node node1.
[root@node1 ~]# srvctl status asm -n node2
ASM instance +ASM2 is running on node node2.
顯示 RAC 數(shù)據(jù)庫的配置
[root@node1 ~]# srvctl config database -d NOVADB
node1 NOVADB1 /opt/ora10g/product/10.2.0/db_1
node2 NOVADB2 /opt/ora10g/product/10.2.0/db_1
顯示指定集群數(shù)據(jù)庫的所有服務(wù)
[root@node1 ~]# srvctl config service -d NOVADB
NOVADB PREF: NOVADB1 NOVADB2 AVAIL:
顯示節(jié)點(diǎn)應(yīng)用程序的配置 —(VIP、GSD、ONS、監(jiān)聽器)
[root@node1 ~]# srvctl config nodeapps -n node1 -a -g -s -l
VIP exists.: /node1-vip/192.168.150.224/255.255.255.0/eth0
GSD exists.
ONS daemon exists.
Listener exists.
利用srvctl config命令可以看到現(xiàn)有數(shù)據(jù)庫的配置信息:
[root@node1 ~]# srvctl config database -d NOVADB -a
node1 NOVADB1 /opt/ora10g/product/10.2.0/db_1
node2 NOVADB2 /opt/ora10g/product/10.2.0/db_1
DB_NAME: NOVADB
ORACLE_HOME: /opt/ora10g/product/10.2.0/db_1
SPFILE: +RAC_DISK/NOVADB/spfileNOVADB.ora
DOMAIN: null
DB_ROLE: null
START_OPTIONS: null
POLICY: AUTOMATIC
ENABLE FLAG: DB ENABLED
顯示 ASM 實(shí)例的配置
[root@node1 ~]# srvctl config asm -n node1
+ASM1 /opt/ora10g/product/10.2.0/db_1
[root@node1 ~]# srvctl config asm -n node2
+ASM2 /opt/ora10g/product/10.2.0/db_1
集群中所有正在運(yùn)行的實(shí)例
SQL>
SELECT inst_id, instance_number inst_no , instance_name inst_name, parallel , status , database_status db_status , active_state state , host_name host FROM gv$instance
ORDER BY inst_id
INST_ID INST_NO INST_NAME PAR STATUS DB_STATUS STATE
———- ———- —————- — ———— —————– ——
1 1 NOVADB1 YES OPEN ACTIVE NORMAL
2 2 NOVADB2 YES OPEN ACTIVE NORMAL
SQL>
位于磁盤組中的所有數(shù)據(jù)文件
SQL> select name from v$datafile
union
select member from v$logfile
union
select name from v$controlfile
union
select name from v$tempfile;
NAME
——————————————————————————–
+RAC_DISK/novadb/controlfile/current.260.685491565
+RAC_DISK/novadb/datafile/nova_test.268.686337643
+RAC_DISK/novadb/datafile/sysaux.257.685491407
+RAC_DISK/novadb/datafile/system.256.685491401
+RAC_DISK/novadb/datafile/undotbs1.258.685491411
+RAC_DISK/novadb/datafile/undotbs2.264.685491733
+RAC_DISK/novadb/datafile/users.259.685491413
+RAC_DISK/novadb/onlinelog/group_1.261.685491571
+RAC_DISK/novadb/onlinelog/group_2.262.685491575
+RAC_DISK/novadb/onlinelog/group_3.265.685491915
+RAC_DISK/novadb/onlinelog/group_4.266.685491921
NAME
——————————————————————————–
+RAC_DISK/novadb/tempfile/temp.263.685491617
12 rows selected.
SQL>
屬于“RAC_DISK”磁盤組的所有 ASM 磁盤
SQL> SELECT path FROM v$asm_disk WHERE group_number IN (select group_number from v$asm_diskgroup where name = ‘RAC_DISK’);
PATH
——————————————————————————–
/dev/raw/raw3
/dev/raw/raw4
ORCL:NOVA3
啟動(dòng)/停止RAC集群
確保是以 oracle UNIX 用戶登錄的。我們將從rac1節(jié)點(diǎn)運(yùn)行所有命令:
# su – oracle
[oracle@node1 ~]$ hostname
node1
停止 Oracle RAC 10g 環(huán)境
第一步是停止 Oracle 實(shí)例。當(dāng)此實(shí)例(和相關(guān)服務(wù))關(guān)閉后,關(guān)閉 ASM 實(shí)例。最后,關(guān)閉節(jié)點(diǎn)應(yīng)用程序(虛擬 IP、GSD、TNS 監(jiān)聽器和 ONS)。
[oracle@node1 ~]$ export ORACLE_SID=NOVADB1
[oracle@node1 ~]$ emctl stop dbconsole
[oracle@node1 ~]$ srvctl stop instance -d NOVADB -i NOVADB1
[oracle@node1 ~]$ srvctl stop asm -n node1
[oracle@node1 ~]$ srvctl stop nodeapps –n node1
啟動(dòng) Oracle RAC 10g 環(huán)境
第一步是啟動(dòng)節(jié)點(diǎn)應(yīng)用程序(虛擬 IP、GSD、TNS 監(jiān)聽器和 ONS)。當(dāng)成功啟動(dòng)節(jié)點(diǎn)應(yīng)用程序后,啟動(dòng) ASM 實(shí)例。最后,啟動(dòng) Oracle 實(shí)例(和相關(guān)服務(wù))以及企業(yè)管理器數(shù)據(jù)庫控制臺。
[oracle@node1 ~]$ export ORACLE_SID=NOVADB
[oracle@node1 ~]$ srvctl start nodeapps -n node1
[oracle@node1 ~]$ srvctl start asm -n node1
[oracle@node1 ~]$ srvctl start instance -d NOVADB -i NOVADB1
[oracle@node1 ~]$ emctl start dbconsole
使用 SRVCTL 啟動(dòng)/停止所有實(shí)例
啟動(dòng)/停止所有實(shí)例及其啟用的服務(wù)。我只是覺得有意思就把此步驟作為關(guān)閉所有實(shí)例的一種方法加進(jìn)來了!
[oracle@node1 ~]$ srvctl start database -d NOVADB
[oracle@node1 ~]$ srvctl stop database -d NOVADB
啟停止監(jiān)聽
[oracle@node1 ~]$lsnrctl start listener_hostb
[oracle@node1 ~]$lsnrctl stop listener_hostb
以下沒經(jīng)過測試呢,等待測試,工作太忙了..
備份
votning diskdd if=voting_disk_name of=backup_file_name
dd if=/dev/rdsk/c4t600C0FF000000000098ADE240330A000d0s4 of=votingdisk.bak# dd if=/dev/zero of=/dev/rdsk/c4t600C0FF000000000098ADE240330A000d0s4 bs=512 count=261120
測試
# dd if=/dev/rdsk/c4t600C0FF000000000098ADE240330A000d0s4 of=/data/backup/rac/vd_backup0420.bak
261120+0 記錄進(jìn)入
261120+0 記錄調(diào)出
# cd /data/backup/rac
# ls
ocr0420.bak ocrdisk vd_backup0420.bak votingdisk.bak votingdisk0420.bak
# dd if=/data/backup/rac/vd_backup0420.bak of=/dev/rdsk/c4t600C0FF000000000098ADE240330A000d0s4
261120+0 記錄進(jìn)入
261120+0 記錄調(diào)出備份OCR磁盤
查看備份
$ocrconfig -showbackup
備份
/data/oracle/crs/bin/ocrconfig -export /data/backup/rac/ocrdisk.bak
還原 需要停掉所有的節(jié)點(diǎn),Stop the Oracle Clusterware software on all of the nodes
/data/oracle/crs/bin/ocrconfig -import file_name
自動(dòng)備份的還原
# /data/oracle/crs/bin/ocrconfig -showbackup
# /data/oracle/crs/bin/ocrconfig -restore /data/oracle/crs/cdata/db168crs/backup00.ocrhosta$cluvfy comp ocr -n all //檢驗(yàn)
ocr 檢查
#ocrcheck配置路徑在
/var/opt/oracle/ocrconfig_loc文件里面 如果需要更改OCR磁盤的路徑配置。
OCR磁盤空間檢查
# /data/oracle/crs/bin/ocrcheck
Status of Oracle Cluster Registry is as follows :
Version : 2
Total space (kbytes) : 399752
Used space (kbytes) : 3784
Available space (kbytes) : 395968
ID : 148562961
Device/File Name : /dev/rdsk/c4t600C0FF000000000098ADE240330A000d0s5
Device/File integrity check succeeded Device/File not configured Cluster registry integrity check succeeded#
感謝各位的閱讀,以上就是“RAC日常運(yùn)維怎么查看服務(wù)器iptables是否關(guān)閉”的內(nèi)容了,經(jīng)過本文的學(xué)習(xí)后,相信大家對RAC日常運(yùn)維怎么查看服務(wù)器iptables是否關(guān)閉這一問題有了更深刻的體會(huì),具體使用情況還需要大家實(shí)踐驗(yàn)證。這里是億速云,小編將為大家推送更多相關(guān)知識點(diǎn)的文章,歡迎關(guān)注!
免責(zé)聲明:本站發(fā)布的內(nèi)容(圖片、視頻和文字)以原創(chuàng)、轉(zhuǎn)載和分享為主,文章觀點(diǎn)不代表本網(wǎng)站立場,如果涉及侵權(quán)請聯(lián)系站長郵箱:is@yisu.com進(jìn)行舉報(bào),并提供相關(guān)證據(jù),一經(jīng)查實(shí),將立刻刪除涉嫌侵權(quán)內(nèi)容。