Friday , July 21 2017
Home / Oracle DBA / TAKING THE BACKUP OF ARCHIVELOGS IN RMAN

TAKING THE BACKUP OF ARCHIVELOGS IN RMAN

RMAN> list archivelog all;

List of Archived Log Copies for database with db_unique_name DBC
=====================================================================

Key Thrd Seq S Low Time
——- —- ——- – ———
19 1 2 A 01-JUL-17
Name: /u01/app/oracle/fast_recovery_area/DBC/archivelog/2017_07_05/o1_mf_1_2_doryt2co_.arc

182 1 3 A 05-JUL-17
Name: /u01/app/oracle/fast_recovery_area/DBC/archivelog/2017_07_05/o1_mf_1_3_dos783g5_.arc

199 1 4 A 05-JUL-17
Name: /u01/app/oracle/fast_recovery_area/DBC/archivelog/2017_07_05/o1_mf_1_4_dos7kv2s_.arc

RMAN>

RMAN> backup archivelog all;

Starting backup at 05-JUL-17
current log archived
using channel ORA_DISK_1
using channel ORA_DISK_2
skipping archived log file /u01/app/oracle/fast_recovery_area/DBC/archivelog/2017_07_05/o1_mf_1_2_doryt2co_.arc; already backed up 1 time(s)
skipping archived log file /u01/app/oracle/fast_recovery_area/DBC/archivelog/2017_07_05/o1_mf_1_3_dos783g5_.arc; already backed up 1 time(s)
skipping archived log file /u01/app/oracle/fast_recovery_area/DBC/archivelog/2017_07_05/o1_mf_1_4_dos7kv2s_.arc; already backed up 1 time(s)
channel ORA_DISK_1: starting archived log backup set
channel ORA_DISK_1: specifying archived log(s) in backup set
input archived log thread=1 sequence=1 RECID=4 STAMP=948549795
channel ORA_DISK_1: starting piece 1 at 05-JUL-17
channel ORA_DISK_1: finished piece 1 at 05-JUL-17
piece handle=/u01/app/oracle/fast_recovery_area/DBC/backupset/2017_07_05/o1_mf_annnn_TAG20170705T140316_dos92fpy_.bkp tag=TAG20170705T140316 comment=NONE
channel ORA_DISK_1: backup set complete, elapsed time: 00:00:01
Finished backup at 05-JUL-17

Starting Control File and SPFILE Autobackup at 05-JUL-17
piece handle=/u01/app/oracle/product/11.2.0/db_home/dbs/c-1307993075-20170705-02 comment=NONE
Finished Control File and SPFILE Autobackup at 05-JUL-17

RMAN> list archivelog all;

List of Archived Log Copies for database with db_unique_name DBC
=====================================================================

Key Thrd Seq S Low Time
——- —- ——- – ———
19 1 2 A 01-JUL-17
Name: /u01/app/oracle/fast_recovery_area/DBC/archivelog/2017_07_05/o1_mf_1_2_doryt2co_.arc

182 1 3 A 05-JUL-17
Name: /u01/app/oracle/fast_recovery_area/DBC/archivelog/2017_07_05/o1_mf_1_3_dos783g5_.arc

199 1 4 A 05-JUL-17
Name: /u01/app/oracle/fast_recovery_area/DBC/archivelog/2017_07_05/o1_mf_1_4_dos7kv2s_.arc

286 1 1 A 05-JUL-17
Name: /u01/app/oracle/fast_recovery_area/DBC/archivelog/2017_07_05/o1_mf_1_1_dos92by5_.arc

RMAN> delete archivelog all;

released channel: ORA_DISK_1
released channel: ORA_DISK_2
allocated channel: ORA_DISK_1
channel ORA_DISK_1: SID=20 device type=DISK
allocated channel: ORA_DISK_2
channel ORA_DISK_2: SID=17 device type=DISK
List of Archived Log Copies for database with db_unique_name DBC
=====================================================================

Key Thrd Seq S Low Time
——- —- ——- – ———
19 1 2 A 01-JUL-17
Name: /u01/app/oracle/fast_recovery_area/DBC/archivelog/2017_07_05/o1_mf_1_2_doryt2co_.arc

182 1 3 A 05-JUL-17
Name: /u01/app/oracle/fast_recovery_area/DBC/archivelog/2017_07_05/o1_mf_1_3_dos783g5_.arc

199 1 4 A 05-JUL-17
Name: /u01/app/oracle/fast_recovery_area/DBC/archivelog/2017_07_05/o1_mf_1_4_dos7kv2s_.arc

286 1 1 A 05-JUL-17
Name: /u01/app/oracle/fast_recovery_area/DBC/archivelog/2017_07_05/o1_mf_1_1_dos92by5_.arc

Do you really want to delete the above objects (enter YES or NO)? yes
deleted archived log
archived log file name=/u01/app/oracle/fast_recovery_area/DBC/archivelog/2017_07_05/o1_mf_1_2_doryt2co_.arc RECID=1 STAMP=948539314
deleted archived log
archived log file name=/u01/app/oracle/fast_recovery_area/DBC/archivelog/2017_07_05/o1_mf_1_3_dos783g5_.arc RECID=2 STAMP=948547939
deleted archived log
archived log file name=/u01/app/oracle/fast_recovery_area/DBC/archivelog/2017_07_05/o1_mf_1_4_dos7kv2s_.arc RECID=3 STAMP=948548243
deleted archived log
archived log file name=/u01/app/oracle/fast_recovery_area/DBC/archivelog/2017_07_05/o1_mf_1_1_dos92by5_.arc RECID=4 STAMP=948549795
Deleted 4 objects

RMAN> list archivelog all;

specification does not match any archived log in the repository

RMAN>

RMAN> restore archivelog all;

Starting restore at 05-JUL-17
using channel ORA_DISK_1
using channel ORA_DISK_2

channel ORA_DISK_1: starting archived log restore to default destination
channel ORA_DISK_1: restoring archived log
archived log thread=1 sequence=3
channel ORA_DISK_1: reading from backup piece /u01/app/oracle/fast_recovery_area/DBC/backupset/2017_07_05/o1_mf_annnn_TAG20170705T133231_dos78vht_.bkp
channel ORA_DISK_2: starting archived log restore to default destination
channel ORA_DISK_2: restoring archived log
archived log thread=1 sequence=2
channel ORA_DISK_2: reading from backup piece /u01/app/oracle/fast_recovery_area/DBC/backupset/2017_07_05/o1_mf_annnn_TAG20170705T133231_dos78trn_.bkp
channel ORA_DISK_1: piece handle=/u01/app/oracle/fast_recovery_area/DBC/backupset/2017_07_05/o1_mf_annnn_TAG20170705T133231_dos78vht_.bkp tag=TAG20170705T133231
channel ORA_DISK_1: restored backup piece 1
channel ORA_DISK_1: restore complete, elapsed time: 00:00:15
channel ORA_DISK_1: starting archived log restore to default destination
channel ORA_DISK_1: restoring archived log
archived log thread=1 sequence=4
channel ORA_DISK_1: reading from backup piece /u01/app/oracle/fast_recovery_area/DBC/backupset/2017_07_05/o1_mf_annnn_TAG20170705T133728_dos7l19y_.bkp
channel ORA_DISK_2: piece handle=/u01/app/oracle/fast_recovery_area/DBC/backupset/2017_07_05/o1_mf_annnn_TAG20170705T133231_dos78trn_.bkp tag=TAG20170705T133231
channel ORA_DISK_2: restored backup piece 1
channel ORA_DISK_2: restore complete, elapsed time: 00:00:15
channel ORA_DISK_2: starting archived log restore to default destination
channel ORA_DISK_2: restoring archived log
archived log thread=1 sequence=1
channel ORA_DISK_2: reading from backup piece /u01/app/oracle/fast_recovery_area/DBC/backupset/2017_07_05/o1_mf_annnn_TAG20170705T140316_dos92fpy_.bkp
channel ORA_DISK_1: piece handle=/u01/app/oracle/fast_recovery_area/DBC/backupset/2017_07_05/o1_mf_annnn_TAG20170705T133728_dos7l19y_.bkp tag=TAG20170705T133728
channel ORA_DISK_1: restored backup piece 1
channel ORA_DISK_1: restore complete, elapsed time: 00:00:00
channel ORA_DISK_2: piece handle=/u01/app/oracle/fast_recovery_area/DBC/backupset/2017_07_05/o1_mf_annnn_TAG20170705T140316_dos92fpy_.bkp tag=TAG20170705T140316
channel ORA_DISK_2: restored backup piece 1
channel ORA_DISK_2: restore complete, elapsed time: 00:00:00
Finished restore at 05-JUL-17

RMAN> list archivelog all;

List of Archived Log Copies for database with db_unique_name DBC
=====================================================================

Key Thrd Seq S Low Time
——- —- ——- – ———
364 1 2 A 01-JUL-17
Name: /u01/app/oracle/fast_recovery_area/DBC/archivelog/2017_07_05/o1_mf_1_2_dos9l96v_.arc

363 1 3 A 05-JUL-17
Name: /u01/app/oracle/fast_recovery_area/DBC/archivelog/2017_07_05/o1_mf_1_3_dos9l88o_.arc

365 1 4 A 05-JUL-17
Name: /u01/app/oracle/fast_recovery_area/DBC/archivelog/2017_07_05/o1_mf_1_4_dos9lqld_.arc

366 1 1 A 05-JUL-17
Name: /u01/app/oracle/fast_recovery_area/DBC/archivelog/2017_07_05/o1_mf_1_1_dos9lqpg_.arc

RMAN>

RMAN> delete noprompt backup;

using channel ORA_DISK_1
using channel ORA_DISK_2

List of Backup Pieces
BP Key BS Key Pc# Cp# Status Device Type Piece Name
——- ——- — — ———– ———– ———-
189 187 1 1 AVAILABLE DISK /u01/app/oracle/fast_recovery_area/DBC/backupset/2017_07_05/o1_mf_annnn_TAG20170705T133231_dos78vht_.bkp
190 188 1 1 AVAILABLE DISK /u01/app/oracle/fast_recovery_area/DBC/backupset/2017_07_05/o1_mf_annnn_TAG20170705T133231_dos78trn_.bkp
203 200 1 1 AVAILABLE DISK /u01/app/oracle/fast_recovery_area/DBC/backupset/2017_07_05/o1_mf_nnndf_TAG20170705T133318_dos7bfxc_.bkp
204 201 1 1 AVAILABLE DISK /u01/app/oracle/fast_recovery_area/DBC/backupset/2017_07_05/o1_mf_nnndf_TAG20170705T133318_dos7bd8z_.bkp
218 215 1 1 AVAILABLE DISK /u01/app/oracle/fast_recovery_area/DBC/backupset/2017_07_05/o1_mf_annnn_TAG20170705T133728_dos7l19y_.bkp
228 226 1 1 AVAILABLE DISK /u01/app/oracle/product/11.2.0/db_home/dbs/c-1307993075-20170705-00
270 269 1 1 AVAILABLE DISK /u01/app/oracle/product/11.2.0/db_home/dbs/c-1307993075-20170705-01
302 299 1 1 AVAILABLE DISK /u01/app/oracle/fast_recovery_area/DBC/backupset/2017_07_05/o1_mf_annnn_TAG20170705T140316_dos92fpy_.bkp
318 316 1 1 AVAILABLE DISK /u01/app/oracle/product/11.2.0/db_home/dbs/c-1307993075-20170705-02
deleted backup piece
backup piece handle=/u01/app/oracle/fast_recovery_area/DBC/backupset/2017_07_05/o1_mf_annnn_TAG20170705T133231_dos78vht_.bkp RECID=1 STAMP=948547955
deleted backup piece
backup piece handle=/u01/app/oracle/fast_recovery_area/DBC/backupset/2017_07_05/o1_mf_annnn_TAG20170705T133231_dos78trn_.bkp RECID=2 STAMP=948547954
deleted backup piece
backup piece handle=/u01/app/oracle/fast_recovery_area/DBC/backupset/2017_07_05/o1_mf_nnndf_TAG20170705T133318_dos7bfxc_.bkp RECID=3 STAMP=948548005
deleted backup piece
backup piece handle=/u01/app/oracle/fast_recovery_area/DBC/backupset/2017_07_05/o1_mf_nnndf_TAG20170705T133318_dos7bd8z_.bkp RECID=4 STAMP=948548004
deleted backup piece
backup piece handle=/u01/app/oracle/fast_recovery_area/DBC/backupset/2017_07_05/o1_mf_annnn_TAG20170705T133728_dos7l19y_.bkp RECID=5 STAMP=948548249
deleted backup piece
backup piece handle=/u01/app/oracle/product/11.2.0/db_home/dbs/c-1307993075-20170705-00 RECID=6 STAMP=948548252
deleted backup piece
backup piece handle=/u01/app/oracle/product/11.2.0/db_home/dbs/c-1307993075-20170705-01 RECID=6 STAMP=948549392
deleted backup piece
backup piece handle=/u01/app/oracle/fast_recovery_area/DBC/backupset/2017_07_05/o1_mf_annnn_TAG20170705T140316_dos92fpy_.bkp RECID=7 STAMP=948549797
deleted backup piece
backup piece handle=/u01/app/oracle/product/11.2.0/db_home/dbs/c-1307993075-20170705-02 RECID=8 STAMP=948549800
Deleted 9 objects

RMAN> list backup;

specification does not match any backup in the repository

RMAN>

Comments

comments

Check Also

DATA BASE LINKS

DATABASE LINKS: What are the db links? create a link from one database to another …

Leave a Reply

Your email address will not be published. Required fields are marked *