rman總結(包含10g rman中的新特性)
正在不斷更新中......
[@more@]1>10grman在backup的時候將當前沒有用的到block跳過,不備份.而在以前的版本中rman只是跳過never been allocated blocks.
2>The CONFIGURE DEVICE TYPE ... PARALLELISM command specifies the number of
automatic channels to allocate for a specified device type. For example, if you configure parallelism to 3 for a device type, then RMAN allocates three channels for the device type when using automatic channels.
3>並行通道的個數應該和物理裝置的match,也就是說如果只有一個磁帶裝置,那麼sbt通道就不能並行,如果只有一個物理disk,那麼disk通道就不能並行.
4>rman在備份archive log的時候如果一個歸檔路徑失敗或者一個log有損壞,那麼rman將去另外的歸檔路徑下尋找可用的archive log,直到備份成功.
5>The only difference between a level 0 incremental backup and a full backup is that a full backup is never included in an incremental strategy.
6>如果compatibility>=10.0.0,那麼當Differential Incremental Backups時發現沒有可用的level 0 backup,rman將備份自從檔案建立以來的所有改變過的block,如果compatibility<10.0.0,那麼rman將產生一次level 0備份
7>當自從上一次level 0備份以來資料塊的改變已經大於或者等於總塊數的20%時,就需要再做一次level 0 backup.
以下語句是檢視在備份集中備份塊數超過50%的資料檔案:
SELECT FILE#, INCREMENTAL_LEVEL, COMPLETION_TIME, BLOCKS, DATAFILE_BLOCKS
FROM V$BACKUP_DATAFILE
WHERE INCREMENTAL_LEVEL > 0
AND BLOCKS / DATAFILE_BLOCKS > .5
ORDER BY COMPLETION_TIME;
9>Backup Optimization for SBT Backups with Recovery Window Retention Policy:
當backup optimization enable,那麼當用rman備份檔案到磁帶的時候,rman備份比recovery window 舊的檔案,即使在增量備份策略中自從上次備份以來資料沒有修改過.
10>BACKUP DURATION 4:00 TABLESPACE users:引數duration將備份控制在4個小時之內,如果4個小時沒有備份完成,那麼未完成的backup set將中止並被丟棄,4小時只能完成的其他backup set是可用的,但是如果這個backup 命令是寫在run block裡面的,到達4小時的時候rman將會報錯,這條命令以後的其他命令也將中止,不再繼續.如果用了以下命令(加了引數PARTIAL):
BACKUP DURATION 4:00 PARTIAL TABLESPACE users FILESPERSET 1; 即使這個backup 命令是寫在run block裡面的,到達4小時的時候rman不會報錯,只是出現一個message,顯示哪些檔案還沒有備份,然後這個備份命令中止,而在這個命令後面的包含在run block裡面的其他命令將繼續執行.
注意上面的那條命令: also the use of FILESPERSET 1 in this example. With this option, RMAN puts each file into its own backupset. This way, when a backup is interrupted at the end of
the backup window, only the backup of the file currently being backed up is lost. All backup sets completed during the window are saved, minimizing the lost work due to the end of the backup window.
另:用DURATION可以得到最好的backup performance(在規定的時間內最快的完成備份)以及控制backup在規定的時間內準確完成(可以用來降低備份速度,讓備份準確的在較長的時間段內完成,以降低在備份過程中rman造成的系統,這一點不宜用在tape streaming中),具體的用法如下:
To maximize performance, use the MINIMIZE TIME option with DURATION, as shown in this example:
BACKUP DURATION 4:00 PARTIAL MINIMIZE TIME DATABASE FILESPERSET 1;
To extend the backup to use the full time available, use the MINIMIZE LOAD option,as in this example:
BACKUP DURATION 4:00 PARTIAL MINIMIZE LOAD DATABASE FILESPERSET 1;
RMAN monitors the progress of the running backup, and periodically estimates how long the backup will take to complete at its present rate. If RMAN estimates that the backup will finish before the end of the backup window, it slows down the rate of backup so that the full available duration will be used. This reduces the overhead on the database associated with the backup
10> MAXCORRUPT:在一個檔案中允許的邏輯壞塊和物理壞塊的總和.當壞塊數小於這個引數時rman備份能夠成功,並且記錄這些壞塊的資訊在controlfile和catalog中,並且使用者可以透過訪問v$database_block_corruption檢視來檢視壞塊的資訊.
如果這個檔案中的壞塊總數超過了maxcorrupt的設定值,那麼rman備份將失敗,並且不會記錄壞塊資訊.所以要想檢視壞塊資訊就必須將這個引數設定的足夠大.
11>rman如何備份不一致的block(fractured block),也就是當備份的時候正在被修改的block:
RMAN does not require that you put datafiles into backup mode. During an RMAN backup, a database server session reads each block of the datafile and checks whether each block is fractured by comparing the block header and footer. If a block is fractured, the session re-reads the block. If the same fracture is found, then the block is considered permanently corrupt. If MAXCORRUPT is exceeded, the backup stops.
12>Block Media Recovery with RMAN
these restrictions of block media recovery:
■ You can only perform block media recovery with RMAN. No
interface is available.
■ You can only perform complete recovery of individual blocks.
cannot stop recovery before all redo has been applied to the
■ You can only recover blocks marked media corrupt. The V$DATABASE_CORRUPTION view indicates which blocks in a file were marked most recent BACKUP or BACKUP ... VALIDATE command was
■ You must have a full RMAN backup. Incremental backups are
media recovery. Proxy backups are also not used by block media
full backups and archived log files are used.
■ Block media recovery is able to restore blocks from parent incarnation
and recover the corrupted blocks through a RESETLOGS.
當某個redo log 丟失,Block Media Recovery在讀到這個redo的時候並不是馬上報錯而停止recovery.而是繼續讀後面的redo,因為如果後面的redo裡刪除了這個block上的表,那麼就算丟失的redo裡再怎麼修改這個表上的記錄,在下一個redo裡其實是把這個block標識成了一個新塊.也就是後一個redo覆蓋了前面丟失的redo,所以block recovery可以繼續下去.
12>to add a flash recovery area to an open database:
必須先設定引數DB_RECOVERY_FILE_DEST_SIZE,再設定DB_RECOVERY_FILE_DEST
SQL> ALTER SYSTEM SET DB_RECOVERY_FILE_DEST_SIZE = 10G SCOPE=BOTH SID='*';
SQL> ALTER SYSTEM SET DB_RECOVERY_FILE_DEST = '/disk1/flash_recovery_area' SCOPE=BOTH SID='*';
如何Disabling the Flash Recovery Area:
ALTER SYSTEM SET DB_RECOVERY_FILE_DEST='' SCOPE=BOTH SID="*";
取消Flash Recovery Area以後,在其中儲存的backup等等還可以被rman識別.
13>10g rman新功能:block change tracking
change tracking 記錄塊的變化,用於增量備份時rman不用掃描整個datafile,而是直接讀這個change tracking file.
change tracking 是以level 0 backup為基礎,也就是說level 0 backup還是要掃描整個資料檔案,但是在level 基礎上的增量或者累積備份就可以應用這個特性.
Enabling Change Tracking:
如果設定了DB_CREATE_FILE_DEST,那麼可以直接SQL> ALTER DATABASE ENABLE BLOCK CHANGE TRACKING;
否則必須指定檔名稱和路徑:
SQL> ALTER DATABASE ENABLE BLOCK CHANGE TRACKING USING FILE '/mydir/rman_change_track.f' REUSE;
Disabling Change Tracking:
SQL> ALTER DATABASE DISABLE BLOCK CHANGE TRACKING;
可以查詢v$block_change_tracking檢視來確定是否使用了block change tracking
Moving the Change Tracking File:
(1). If necessary, determine the current name of the change tracking file:
SELECT filename
FROM V$BLOCK_CHANGE_TRACKING;
(2). Shut down the database. For example:
SHUTDOWN IMMEDIATE
(3). Using host operating system commands, move the change tracking file to its new location.
(4). Mount the database and move the change tracking file to a location that has more space. For example:
ALTER DATABASE RENAME FILE
'ora_home/dbs/change_trk.f' TO '/new_disk/change_trk.f';
(5). Open the database:
ALTER DATABASE OPEN;
運用以上這樣的步驟可以保留change tracking file裡面原有的內容.但是如果資料庫不允許停機,那麼就得用一下方法,那麼change tracking file裡面原有的內容將會丟失,以後的增量備份都必須掃描datafile,直到做了一次level 0 backup:
(1).ALTER DATABASE DISABLE BLOCK CHANGE TRACKING;
(2).ALTER DATABASE ENABLE BLOCK CHANGE TRACKING USING FILE 'new_location';
14>影響archivelog路徑的因素:
(1)如果LOG_ARCHIVE_DEST (and, optionally, LOG_ARCHIVE_DUPLEX_DEST) is set,那麼archivelog的路徑只遵循此引數的設定.
(2)如果 DB_RECOVERY_FILE_DEST is specified (that is, if a flash recovery area is
configured) 而且沒有設定 LOG_ARCHIVE_DEST_n, then LOG_ARCHIVE_DEST_10引數隱含設定為 flash recovery area.
(You can override this behavior by explicitly setting LOG_ARCHIVE_DEST_10 to an empty string.)
(3)如果設定了任何一個LOG_ARCHIVE_DEST_n引數,那麼archivelog的路徑只遵循此引數的設定.如果想讓archivelog路徑為配置好的flash recovery area,那麼可以將LOG_ARCHIVE_DEST_n引數配置為LOCATION=USE_DB_RECOVERY_FILE_DEST
(4)如果沒有設定以下任何一個引數:LOG_ARCHIVE_DEST, LOG_ARCHIVE_DEST_n, orDB_RECOVERY_FILE_DEST,
那麼redo logs are archived to a default location that is platform-specific. On Solaris, for example, the default is ?/dbs.
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/75730/viewspace-838019/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- 10G RMAN恢復新特性
- 10G 新特性系列:RMAN 新的引數-PREVIEWView
- 實戰10g新特性之RMAN TSPITR特性
- rman總結
- 實戰10g新特性之rman duplicate複製資料庫資料庫
- Oracle rman 命令總結Oracle
- rman備份rac的總結
- Oracle10g新特性——RMAN(轉來的)Oracle
- 10g新特性:rman恢復時候資料檔案的自動建立
- RMAN命令LIST操作總結
- RMAN 總結篇 1 - (轉)
- RMAN 總結篇 2 - (轉)
- RMAN 總結篇 3 - (轉)
- 12c RMAN新特性之Recover Table
- Oracle10g新特性——RMAN(轉來的)——2Oracle
- RMAN異機恢復總結
- rman備份的其它特性
- Oracle 12C新特性-RMAN恢復表Oracle
- Oracle11g新特性點評之RMANOracle
- rman的一點簡單總結 1
- Oracle的RMAN備份恢復,先從進入RMAN開始總結Oracle
- oracle 10g RMAN管理Oracle 10g
- 【RMAN】Oracle11g備份恢復新特性Oracle
- ZT:資料庫Oracle11g新特性RMAN資料庫Oracle
- oracle RMAN 備份恢復總結Oracle
- oracle RMAN 備份恢復總結Oracle
- RMAN使用者手冊總結
- 同事總結的 : 用RMAN建立Physical Standby DatabaseDatabase
- 【RMAN】RMAN跨版本恢復(中)
- oracle12c新特性(7)--如何在RMAN中執行SQL語句OracleSQL
- 10g RAC rman tips
- oracle 10g rman 指令碼Oracle 10g指令碼
- oracle12c新特性(8)--RMAN中的表恢復和分割槽恢復Oracle
- 11g RMAN新特性 active database duplication createing standbyDatabase
- 10g RMAN的REDUNDANCY策略改變
- 【RMAN】Oracle_rman中skip引發的血案Oracle
- RMAN 命令總結(一)--轉自網路
- RMAN 命令總結(二)--轉自網路