配置默認備份類型backupset和image copy
backup命令可以創建備份集或者鏡像拷貝兩種備份類型。在磁盤上,
我們可以備份為備份集或者鏡像拷貝。默認的備份類型是未壓縮的備份集。在磁盤上,備份類型只能是備份集,不能設置為鏡像拷貝。
配置默認備份類型
1.默認鏡像文件到磁盤
CONFIGURE DEVICE TYPE DISK BACKUP TYPE TO COPY;
2.默認備份集到磁盤
CONFIGURE DEVICE TYPE DISK BACKUP TYPE TO BACKUPSET;
3.默認壓縮備份集到磁盤
CONFIGURE DEVICE TYPE DISK BACKUP TYPE TO COMPRESSED BACKUPSET;
4.默認壓縮備份集到磁帶
CONFIGURE DEVICE TYPE sbt BACKUP TYPE TO COMPRESSED BACKUPSET;
嘗試更改默認配置為鏡像拷貝到磁盤
RMAN> show device type;
RMAN configuration parameters for database with db_unique_name TEST are:
CONFIGURE DEVICE TYPE DISK PARALLELISM 1 BACKUP TYPE TO BACKUPSET; # default
RMAN> CONFIGURE DEVICE TYPE DISK BACKUP TYPE TO COPY;
new RMAN configuration parameters:
CONFIGURE DEVICE TYPE DISK BACKUP TYPE TO COPY PARALLELISM 1;
new RMAN configuration parameters are successfully stored
released channel: ORA_DISK_1
RMAN> show device type;
RMAN configuration parameters for database with db_unique_name TEST are:
CONFIGURE DEVICE TYPE DISK BACKUP TYPE TO COPY PARALLELISM 1;
嘗試更改默認配置為鏡像拷貝到磁帶
RMAN> CONFIGURE DEVICE TYPE sbt BACKUP TYPE TO COPY;
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of configure command at 07/23/2017 22:50:47
RMAN-06609: AS COPY can be configured only for disk device
失敗
更改默認配置為備份集到磁帶
RMAN> CONFIGURE DEVICE TYPE sbt BACKUP TYPE TO BACKUPSET;
new RMAN configuration parameters:
CONFIGURE DEVICE TYPE 'SBT_TAPE' BACKUP TYPE TO BACKUPSET PARALLELISM 1;
new RMAN configuration parameters are successfully stored
RMAN> configure default device type to sbt;
old RMAN configuration parameters:
CONFIGURE DEFAULT DEVICE TYPE TO 'SBT_TAPE';
new RMAN configuration parameters:
CONFIGURE DEFAULT DEVICE TYPE TO 'SBT_TAPE';
new RMAN configuration parameters are successfully stored
兩個語句都修改成功,配置默認備份設備的語句 configure default device type to xxx其實指定了默認備份類型為非壓縮型的備份集。