作業系統和informix資料庫全部損壞恢復測試(不同機器之間)
接http://tonykorn97.itpub.net/post/6414/458421
此時我們測試一下在一臺機器上做備份到另外一臺機器上恢復的過程。
1,安裝作業系統,資料庫,networker
2, 在test05伺服器上做備份,然後放到test07上面恢復
3,此時磁帶機的狀態為:
[root@test07 root]# nsrmm -m
nsrmm: RAP error: 4mm tape test05.01 not in media index
[root@test07 root]# mminfo -m
mminfo: no matches found for the query
[root@test07 root]# mt -f /dev/nst0 status
SCSI 2 tape drive:
File number=0, block number=1, partition=0.
Tape block size 0 bytes. Density code 0x26 (DDS-4 or QIC-4GB).
Soft error count since last status=0
General status bits on (1010000):
ONLINE IM_REP_EN
[root@test07 root]#
4,scanner重建磁帶媒體和索引資訊
提示資訊:
[root@test07 root]# scanner -i /dev/nst0
scanner: scanning 4mm tape test05.01 on /dev/nst0
scanner: adding 4mm tape test05.01 to pool DBMIData
scanner: (ssid 4293453817) Can't open session for client test05 to index service on test07
scanner: File index error: `test05' is not a registered client
scanner: write failed, 斷開的管道
scanner: ssid 4293453817: scan complete
scanner: ssid 4293453817: 4031 KB, 1 file(s)
5,在test07上面增加test05的client,重新scanner
[root@test07 root]# scanner -i /dev/nst0
scanner: scanning 4mm tape test05.01 on /dev/nst0
scanner: 4mm tape test05.01 already exists in the media index
scanner: ssid 4293453817: scan complete
scanner: ssid 4293453817: 4031 KB, 1 file(s)
scanner: ssid 4276676602: scan complete
scanner: ssid 4276676602: 63 KB, 1 file(s)
scanner: ssid 4259899387: scan complete
scanner: ssid 4259899387: 63 KB, 1 file(s)
scanner: ssid 4243122171: scan complete
scanner: ssid 4243122171: 63 KB, 1 file(s)
scanner: ssid 4226344957: scan complete
scanner: ssid 4226344957: 63 KB, 1 file(s)
6,此時可以載入磁帶資訊:
[root@test07 root]# nsrmm -m
4mm tape test05.01 mounted on /dev/nst0, write protected
[root@test07 root]# watch
volume written (%) expires read mounts capacity
test05.01 17 MB 2% 2009?ê03??28è? 0 KB 1 1100 MB
Current tape test05.01 MB is used!
[root@test07 root]#
7,recover恢復檔案
[root@test07 root]# recover /home/informix/etc/
/home/informix/etc not in index
Enter directory to browse:
[root@test07 root]#
8,用其他方式恢復
[root@test07 informix]# recover -S 3857382863
Recovering files into their original locations.
./ixbar.0
./oncfg_ontest01.0
./test01.cfg
Received 4 matching file(s) from NSR server `test07'
Recover completion time: Thu Mar 27 10:56:30 2008
[root@test07 informix]#
9,onbar -r恢復測試:
出錯,日誌資訊:
2008-03-27 10:57:27 17576 17574 No such file or directory
2008-03-27 10:57:28 17576 17574 /home/informix/bin/onbar_d -r
2008-03-27 10:57:28 17576 17574 (-43075) Unable to open file /home/informix/etc/sm_versions .
No such file or directory
2008-03-27 10:57:28 17576 17574 /home/informix/bin/onbar_d complete, returning 142 (0x8e)
10,修改過sm_versions後重新恢復,出錯,日誌資訊:
2008-03-27 10:59:18 17593 17591 /home/informix/bin/onbar_d -r
2008-03-27 10:59:19 17593 17591 Successfully connected to Storage Manager.
2008-03-27 10:59:19 17593 17591 XBSA Error: (BSAGetObject) Backup object does not exist in Storage Manager.
2008-03-27 10:59:19 17593 17591 Object information: bar_objdesc
obj_id 0 obj_name 'rootdbs' obj_type 'R' act_id 0 act_type 2 act_status 0
act_start '2008-03-27 10:59:19' act_end '2008-03-27 09:52:05'
ins_time 0 rsam_time 80214 seal_time 1206582725 prev_seal_time 1206446260 level 0 copyid hi:lo 1206582725:1206582726 req_act_id 15
logstream 0 est_pages hi:lo 0:0 first_log 9 chpt_log 9 last_log 0
partial_flag 0 do_query 0 ins_sm_id 0 ins_sm_name ''
ins_verify 0 ins_verify_date '' restore order 0:0
objInfo ''
retry 0 in_catalog 1 in_bootfile 0 child_pid 0 child_state 0
bkup_host ''
2008-03-27 10:59:19 17593 17591 (-43260) ON-Bar was unable to get backup record of rootdbs from storage manager.
2008-03-27 10:59:19 17593 17591 Unable to start the storage space restore: Archive API error: already open.
2008-03-27 10:59:19 17593 17591 Unable to start the storage space restore: Archive API error: already open.
2008-03-27 10:59:19 17593 17591 Unable to start the storage space restore: Archive API error: already open.
2008-03-27 10:59:19 17593 17591 Unable to start the storage space restore: Archive API error: already open.
2008-03-27 10:59:19 17593 17591 Unable to start the storage space restore: Archive API error: already open.
2008-03-27 10:59:24 17593 17591 (-43140) Due to the previous error, logical restore will not be attempted.
2008-03-27 10:59:24 17593 17591 /home/informix/bin/onbar_d complete, returning 131 (0x83)
~
11,刪除networker
12,更改伺服器主機名
13,重新啟動伺服器
14,然後重新安裝networker
15,重新scanner
[root@test07 root]# scanner -i /dev/nst0
[root@test05 installfiles]# nsrmm -m
4mm tape test05.01 mounted on /dev/nst0, write protected
[root@test05 installfiles]# watch
volume written (%) expires read mounts capacity
test05.01 17 MB 2% 2009?ê03??28è? 0 KB 1 1100 MB
Current tape test05.01 MB is used!
16,此時可以用recover恢復
[root@test05 installfiles]# recover /home/informix/etc
recover: Current working directory is /home/informix/etc/
recover> ls
ixbar.0 oncfg_ontest01.0 test01.cfg
recover> add ixbar.0
1 file(s) marked for recovery
recover> add oncfg-ontest01.0
recover: oncfg-ontest01.0 not in index
1 file(s) marked for recovery
recover> add test01.cfg
2 file(s) marked for recovery
recover> recover
recover: Total estimated disk space needed for recover is 20 KB.
Recovering 2 files into their original locations
Volumes needed (all on-line):
test05.01 at /dev/nst0
Requesting 2 file(s), this may take a while...
./ixbar.0
./ixbar.0 file exists, overwrite (n, y, N, Y) or rename (r, R) [n]? y
overwriting ./ixbar.0
./test01.cfg
./test01.cfg file exists, overwrite (n, y, N, Y) or rename (r, R) [y]? y
overwriting ./test01.cfg
Received 2 file(s) from NSR server `test05'
Recover completion time: Thu Mar 27 17:45:38 2008
recover> quit
[root@test05 installfiles]#
17,onbar恢復還是不行:
2008-03-27 17:45:49 1860 1858 /home/informix/bin/onbar_d -r
2008-03-27 17:45:49 1860 1858 Successfully connected to Storage Manager.
2008-03-27 17:45:58 1860 1858 Begin cold level 0 restore rootdbs (Storage Manager copy ID: 1206582725 1206582726).
2008-03-27 17:50:53 1860 1858 Unable to write storage space restore data to the database server: .
2008-03-27 17:50:53 1860 1858 (-43391) Skipped backup/restore of space 'rootdbs'.
2008-03-27 17:50:53 1860 1858 Unable to start the storage space restore: Archive API error: already open.
2008-03-27 17:50:53 1860 1858 Unable to start the storage space restore: Archive API error: already open.
2008-03-27 17:50:53 1860 1858 Unable to start the storage space restore: Archive API error: already open.
2008-03-27 17:50:53 1860 1858 Unable to start the storage space restore: Archive API error: already open.
2008-03-27 17:50:53 1860 1858 Unable to start the storage space restore: Archive API error: already open.
2008-03-27 17:50:58 1860 1858 (-43140) Due to the previous error, logical restore will not be attempted.
2008-03-27 17:50:58 1860 1858 /home/informix/bin/onbar_d complete, returning 131 (0x83)
~
18,informix日誌資訊:
17:46:05 IBM Informix Dynamic Server Version 10.00.UC4 Software Serial Number AAA#B000000
17:46:05 listener-thread: err = -930: oserr = 0: errstr = test07: Cannot connect to database server (test07).
17:46:05 sql_listener: ASF_LISTEN failed
17:46:05 Attempting to bring listener thread down.
17:46:05 Server stopped.
17:46:05 IBM Informix Dynamic Server Stopped.
17:46:05 mt_shm_remove: WARNING: may not have removed all/correct segments
19,修改sqlhosts檔案.
20, 重新恢復正常。
21,上面恢復說明一個問題,恢復的時候可以在兩臺機器之間進行,兩臺機器之間的ip可以不同,但是主機名需要相同。
暫時只做了一下這樣的備份恢復測試。
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/312079/viewspace-245844/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- 作業系統和informix資料庫全部損壞恢復測試作業系統ORM資料庫
- 伺服器系統癱瘓系統損壞資料恢復伺服器資料恢復
- master資料庫損壞之後的恢復AST資料庫
- Oracle資料庫不同損壞級別的恢復詳解Oracle資料庫
- [ORACLE] 系統故障資料庫恢復--資料檔案無損壞Oracle資料庫
- 【伺服器資料恢復】伺服器reiserfs檔案系統損壞的資料恢復案例伺服器資料恢復
- 備份&恢復之十三:損壞全部控制檔案
- 資料庫資料恢復—NTFS分割槽損壞如何恢復SqlServer資料庫資料資料庫資料恢復SQLServer
- 【資料庫資料恢復】MongoDB資料庫檔案損壞的資料恢復案例資料庫資料恢復MongoDB
- 【北亞伺服器資料恢復】伺服器reiserfs檔案系統損壞的資料恢復案例伺服器資料恢復
- 資料檔案或者tablespace損壞基於rman恢復測試
- Oracle資料庫UNDO損壞後的恢復Oracle資料庫
- 使用RMAN恢復完全損壞的資料庫資料庫
- 當前日誌組全部損壞的恢復
- 介質恢復,即磁碟或作業系統檔案損壞的恢復-非RMAN方法作業系統
- 非系統表空間損壞,rman備份恢復
- 非系統資料檔案損壞,rman備份恢復
- 資料庫資料恢復-SQL SERVER資料庫MDF (NDF)或LDF損壞如何恢復資料?資料庫資料恢復SQLServer
- 【伺服器資料恢復】IBM儲存伺服器硬碟壞道離線、oracle資料庫損壞的資料恢復伺服器資料恢復IBM硬碟Oracle資料庫
- 作業系統層面恢復mysql的資料庫作業系統MySql資料庫
- 作業系統重灌後Oracle資料庫的恢復作業系統Oracle資料庫
- IBM X3650伺服器系統損壞故障的資料恢復IBM伺服器資料恢復
- u盤檔案損壞怎麼恢復資料 u盤恢復損壞資料的有效方法
- 伺服器Oracle資料庫損壞修復伺服器Oracle資料庫
- 【儲存資料恢復】IBM儲存檔案NTFS系統損壞的資料恢復案例資料恢復IBM
- Informix資料庫備份與恢復ORM資料庫
- 資料底層損壞的恢復方法—拼碎片恢復資料
- PDM測試資料庫恢復資料庫
- 損壞聯機日誌 恢復
- Oracle 11g 資料庫恢復:場景9-系統預設undo表空間資料檔案損壞Oracle資料庫
- 成功恢復某公司伺服器故障導致的資料庫損壞伺服器資料庫
- 執行在容器中Postgres資料庫資料損壞後如何恢復?資料庫
- 資料庫損壞解決:資料庫已損壞,無法分配空間資料庫
- 伺服器資料庫損壞能修復嘛伺服器資料庫
- MySQL資料庫下.frm.MYD.MYI損壞恢復操作MySql資料庫
- index損壞恢復Index
- 【伺服器資料恢復】raid5崩潰導致lvm資訊和VXFS檔案系統損壞的資料恢復案例伺服器資料恢復AILVM
- 【伺服器資料恢復】某品牌ProLiant伺服器raid癱瘓資料庫檔案損壞的資料恢復伺服器資料恢復AI資料庫