rman target / >> /home/oracle/sykdb_level0_$dt.log << EOF
run{
allocate channel ch1 type sbt_tape;
allocate channel ch2 type sbt_tape;
backup incremental level 0 database format 'db_level0_%d_%T_%s_%p_%t' tag 'db_level0';
sql 'alter system archive log current';
sql 'alter system archive log current';
backup archivelog all format 'arch_level0_%s_%p_%t' tag 'arch_level0' delete all input;
crosscheck backup;
delete noprompt obsolete;
delete noprompt expired backup;
backup current controlfile format 'control_%s_%p_%t' tag 'controlfile';
backup spfile format 'spfile_%s_%p_%t' tag 'spfile';
release channel ch1;
release channel ch2;
}
list backup;
exit
这个是我参照网络上的例子写的 增量 0 级备份.请各位指证.
rman参数:
RMAN> show all;
using target database control file instead of recovery catalog
RMAN configuration parameters for database with db_unique_name DB are:
CONFIGURE RETENTION POLICY TO RECOVERY WINDOW OF 7 DAYS;
CONFIGURE BACKUP OPTIMIZATION ON;
CONFIGURE DEFAULT DEVICE TYPE TO sbt_tape;
CONFIGURE CONTROLFILE AUTOBACKUP OFF; # default
CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO '%F'; # default
CONFIGURE DEVICE TYPE DISK PARALLELISM 1 BACKUP TYPE TO BACKUPSET; # default
CONFIGURE DATAFILE BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
CONFIGURE ARCHIVELOG BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
CONFIGURE MAXSETSIZE TO UNLIMITED; # default
CONFIGURE ENCRYPTION FOR DATABASE OFF; # default
CONFIGURE ENCRYPTION ALGORITHM 'AES128'; # default
CONFIGURE COMPRESSION ALGORITHM 'BASIC' AS OF RELEASE 'DEFAULT' OPTIMIZE FOR LOAD TRUE ; # default
CONFIGURE ARCHIVELOG DELETION POLICY TO NONE; # default
CONFIGURE SNAPSHOT CONTROLFILE NAME TO '/u01/app/oracle/product/11.2.0/dbhome_1/dbs/snapcf_db2.f'; # default