通过em调用rman执行备份,自动生成的脚本
- backup device type disk tag '%TAG' database;
- backup device type disk tag '%TAG' archivelog all not backed up delete all input;
- run {
- allocate channel oem_backup_disk1 type disk format '%U' maxpiecesize 1000 G;
- backup tag '%TAG' current controlfile;
- release channel oem_backup_disk1;
- }
- allocate channel for maintenance type disk;
- delete noprompt obsolete device type disk;
- release channel;
查看备份信息,通过sql_trace=true 抓取到的脚本
- SELECT b.session_key, b.session_recid, b.session_stamp, b.command_id,
- b.status, b.start_time, b.time_taken_display, b.input_type,
- b.output_device_type, b.input_bytes_display, b.output_bytes_display,
- b.output_bytes_per_sec_display
- FROM
- V$RMAN_BACKUP_JOB_DETAILS b WHERE ( b.start_time > (SYSDATE - 30) ) order
- by b.start_time
结果如下图所示:
阅读(2340) | 评论(0) | 转发(0) |