Home » RDBMS Server » Backup & Recovery » RMAN Backup
RMAN Backup [message #350910] Sat, 27 September 2008 08:28 Go to next message
Mary08
Messages: 3
Registered: September 2008
Location: Athens
Junior Member
Hi to everyone,

I am new to Oracle and I would like to ask you something regarding Backup using RMAN.

I have created a weekly script using RMAN commands to take Incremental level 0 backup.
The script before taking the next weekly backup deletes the previous for disk space reasons (not enough space for 2 backups). Each backup is about 75GB.

What I would like to do is before deleting the last backup and taking the next backup all the previous backup files and Archivelogs to be copied to another local disk, to a specific path.

I tried to put a 'cp' command but the backup is using RMAN and it does not of course understand the cp command.

Is there any similar copy command for RMAN or what can I do to copy it somewhere before deleting it from script.

Of course I could do that manually but it is not possible!!

Thanks
Mary
Re: RMAN Backup [message #350914 is a reply to message #350910] Sat, 27 September 2008 10:22 Go to previous messageGo to next message
ebrian
Messages: 2794
Registered: April 2006
Senior Member
You could copy the files with an O/S copy command and then use RMAN to remove the backups prior to performing the new backup. Another option would be to use BACKUP BACKUPSET command to "copy" the backups to another area and then use RMAN to delete the local version.
Re: RMAN Backup [message #350947 is a reply to message #350910] Sun, 28 September 2008 00:52 Go to previous messageGo to next message
Mary08
Messages: 3
Registered: September 2008
Location: Athens
Junior Member
Thanks for the answer,

The thing is that my script is being called from rman and a cp command is not accepted in the script.

The script contains the following line to call the script:
/uorabin/app/oracle/product/9.2/bin/rman @/home/oracle/backup

so if I put a cp /u04/Backup/* /u03/BACKUP/ before the following commands:
connect target sys/manager
delete backup;
delete archivelog all;
backup incremental level 0 database plus archivelog;
exit;

the cp command cannot be read.

Re: RMAN Backup [message #350975 is a reply to message #350947] Sun, 28 September 2008 08:40 Go to previous message
ebrian
Messages: 2794
Registered: April 2006
Senior Member
If you are using crontab to run your script, just add the cp portion right before rman is executed.

------- example backup script that crontab calls --------
# copy previous backup
cp -p /u04/Backup/* /u03/BACKUP/

# perform current backup
/uorabin/app/oracle/product/9.2/bin/rman @/home/oracle/backup
---------------------------------------------------------
Previous Topic: Differential backup
Next Topic: reg EXPORT and IMPORT
Goto Forum:
  


Current Time: Mon Nov 25 23:15:25 CST 2024