cancel
Showing results for 
Search instead for 
Did you mean: 

Question: BRBACKUP and BRARCHIVE retention time

symon_braunbaer
Participant
0 Kudos

Dear experts,

At our company we are performing backups to disk via RMAN. All good, BUT our server, which holds the backups

and the archivelogs is constantly running out of space. According to the company's policies, the retention period

is 14 days, all the backups and archivelogs older than that, can be carelessly deleted. Hence, I have the following

2 questions:

1) I found the following 2 parameter in init<SID>.sap:

# retention period in days for archive log files saved on disk

# default: 30

# cleanup_disk_archive = 30

# retention period in days for database files backed up on disk

# default: 30

# cleanup_disk_backup = 30

Are those the correct parameters ?

2) How is this functionality implemented ? Do brbackup and brarchive only overwrite backups / archivelogs older

than the value specified. Or they are searching for everything older than the retention period in the backup destination

and then purge it... ?

I am asking this question, because we have old backups before and after SAP upgrade and it would be very bad,

if those backups get purged when setting those parameter(s).

Many thanks for your answer(s)!!

Accepted Solutions (1)

Accepted Solutions (1)

Reagan
Advisor
Advisor
0 Kudos

If the backups are stored to the tape (eg: TSM backup solution) then these parameters will not be helpful (as far as I know)

These parameters will work if the backups are stored in a disk.

cleanup_disk_archive (SAP Library - SAP Database Guide: Oracle (BC-DB-ORA-DBA))

Regards

RB

symon_braunbaer
Participant
0 Kudos

Hi Reagan,

yes, I am talking about backups to disk. I am only worrying, that if I set those parameters,

our old backup before the SAP upgrade will be gone... Please advise! Thank you...

former_member188883
Active Contributor
0 Kudos

Hi Symon,

You may copy the selective backup to tape and preserve it until you decide to delete that backup.

Hope this helps.

Regards,

Deepak Kori

Reagan
Advisor
Advisor
0 Kudos

Hello Symon

If you set the parameter and if the BRTools works as designed then the saved backups will be deleted based on the retention period. Else you can move the backups to a different drive.

I would consider keeping the backup taken just before the upgrade (downtime phase) for at least a month to be on the safer side.

Regards

RB

symon_braunbaer
Participant
0 Kudos

Thank you, Reagan! This is also what I have been planning, just I needed to know whether it's necessary to backup the backup 🙂 somewhere else or not!

symon_braunbaer
Participant
0 Kudos

hello Reagan,

I need to continue this topic, though I have marked my initial question as answered...

I first decided to set the retention period for BRARCHIVE in init<SID>.sap

cleanup_disk_archive = 14

But on the next BRARCHIVE runs it didn't cleanup nothing, in the destination where we are storing the archived redolog files, I can still see redologs from January !! We are using BRTOOLS 7.20 (32).

Do you know why is it not working ? Thanks !!

Reagan
Advisor
Advisor
0 Kudos

Hello Symon

Could you provide the contents of the .sap profile used please ?

Regards

RB

symon_braunbaer
Participant
0 Kudos

Hi Reagan,

there you go, I have removed all the comments from the file to make it more compact:

backup_mode = all

restore_mode = all

backup_type = online_cons

backup_dev_type = rman_disk

backup_root_dir = <path>/sap_backup/<SID>

stage_root_dir = /oracle/<SID>/sapbackup

compress = no

compress_cmd = "compress -c $ > $"

uncompress_cmd = "uncompress -c $ > $"

compress_dir = /oracle/<SID>/sapreorg

archive_function = delete_saved

archive_copy_dir = <path>/sap_backup/<SID>/oraarch

archive_stage_dir = /oracle/<SID>/sapbackup

tape_copy_cmd = cpio

disk_copy_cmd = copy

stage_copy_cmd = rcp

pipe_copy_cmd = rsh

cpio_flags = -ovB

cpio_in_flags = -iuvB

cpio_disk_flags = -pdcu

dd_flags = "obs=64k bs=64k"

dd_in_flags = "ibs=64k bs=64k"

saveset_members = 1

rman_channels = 1

rman_filesperset = 300

_rman_sess_stmt = ("alter session set optimizer_mode=RULE")

rman_parms = "SBT_LIBRARY=/oracle/<SID>/112_64/lib/libddobk.so, ENV=(STORAGE_UNIT=SAP,BACKUP_HOST=wspo013.ages.at)"

copy_out_cmd = "dd ibs=8k obs=64k of=$"

copy_in_cmd = "dd ibs=64k obs=8k if=$"

rewind = "mt -f $ rewind"

rewind_offline = "mt -f $ offline"

tape_pos_cmd = "mt -f $ fsf $"

tape_size = 100G

exec_parallel = 0

tape_address = /dev/rmt/0mn

tape_address_rew = /dev/rmt/0m

volume_archive = (<SID>A01, <SID>A02, <SID>A03, <SID>A04, <SID>A05,

                  <SID>A06, <SID>A07, <SID>A08, <SID>A09, <SID>A10,

                  <SID>A11, <SID>A12, <SID>A13, <SID>A14, <SID>A15,

                  <SID>A16, <SID>A17, <SID>A18, <SID>A19, <SID>A20,

                  <SID>A21, <SID>A22, <SID>A23, <SID>A24, <SID>A25,

                  <SID>A26, <SID>A27, <SID>A28, <SID>A29, <SID>A30)

volume_backup = (<SID>B01, <SID>B02, <SID>B03, <SID>B04, <SID>B05,

                 <SID>B06, <SID>B07, <SID>B08, <SID>B09, <SID>B10,

                 <SID>B11, <SID>B12, <SID>B13, <SID>B14, <SID>B15,

                 <SID>B16, <SID>B17, <SID>B18, <SID>B19, <SID>B20,

                 <SID>B21, <SID>B22, <SID>B23, <SID>B24, <SID>B25,

                 <SID>B26, <SID>B27, <SID>B28, <SID>B29, <SID>B30)

expir_period = 30

tape_use_count = 100

cleanup_disk_archive = 14

Reagan
Advisor
Advisor
0 Kudos

Hello Symon


archive_copy_dir = <path>/sap_backup/<SID>/oraarch

Is this the FS where the archives are backed up ?

Regards

RB

symon_braunbaer
Participant
0 Kudos

Hello Reagan,

yes it is. Though as I stated before, I can still see logs from January there.

I'll just add, that it can't be a permission problem, the files are created and owned by the oraSID user, under which the brarchive and brbackup commands are invoked.

Reagan
Advisor
Advisor
0 Kudos

Good Day Symon

I would remove the <path> from <path>/sap_backup/<SID> and then specify the exact path in the .sap profile.

has suggested the same here

http://scn.sap.com/thread/3501086

Regards

RB

Answers (0)