Oracle RMAN全备脚本(正式测试可行)

Oracle RMAN全备脚本 正式环境测试可行

请参考。

run{
allocate channel c1 type disk maxpiecesize=20G;
allocate channel c2 type disk maxpiecesize=20G;
allocate channel c3 type disk maxpiecesize=20G;
allocate channel c4 type disk maxpiecesize=20G;
crosscheck archivelog all;
delete noprompt expired archivelog all;
crosscheck backup;
delete noprompt expired backup;
crosscheck copy;
delete noprompt expired copy;
report obsolete;
delete noprompt obsolete;
backup filesperset 6 tag 'full_incr_lv0' incremental level 0 database format 'F:\db_rman_backup\fulldb_lv0_%d_%U_%T';

sql 'alter system archive log current';
backup filesperset 20 tag 'archbackup' archivelog all delete input format 'F:\db_rman_backup\arch_%d_%U_%T';
delete noprompt archivelog all completed before 'sysdate-1';

release channel c1;
release channel c2;
release channel c3;
release channel c4;
}

你可能感兴趣的:(数据库运维案例分享,oracle,数据库)