No question at this time
DBA Top 10
1 A. Kavsek 8400
2 B. Vroman 5900
3 M. Cadot 5400
4 P. Wisse 4800
5 T. Boles 3700
6 J. Schnackenberg 2100
7 . Lauri 1500
8 R. Pattyn 700
9 T. P 600
9 J. PĂ©ran 600
About
DBA-Village
The DBA-Village forum
Forum as RSS
as RSS feed
Site Statistics
Ever registered users48407
Total active users1518
Act. users last 24h4
Act. users last hour1
Registered user hits last week254
Registered user hits last month927
Go up

Create standby using backup sets (from Oracle 12c)
Next thread: ORA-00600: internal error code, arguments: [KGL-heap-size-exceeded],
Prev thread: Golden Gate Replication

Message Score Author Date
Hi, From Oracle 12c (if I am not mistaken), it ...... Lauri Jul 22, 2019, 15:08
From the Oracle 12c documentation I didn't find th...... Lauri Jul 22, 2019, 15:46
Often finding an example in the Oracle Documentati...... Tim Boles Jul 23, 2019, 20:28
Hi Tim, Thanks for the feedback. Indeed, I als...... Lauri Jul 24, 2019, 11:43
Hi again Lauri, Yes that syntax should work. I...... Tim Boles Jul 24, 2019, 16:54
Hi Tim, Thanks for your answer. I am indeed ...... Lauri Jul 25, 2019, 09:06

Follow up by mail Click here


Subject: Create standby using backup sets (from Oracle 12c)
Author: Lauri, Netherlands
Date: Jul 22, 2019, 15:08, 28 days ago
Os info: All
Oracle info: 12cR1 and 12cR2
Message: Hi,

From Oracle 12c (if I am not mistaken), it is possible to use backup sets to crrate a standby database.

The classic syntax used with the "active database" option is something like:

run {
set newname for datafile ...
duplicate target database for standby from active database nofilenamecheck;
}

adding the backup sets option, something like:

run {
set newname for datafile ...
duplicate target database for standby from active database using compressed backupset nofilenamecheck;
}

I have never tried it so far.
is it by the way the correct syntax?

I have read that using the "from active database using compressed backupset" option it goes faster than with the classic "from active database".
Does someone has experience with it?

Kind Regards.
Goto: Reply - Top of page 
If you think this item violates copyrights, please click here

Subject: Re-Create standby using backup sets (from Oracle 12c)
Author: Lauri, Netherlands
Date: Jul 22, 2019, 15:46, 28 days ago
Message: From the Oracle 12c documentation I didn't find this option.
I think this is an option only to duplicate a database (thus not a standby) or to refresh a standby databse...
Your rating?: This reply is Good Excellent
Goto: Reply - Top of page 
If you think this item violates copyrights, please click here

Subject: Re: Create standby using backup sets (from Oracle 12c)
Author: Tim Boles, United States
Date: Jul 23, 2019, 20:28, 26 days ago
Message: Often finding an example in the Oracle Documentation can be tricky. In this case you will find the example in Data Guard Concepts and Administration

https://docs.oracle.com/database/121/SBYDB/rcmbackp.htm#SBYDB01500

DUPLICATE TARGET DATABASE
FOR STANDBY
DORECOVER
SPFILE
SET "db_unique_name"="foou" COMMENT ''Is a duplicate''
SET LOG_ARCHIVE_DEST_2="service=inst3 ASYNC REGISTER
VALID_FOR=(online_logfile,primary_role)"
SET FAL_SERVER="inst1" COMMENT "Is primary"
NOFILENAMECHECK;

This is just one example. There are many other approaches as well that you can find just by googling it.

You are right that it is basically duplicating the database but it is using a "standby" controlfile.

Now for the compressed backup. How much faster it is depends on the circumstances. There is a balancing act here. There is extra server processing that is involved with creating and using the compressed backup. The savings you gain is in the transferring of the compressed backup set across the network for the recovery. So if you have an extremely large database who's backup files must be copied over the network to a new location then yes you will it will be faster. However, if you have a small database or not transferring across a network then probably not.

Your rating?: This reply is Good Excellent
Goto: Reply - Top of page 
If you think this item violates copyrights, please click here

Subject: Re-Create standby using backup sets (from Oracle 12c)
Author: Lauri, Netherlands
Date: Jul 24, 2019, 11:43, 26 days ago
Message: Hi Tim,

Thanks for the feedback.
Indeed, I also find that (unfortunatelly) the Oracle documentation lacks good (practical) examples and if ofter tricky to read and even to understand.
That's the reason why I posted such a thread here.

Well, personally, when I havd to set up a standby database with RMAN, I use a script like:

run {
set newname for datafile ...
duplicate target database for standby from active database nofilenamecheck;
}

It works fine. There are only few configurations to do.

If I want to use the "compressed backupset" option, is the following code the right syntax?


run {
set newname for datafile ...
duplicate target database for standby from active database using compressed backupset nofilenamecheck;
}

I could not fine a good example so far...
Is the above the correct syntax?
Does someone has experience with it?

I am still hesitating about the advantages og using the compressed backupset option.

Pros:

- The disturbance of the primary database and primary server should be minimun.
- This might be a viable option is the primary database is highly active (bank, reservation system,...).
- This might be a viable option if we have an easy access to the backup, for instance through a mounted point (on Linux/Unix).

Cons:

- Backup sets have to be read across the network, and if the database is "big" this might take some time.
- In many cases, the RMAN backups are managed by a different group of people and these backups are saved on a device (either tape or disks) that are not directly accessible, and if we want to acess the backup the procedure might take some time.
- Using the active database option is that we do not need to worry about the RMAN backup.

In your above piece of code I do not see the usage of the option using compressed backupset.

Kind Regards.
Your rating?: This reply is Good Excellent
Goto: Reply - Top of page 
If you think this item violates copyrights, please click here

Subject: Re: Re-Create standby using backup sets (from Oracle 12c)
Author: Tim Boles, United States
Date: Jul 24, 2019, 16:54, 26 days ago
Message: Hi again Lauri,

Yes that syntax should work. I have not tested it specifically but I have done similar statements but generally don't use the nofilenamecheck option.

However, there are some things I believe that you should note here.

I don't know if things have changed but in Oracle 12c the "from active database" command is not using "previous" backupsets. The command is actually creating a new backupset and then is transferring it to the remote instance. So that will probably throw off your pros and cons.

The good thing is that you can reduce the time of the backup even more beyond the compressed backupset by having parallel channels. Note: If you configure or manually allocate channels for active duplication with backup sets, ensure that the number of auxiliary channels is greater then or equal to the number of target channels. (https://docs.oracle.com/database/121/RCMRF/rcmsynta020.htm#RCMRF126)

At least this is what I saw during my testing of the duplicate database using Oracle VirtualBox.

(https://app.pluralsight.com/library/courses/ocp-12c-performing-backup-recovery-using-new-features-rman/table-of-contents)


Regards
Tim
Your rating?: This reply is Good Excellent
Goto: Reply - Top of page 
If you think this item violates copyrights, please click here

Subject: Re-Create standby using backup sets (from Oracle 12c)
Author: Lauri, Netherlands
Date: Jul 25, 2019, 09:06, 25 days ago
Message: Hi Tim,

Thanks for your answer.

I am indeed concerned by an Oracle 12c database. So, if the "from active database" is not using the current backupsets, and create new ones, the indeed my pros and cons are probably not relevant anymore...
So, it is probably not worth to use the backup sets, and I'd rather stick to the classical "from active database", even if I have a big or "active" database...

But, do you know if there are some improvements using backupsets when creating a standby database with Oracle 18c and 19c.

You mentioned two links, but I I didn't find a clear example using "duplicate target database for standby from active database using compressed backupset...".
Especially I didn't understand the last link.

In your post you mentioned that you didn't used that method for creating a standby database, do you mean that you always used the classical "from active database" (that makes copies of the data files)?

Kind Regards
Your rating?: This reply is Good Excellent
Goto: Reply - Top of page 
If you think this item violates copyrights, please click here