Standby 庫, 根盤暴滿,虛驚一場 [原創]
突然收到備庫上以下錯誤,嚇了一大跳,hehe
根盤空間有3多個G呀,怎麼會突然暴滿?
哎,別想了,先解決問題要緊
Jul 28 16:20:13 hpdb2 vmunix: vxfs: NOTICE: msgcnt 1895 mesg 001: V-2-1: vx_nospace - /dev/root file system full (1 block ext
ent)
Jul 28 16:20:28 hpdb2 vmunix: vxfs: NOTICE: msgcnt 1897 mesg 001: V-2-1: vx_nospace - /dev/root file system full (1 block ext
ent)
Jul 28 16:20:56 hpdb2 vmunix: vxfs: NOTICE: msgcnt 1899 mesg 001: V-2-1: vx_nospace - /dev/root file system full (1 block ext
ent)
Jul 28 16:21:15 hpdb2 vmunix: vxfs: NOTICE: msgcnt 1901 mesg 001: V-2-1: vx_nospace - /dev/root file system full (1 block ext
ent)
Jul 28 16:21:30 hpdb2 vmunix: vxfs: NOTICE: msgcnt 1903 mesg 001: V-2-1: vx_nospace - /dev/root file system full (1 block ext
ent)
bdf確認了一下,根盤使用100%了.汗一個。
root@hpdb2:/jbindx02/oraindx/indx #bdf
Filesystem kbytes used avail %used Mounted on
/dev/vg00/lvol3 3145728 3145728 0 100% /
/dev/vg00/lvol1 505392 129008 325840 28% /stand
/dev/vg00/lvol8 5242880 1534784 3679208 29% /var
/dev/vg00/lvol7 5242880 2020824 3196896 39% /usr
/dev/vg00/u01 14680064 8635816 5998560 59% /u01
/dev/vg00/lvol6 2097152 1050976 1038128 50% /tmp
/dev/vg00/lvol5 5996544 3900936 2079272 65% /opt
/dev/vg00/lvol4 524288 83336 437552 16% /home
/dev/vgdgehrdata/lvolvgdgehrdata
819200000 435723320 380480784 53% /dgehrdata
/dev/vgdgehrarch/lvolvgdgehrarch
256000000 165329936 89961952 65% /dgehrarch
/dev/vgdba01/lvoldba01
1331232768 8767432 1312133584 1% /dba01
/dev/vgdba02/lvoldba02
1331232768 61856 1320771152 0% /dba02
/dev/vgdgjbarch/lvolvgdgjbarch
363528192 112804792 248764768 31% /dgjbarch
/dev/vgdgjbdata/lvolvgdgjbdata
1873936384 1122876504 745192272 60% /dgjbdata
糊亂找了一通,終於發現以下目錄下多出了兩個oracle的資料檔案.
root@hpdb2:/jbindx02/oraindx/indx #ll
total 5596240
-rw-r----- 1 oracle dba 2097160192 Jul 28 09:24 rsm_idx80.dbf
-rw-r----- 1 oracle dba 771751936 Jul 28 09:24 rsm_idx81.dbf
嘿嘿,發現了就趕快刪除吧,別急哦,不能刪除? 為什麼呢,請聽我慢慢道來.(這裡有點繞)
先說明介紹一下系統架構.
這個出問題的主機(簡稱Q主機),這個主機既是其他三臺主機的HA(MC/SG),又是這臺三臺主機上資料的standby(Oracle/DG).
上面各位看到的那個/jbindx02/oraindx/indx 目錄,其實是給HA/Clustering用的,一個沒有mount任何儲存的目錄。
而dataguard其實是用得另外一套目錄,由於在一臺主庫上有一個存放索引的目錄/jbindx02/oraindx/indx 一直沒有存放資料檔案進去,所以就忘記了加在 db_file_name_convert中,今天加表空間時,看到其他目錄快滿了,就向這個目錄放資料檔案了,所以就造成了以上問題。
問題找到了,想辦法解決備庫問題吧.
解決過程如下:
1.先檢視一下alert.log
WARNING: File being created with same name as in Primary
Existing file may be overwritten
Mon Jul 28 09:24:10 2008
File #546 added to control file as 'UNNAMED00546'.
Originally created as:
'/jbindx02/oraindx/indx/rsm_idx81.dbf'
Recovery was unable to create the file as:
'/jbindx02/oraindx/indx/rsm_idx81.dbf'
Errors with log /dgjbarch/dgjb_1_27376_638807858.log
MRP0: Background Media Recovery terminated with error 19502
Mon Jul 28 09:24:10 2008
Errors in file /u01/oracle/admin/hpjob/bdump/dghpjob_mrp0_21025.trc:
ORA-19502: write error on file "/jbindx02/oraindx/indx/rsm_idx81.dbf", blockno 93696 (blocksize=8192)
ORA-27072: File I/O error
HP-UX Error: 2: No such file or directory
Additional information: 4
Additional information: 93696
Additional information: 540672
Mon Jul 28 09:24:51 2008
Some recovered datafiles maybe left media fuzzy
Media recovery may continue but open resetlogs may fail
Mon Jul 28 09:24:51 2008
Errors in file /u01/oracle/admin/hpjob/bdump/dghpjob_mrp0_21025.trc:
ORA-19502: write error on file "/jbindx02/oraindx/indx/rsm_idx81.dbf", blockno 93696 (blocksize=8192)
ORA-27072: File I/O error
HP-UX Error: 2: No such file or directory
Additional information: 4
Additional information: 93696
Additional information: 540672
Mon Jul 28 09:24:51 2008
MRP0: Background Media Recovery process shutdown (dghpjob)
2.先停止恢復
alter database recover managed standby database cancel ;
3.把需要轉用的目錄加進去
ALTER SYSTEM SET db_file_name_convert='xxx,xxx' scope=both;
4.關閉資料庫
shtudown immediate;
5.移動資料檔案
mv rsm_idx80.dbf /xxxx
mv rsm_idx81.dbf /xxxx
6.啟動資料庫到mount
ALTER SYSTEM SET standby_file_management='MANUAL' SCOPE=BOTH;
alter database rename file '/jbindx02/oraindx/indx/rsm_idx80.dbf' to '/dgjbdata/indx/rsm_idx80.dbf' ;
---成功
alter database rename file '/jbindx02/oraindx/indx/rsm_idx80.dbf' to '/dgjbdata/indx/rsm_idx80.dbf' ;
---失敗(錯誤資訊如下)
ORA-01111: name for data file 546 is unknown - rename to correct file
ORA-01110: data file 546: '/u01/oracle/product/10.2.0.3/dbs/UNNAMED00546'
ORA-01157: cannot identify/lock data file 546 - see DBWR trace file
ORA-01111: name for data file 546 is unknown - rename to correct file
ORA-01110: data file 546: '/u01/oracle/product/10.2.0.3/dbs/UNNAMED00546'
其實從上面看這個檔案的大小和alert.log中的資訊,已經知道了,這個檔案沒有建立成功。
7.對這個損壞的檔案進行恢復
SQL> select name from v$datafile where file# = 546;
NAME
--------------------------------------------------------------------------------
/u01/oracle/product/10.2.0.3/dbs/UNNAMED00546
SQL> alter database create datafile '/u01/oracle/product/10.2.0.3/dbs/UNNAMED00546' as '/dgjbdata/indx/rsm_idx81.dbf';
Database altered.
SQL> select name from v$datafile where file# = 546;
NAME
--------------------------------------------------------------------------------
/dgjbdata/indx/rsm_idx81.dbf
-------過來了^_^
SQL> alter system set standby_file_management=AUTO scope=both;
SQL> alter database create datafile '/u01/oracle/product/10.2.0.3/dbs/UNNAMED00546' as '/dgjbdata/indx/rsm_idx81.dbf';
Database altered.
8.切換到恢復狀態下
ALTER DATABASE RECOVER managed standby database disconnect from session
9.完工了,回家鳥 ^_^
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/7364032/viewspace-414942/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- Standby 庫, 根盤暴滿,虛驚一場 [zt]
- dataguard standby備庫磁碟空間滿(ZT)
- 虛驚一場(使用工具執行命令的後果)
- 【原創】Linux虛擬化KVM-Qemu分析(一)Linux
- 美日韓出海市場Q3覆盤:出海遊戲再創新高,美區收入暴增127%遊戲
- RAC資料庫建立STANDBY(一)資料庫
- [原創]XCodeGhost詳細技術分析[XCodeGhost內幕暴料]XCode
- 物理Standby資料庫及邏輯Standby資料庫(Physical Standby & Logical Standby)資料庫
- 庫存批量規則(原創)
- 大牛教你查庫暴庫
- 原根與 NTT
- HPUX中vg00根盤映象配置方法(一)UX
- 【原創】手工建立Oracle資料庫Oracle資料庫
- 【原創】VB P-code -- 虛擬碼的奧祕
- 【原創】Linux虛擬化KVM-Qemu分析(六)之中斷虛擬化Linux
- 虛擬記憶體設定在c盤和d盤一樣嘛 虛擬記憶體放c盤還是d盤記憶體
- 震驚!iOS11 耗電竟然是因為它...——Jinkey 原創iOS
- [原創] Oracle資料庫資源管理Oracle資料庫
- Oracle資料庫開發指南(原創)Oracle資料庫
- 資料庫圈周盤點:信創市場升溫;StarRocks 2.2 新版本釋出資料庫
- 【原創】Linux虛擬化KVM-Qemu分析(四)之CPU虛擬化(2)Linux
- 【原創】VB P-code -- 虛擬機器的藝術虛擬機
- 【原創】淺談指標(一)指標
- 電腦c盤太滿了如何清理 電腦c盤滿了如何解決
- 部署STANDBY資料庫資料庫
- 根據除錯工具看原始碼之虛擬dom(一)除錯原始碼
- 【Linux】/var/spool/clientmqueue 佔滿根目錄LinuxclientMQ
- CentOS 7 如何解決根目錄滿了CentOS
- 數安時代入根,360信創SM2國密根證書庫再添新“翼”
- 【原創】Linux虛擬化KVM-Qemu分析(五)之記憶體虛擬化Linux記憶體
- 【原創】Linux虛擬化KVM-Qemu分析(七)之timer虛擬化Linux
- 【原創】Linux虛擬化KVM-Qemu分析(二)之ARMv8虛擬化Linux
- 給個驚喜感動一下 父母適用智慧機盤點
- 原根學習筆記筆記
- [原創]資料庫安全思維導圖資料庫
- windows 上的手工建庫過程 (原創)Windows
- 轉:如何做一場B格滿滿的技術大會演講
- 【原創】Linux虛擬化KVM-Qemu分析(十一)之virtqueueLinux