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;
}

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.