Copy archive log from ASM to disk in Oracle

Copy archivelog from ASM to disk in Oracle

RMAN command is used for copying archive from ASM to Disk

RMAN> copy archivelog '+DATAARC/arch_1_seq_236.359' to '/u02/arc/arch_1_seq_236.359';

Use AMDCMD command for copying archive from ASM to Disk

asmcmd> cp +DATAARC/CDB/ARCHIVELOG/2016_05_03/arch_1_seq_236.359 /u02/backup/archivelogs/2016_05_03/arch_1_seq_236.359;

Use this for copy all the file present in archive folder

#!/bin/bash
. /home/oracle/.bash_profile
for i in $(asmcmd ls +FRA/CDB/ARCHIVELOG/);
do asmcmd cp +DATAARC/CDB/ARCHIVELOG/$i /home/backup/archivelogs/;
done

Restore archive log from back at specific location

run {
set archivelog destination to '/home/backup/archivelogs/';
restore archivelog all;
}

Backup archivelog from specific desitination

run
{
allocate channel c1 type disk format '/tmp/arc_%U';
backup archivelog all;
}

This entry was posted in Oracle on by .
Unknown's avatar

About SandeepSingh

Hi, I am working in IT industry with having more than 15 year of experience, worked as an Oracle DBA with a Company and handling different databases like Oracle, SQL Server , DB2 etc Worked as a Development and Database Administrator.

Leave a Reply