11g rman validate驗證資料庫
11g rman validate驗證資料庫
==========================
11g rman中增加validate來檢查資料庫狀況
可以針對全庫、控制檔案、引數檔案等進行驗證
可以針對全庫、控制檔案、引數檔案等進行驗證
validate database;
validate datafile 3;
validate spfile;
validate current controlfile;
validate backupset xxx;
validate tablespace system;
======================
[oracle@localhost 2011_11_08]$ rman target /
Recovery Manager: Release 11.2.0.1.0 - Production on Tue Nov 8 11:08:39 2011
Copyright (c) 1982, 2009, Oracle and/or its affiliates. All rights reserved.
connected to target database: DB11 (DBID=1298141643)
--全庫驗證
--結果包括所有檔案的狀態、是否有壞塊、空塊、使用量、以及scn
--同時還有檔案中資料和索引各佔用的塊等資訊
--全庫驗證的結果預設包含引數檔案和控制檔案
--結果包括所有檔案的狀態、是否有壞塊、空塊、使用量、以及scn
--同時還有檔案中資料和索引各佔用的塊等資訊
--全庫驗證的結果預設包含引數檔案和控制檔案
RMAN> validate database;
Starting validate at 08-NOV-11
using target database control file instead of recovery catalog
allocated channel: ORA_DISK_1
channel ORA_DISK_1: SID=41 device type=DISK
channel ORA_DISK_1: starting validation of datafile
channel ORA_DISK_1: specifying datafile(s) for validation
input datafile file number=00001 name=/oracle/oradata/db11/db11/system01.dbf
input datafile file number=00002 name=/oracle/oradata/db11/db11/sysaux01.dbf
input datafile file number=00003 name=/oracle/oradata/db11/db11/undotbs01.dbf
input datafile file number=00004 name=/oracle/oradata/db11/db11/users01.dbf
channel ORA_DISK_1: validation complete, elapsed time: 00:00:35
List of Datafiles
=================
File Status Marked Corrupt Empty Blocks Blocks Examined High SCN
---- ------ -------------- ------------ --------------- ----------
1 OK 0 13729 87041 877449
File Name: /oracle/oradata/db11/db11/system01.dbf
Block Type Blocks Failing Blocks Processed
---------- -------------- ----------------
Data 0 58037
Index 0 12168
Other 0 3106
using target database control file instead of recovery catalog
allocated channel: ORA_DISK_1
channel ORA_DISK_1: SID=41 device type=DISK
channel ORA_DISK_1: starting validation of datafile
channel ORA_DISK_1: specifying datafile(s) for validation
input datafile file number=00001 name=/oracle/oradata/db11/db11/system01.dbf
input datafile file number=00002 name=/oracle/oradata/db11/db11/sysaux01.dbf
input datafile file number=00003 name=/oracle/oradata/db11/db11/undotbs01.dbf
input datafile file number=00004 name=/oracle/oradata/db11/db11/users01.dbf
channel ORA_DISK_1: validation complete, elapsed time: 00:00:35
List of Datafiles
=================
File Status Marked Corrupt Empty Blocks Blocks Examined High SCN
---- ------ -------------- ------------ --------------- ----------
1 OK 0 13729 87041 877449
File Name: /oracle/oradata/db11/db11/system01.dbf
Block Type Blocks Failing Blocks Processed
---------- -------------- ----------------
Data 0 58037
Index 0 12168
Other 0 3106
File Status Marked Corrupt Empty Blocks Blocks Examined High SCN
---- ------ -------------- ------------ --------------- ----------
2 OK 0 17402 60183 877455
File Name: /oracle/oradata/db11/db11/sysaux01.dbf
Block Type Blocks Failing Blocks Processed
---------- -------------- ----------------
Data 0 10067
Index 0 7025
Other 0 25666
---- ------ -------------- ------------ --------------- ----------
2 OK 0 17402 60183 877455
File Name: /oracle/oradata/db11/db11/sysaux01.dbf
Block Type Blocks Failing Blocks Processed
---------- -------------- ----------------
Data 0 10067
Index 0 7025
Other 0 25666
File Status Marked Corrupt Empty Blocks Blocks Examined High SCN
---- ------ -------------- ------------ --------------- ----------
3 OK 0 112 9600 877455
File Name: /oracle/oradata/db11/db11/undotbs01.dbf
Block Type Blocks Failing Blocks Processed
---------- -------------- ----------------
Data 0 0
Index 0 0
Other 0 9488
---- ------ -------------- ------------ --------------- ----------
3 OK 0 112 9600 877455
File Name: /oracle/oradata/db11/db11/undotbs01.dbf
Block Type Blocks Failing Blocks Processed
---------- -------------- ----------------
Data 0 0
Index 0 0
Other 0 9488
File Status Marked Corrupt Empty Blocks Blocks Examined High SCN
---- ------ -------------- ------------ --------------- ----------
4 OK 0 481 640 749391
File Name: /oracle/oradata/db11/db11/users01.dbf
Block Type Blocks Failing Blocks Processed
---------- -------------- ----------------
Data 0 15
Index 0 2
Other 0 142
---- ------ -------------- ------------ --------------- ----------
4 OK 0 481 640 749391
File Name: /oracle/oradata/db11/db11/users01.dbf
Block Type Blocks Failing Blocks Processed
---------- -------------- ----------------
Data 0 15
Index 0 2
Other 0 142
channel ORA_DISK_1: starting validation of datafile
channel ORA_DISK_1: specifying datafile(s) for validation
including current control file for validation
including current SPFILE in backup set
channel ORA_DISK_1: validation complete, elapsed time: 00:00:01
List of Control File and SPFILE
===============================
File Type Status Blocks Failing Blocks Examined
------------ ------ -------------- ---------------
SPFILE OK 0 2
Control File OK 0 594
Finished validate at 08-NOV-11
channel ORA_DISK_1: specifying datafile(s) for validation
including current control file for validation
including current SPFILE in backup set
channel ORA_DISK_1: validation complete, elapsed time: 00:00:01
List of Control File and SPFILE
===============================
File Type Status Blocks Failing Blocks Examined
------------ ------ -------------- ---------------
SPFILE OK 0 2
Control File OK 0 594
Finished validate at 08-NOV-11
RMAN> validate datafile 3;
Starting validate at 08-NOV-11
using channel ORA_DISK_1
channel ORA_DISK_1: starting validation of datafile
channel ORA_DISK_1: specifying datafile(s) for validation
input datafile file number=00003 name=/oracle/oradata/db11/db11/undotbs01.dbf
channel ORA_DISK_1: validation complete, elapsed time: 00:00:03
List of Datafiles
=================
File Status Marked Corrupt Empty Blocks Blocks Examined High SCN
---- ------ -------------- ------------ --------------- ----------
3 OK 0 112 9600 877455
File Name: /oracle/oradata/db11/db11/undotbs01.dbf
Block Type Blocks Failing Blocks Processed
---------- -------------- ----------------
Data 0 0
Index 0 0
Other 0 9488
using channel ORA_DISK_1
channel ORA_DISK_1: starting validation of datafile
channel ORA_DISK_1: specifying datafile(s) for validation
input datafile file number=00003 name=/oracle/oradata/db11/db11/undotbs01.dbf
channel ORA_DISK_1: validation complete, elapsed time: 00:00:03
List of Datafiles
=================
File Status Marked Corrupt Empty Blocks Blocks Examined High SCN
---- ------ -------------- ------------ --------------- ----------
3 OK 0 112 9600 877455
File Name: /oracle/oradata/db11/db11/undotbs01.dbf
Block Type Blocks Failing Blocks Processed
---------- -------------- ----------------
Data 0 0
Index 0 0
Other 0 9488
Finished validate at 08-NOV-11
--驗證引數檔案
--比較簡單
RMAN> validate spfile;
Starting validate at 08-NOV-11
using channel ORA_DISK_1
channel ORA_DISK_1: starting validation of datafile
channel ORA_DISK_1: specifying datafile(s) for validation
including current SPFILE in backup set
channel ORA_DISK_1: validation complete, elapsed time: 00:00:00
List of Control File and SPFILE
===============================
File Type Status Blocks Failing Blocks Examined
------------ ------ -------------- ---------------
SPFILE OK 0 2
Finished validate at 08-NOV-11
using channel ORA_DISK_1
channel ORA_DISK_1: starting validation of datafile
channel ORA_DISK_1: specifying datafile(s) for validation
including current SPFILE in backup set
channel ORA_DISK_1: validation complete, elapsed time: 00:00:00
List of Control File and SPFILE
===============================
File Type Status Blocks Failing Blocks Examined
------------ ------ -------------- ---------------
SPFILE OK 0 2
Finished validate at 08-NOV-11
--驗證控制檔案
--與引數檔案類似
--與引數檔案類似
RMAN> validate current controlfile;
Starting validate at 08-NOV-11
using channel ORA_DISK_1
channel ORA_DISK_1: starting validation of datafile
channel ORA_DISK_1: specifying datafile(s) for validation
including current control file for validation
channel ORA_DISK_1: validation complete, elapsed time: 00:00:01
List of Control File and SPFILE
===============================
File Type Status Blocks Failing Blocks Examined
------------ ------ -------------- ---------------
Control File OK 0 594
Finished validate at 08-NOV-11
using channel ORA_DISK_1
channel ORA_DISK_1: starting validation of datafile
channel ORA_DISK_1: specifying datafile(s) for validation
including current control file for validation
channel ORA_DISK_1: validation complete, elapsed time: 00:00:01
List of Control File and SPFILE
===============================
File Type Status Blocks Failing Blocks Examined
------------ ------ -------------- ---------------
Control File OK 0 594
Finished validate at 08-NOV-11
--使用list命令可以將現存在catalog中的backupset列出
--根據列出的backupset key可以對backupset進行驗證
--根據列出的backupset key可以對backupset進行驗證
RMAN> list backupset;
List of Backup Sets
===================
BS Key Type LV Size Device Type Elapsed Time Completion Time
------- ---- -- ---------- ----------- ------------ ---------------
4 Full 954.85M DISK 00:01:26 08-NOV-11
BP Key: 4 Status: AVAILABLE Compressed: NO Tag: TAG20111108T112236
Piece Name: /oracle/flash_recovery_area/DB11/backupset/2011_11_08/o1_mf_nnndf_TAG20111108T112236_7ck83wn9_.bkp
List of Datafiles in backup set 4
File LV Type Ckp SCN Ckp Time Name
---- -- ---- ---------- --------- ----
1 Full 878265 08-NOV-11 /oracle/oradata/db11/db11/system01.dbf
2 Full 878265 08-NOV-11 /oracle/oradata/db11/db11/sysaux01.dbf
3 Full 878265 08-NOV-11 /oracle/oradata/db11/db11/undotbs01.dbf
4 Full 878265 08-NOV-11 /oracle/oradata/db11/db11/users01.dbf
BS Key Type LV Size Device Type Elapsed Time Completion Time
------- ---- -- ---------- ----------- ------------ ---------------
5 Full 9.36M DISK 00:00:02 08-NOV-11
BP Key: 5 Status: AVAILABLE Compressed: NO Tag: TAG20111108T112236
Piece Name: /oracle/flash_recovery_area/DB11/backupset/2011_11_08/o1_mf_ncsnf_TAG20111108T112236_7ck86x1h_.bkp
SPFILE Included: Modification time: 08-NOV-11
SPFILE db_unique_name: DB11
Control File Included: Ckp SCN: 878298 Ckp time: 08-NOV-11
------- ---- -- ---------- ----------- ------------ ---------------
5 Full 9.36M DISK 00:00:02 08-NOV-11
BP Key: 5 Status: AVAILABLE Compressed: NO Tag: TAG20111108T112236
Piece Name: /oracle/flash_recovery_area/DB11/backupset/2011_11_08/o1_mf_ncsnf_TAG20111108T112236_7ck86x1h_.bkp
SPFILE Included: Modification time: 08-NOV-11
SPFILE db_unique_name: DB11
Control File Included: Ckp SCN: 878298 Ckp time: 08-NOV-11
RMAN> validate backupset 5;
Starting validate at 08-NOV-11
using channel ORA_DISK_1
channel ORA_DISK_1: starting validation of datafile backup set
channel ORA_DISK_1: reading from backup piece /oracle/flash_recovery_area/DB11/backupset/2011_11_08/o1_mf_ncsnf_TAG20111108T112236_7ck86x1h_.bkp
channel ORA_DISK_1: piece handle=/oracle/flash_recovery_area/DB11/backupset/2011_11_08/o1_mf_ncsnf_TAG20111108T112236_7ck86x1h_.bkp tag=TAG20111108T112236
channel ORA_DISK_1: restored backup piece 1
channel ORA_DISK_1: validation complete, elapsed time: 00:00:01
Finished validate at 08-NOV-11
using channel ORA_DISK_1
channel ORA_DISK_1: starting validation of datafile backup set
channel ORA_DISK_1: reading from backup piece /oracle/flash_recovery_area/DB11/backupset/2011_11_08/o1_mf_ncsnf_TAG20111108T112236_7ck86x1h_.bkp
channel ORA_DISK_1: piece handle=/oracle/flash_recovery_area/DB11/backupset/2011_11_08/o1_mf_ncsnf_TAG20111108T112236_7ck86x1h_.bkp tag=TAG20111108T112236
channel ORA_DISK_1: restored backup piece 1
channel ORA_DISK_1: validation complete, elapsed time: 00:00:01
Finished validate at 08-NOV-11
RMAN> validate tablespace system;
Starting validate at 08-NOV-11
using channel ORA_DISK_1
channel ORA_DISK_1: starting validation of datafile
channel ORA_DISK_1: specifying datafile(s) for validation
input datafile file number=00001 name=/oracle/oradata/db11/db11/system01.dbf
channel ORA_DISK_1: validation complete, elapsed time: 00:00:15
List of Datafiles
=================
File Status Marked Corrupt Empty Blocks Blocks Examined High SCN
---- ------ -------------- ------------ --------------- ----------
1 OK 0 13729 87041 878568
File Name: /oracle/oradata/db11/db11/system01.dbf
Block Type Blocks Failing Blocks Processed
---------- -------------- ----------------
Data 0 58037
Index 0 12168
Other 0 3106
using channel ORA_DISK_1
channel ORA_DISK_1: starting validation of datafile
channel ORA_DISK_1: specifying datafile(s) for validation
input datafile file number=00001 name=/oracle/oradata/db11/db11/system01.dbf
channel ORA_DISK_1: validation complete, elapsed time: 00:00:15
List of Datafiles
=================
File Status Marked Corrupt Empty Blocks Blocks Examined High SCN
---- ------ -------------- ------------ --------------- ----------
1 OK 0 13729 87041 878568
File Name: /oracle/oradata/db11/db11/system01.dbf
Block Type Blocks Failing Blocks Processed
---------- -------------- ----------------
Data 0 58037
Index 0 12168
Other 0 3106
channel ORA_DISK_1: starting validation of datafile
channel ORA_DISK_1: specifying datafile(s) for validation
including current control file for validation
including current SPFILE in backup set
channel ORA_DISK_1: validation complete, elapsed time: 00:00:01
List of Control File and SPFILE
===============================
File Type Status Blocks Failing Blocks Examined
------------ ------ -------------- ---------------
SPFILE OK 0 2
Control File OK 0 594
Finished validate at 08-NOV-11
channel ORA_DISK_1: specifying datafile(s) for validation
including current control file for validation
including current SPFILE in backup set
channel ORA_DISK_1: validation complete, elapsed time: 00:00:01
List of Control File and SPFILE
===============================
File Type Status Blocks Failing Blocks Examined
------------ ------ -------------- ---------------
SPFILE OK 0 2
Control File OK 0 594
Finished validate at 08-NOV-11
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/13177610/viewspace-710418/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- rman備份驗證(之restore validate)REST
- 驗證oracle 11g資料庫的RMAN備份的有效性Oracle資料庫
- 使用validate驗證資料檢查資料壞塊
- Struts2教程4:使用validate方法驗證資料
- jquery validate 手工驗證方法jQuery
- Oracle RMAN 連線資料庫認證方法Oracle資料庫
- mongoose使用validate驗證, 獲取自定義驗證資訊Go
- jquery.validate 表單驗證jQuery
- validate表單驗證外掛
- 資料庫的身份驗證方式資料庫
- thinkphp validate unique 資料庫欄位唯一性校驗PHP資料庫
- jQuery Validate非同步ajax方式驗證jQuery非同步
- jQuery Validate驗證規則的使用jQuery
- jQuery Validate驗證規則使用演示jQuery
- jQuery Validate忽略指定元素不驗證jQuery
- jQuery Validate驗證規則實質jQuery
- jQuery Validate驗證觸發的方式jQuery
- jQuery Validate驗證除錯開關jQuery除錯
- jQuery Validate自定義驗證成功資訊jQuery
- 騰訊資料庫tdsql部署與驗證資料庫SQL
- 11g RMAN新特性active database duplicate 資料庫異構Database資料庫
- 11g RMAN新特性 active database duplication 複製資料庫Database資料庫
- 讓你的 validate 支援場景驗證
- Thinkphp5基礎——11 validate驗證PHP
- jQuery Validate驗證上傳檔案大小jQuery
- jQuery Validate自定義驗證錯誤資訊jQuery
- jQuery Validate新增自定義驗證規則jQuery
- 使用RMAN Duplicate方法搭建異名資料庫實驗資料庫
- RMAN 驗證 資料檔案 和 備份 的有效性
- Oracle資料庫密碼延遲驗證Oracle資料庫密碼
- jQuery Validate表單驗證基本流程介紹jQuery
- jQuery Validate對select下拉選單驗證jQuery
- jQuery Validate驗證確認密碼是否相同jQuery密碼
- jQuery Validate checkbox和radio驗證jQuery
- jquery.validate失去焦點時就驗證jQuery
- Backup And Recovery User's Guide-從RMAN開始-驗證資料庫檔案和備份GUIIDE資料庫
- 修改外來鍵為validate時需要驗證資料是否符合外來鍵約束
- 1.6.3. 資料庫管理員身份驗證方法資料庫