Home » RDBMS Server » Backup & Recovery » adding DBID to rman backup definition (rman)
adding DBID to rman backup definition [message #526929] Thu, 13 October 2011 13:57 Go to next message
fourty2
Messages: 6
Registered: January 2011
Junior Member
hi all,

is there any way I can add the DBID to my rman backup name?
I've already tried %F/%f as seen in the man page. but this option remains ignored.

It works for the rman backup of the controlfile. but no change to get this running proper for the datafiles.

any ideas? Confused
Re: adding DBID to rman backup definition [message #526933 is a reply to message #526929] Thu, 13 October 2011 14:31 Go to previous messageGo to next message
Mahesh Rajendran
Messages: 10707
Registered: March 2002
Location: oracleDocoVille
Senior Member
Account Moderator
%F is meant only for controlfiles.
You can tag the backup, if that helps but cannot change the format.
Re: adding DBID to rman backup definition [message #526991 is a reply to message #526933] Fri, 14 October 2011 04:20 Go to previous messageGo to next message
fourty2
Messages: 6
Registered: January 2011
Junior Member
I see...

I've added this to a rman script now.
dbid=$(echo -e "select dbid from v\$database;" | sqlplus / as sysdba 2>/dev/null | grep [0-9][0-9][0-9][0-9][0-9][0-9] | sed -e 's/ //g')
configure channel device type disk format '$bakdir/$ORACLE_SID-$dbid-ora-df%t_s%s_s%p';

works for me.

thx!
Re: adding DBID to rman backup definition [message #527018 is a reply to message #526991] Fri, 14 October 2011 08:40 Go to previous messageGo to next message
BlackSwan
Messages: 26766
Registered: January 2009
Location: SoCal
Senior Member
>works for me.
For some definition of "works".

How successful was DB restore using this backup?
Re: adding DBID to rman backup definition [message #527298 is a reply to message #527018] Mon, 17 October 2011 07:00 Go to previous message
fourty2
Messages: 6
Registered: January 2011
Junior Member
BlackSwan wrote on Fri, 14 October 2011 15:40
>works for me.
For some definition of "works".

How successful was DB restore using this backup?


do you think there might be a problem with such definition?
I haven't done a restore yet, but rman, at least, recognizes the backups correct.
I see no reason why restoring shouldn't work proper...?
Previous Topic: rman catalog
Next Topic: RMAN script query
Goto Forum:
  


Current Time: Thu Mar 28 05:35:38 CDT 2024