Separate listener for Data Guard - Data Guard

I am setting up a best practice about using a dedicated listener for Data Guard. The idea is to maintain full functionality of Data Guard while application team is requesting to bring down listener service (according to business requirement). Need your opinion on these:
1. I understand that there may be a very little chance when listener is required by Data Guard, but I find it no harm to do this. Do you agree with me?
2. In RAC environment, we can only have 1 VIP to be used in listener.ora. I am thinking of using same IP but different port numbers for different listener. Any better idea than this?
Many thanks 

It is never a bad practice to use separate listeners at the primary and at the Standby for Data Guard's use. A listener at the standby is required by Data Guard to make a connection to that standby. A listener at the Primary is required for Data Guard to make a reverse connection from the Standby to the Primary for some kinds of Gap resolution (missing log file the the Primary thinks it already sent or a corrupted log file etc). And of course, when you switch roles.
To answer the second question could you please tell me what version of Oracle you are using and if you plan on using the Data Guard Broker or not?
Thanks.
Larry 

It is 10.2.0.5. No, I don't plan to use Data Guard Broker, but I would like to know if I can benefit from it in this case. 

In 10.2 it is hard to do this kind of special configuration because the Broker looks at your settings and configures its own connection string to send the redo. After that no matter what changes you make to the TNS names file it uses it owns connect string.
In 11.1 the Broker introduced a new property called DGConnectIdentifier where you specify your TNS name and it always uses that. It also has StaticConnectIdentifier to allow you to specify the static listener entry you want it to use.
Larry 

When using the broker in 10.2 to define your sites, you define a connect identifier along with it. As as long as your TNS is setup on the server to point to the dedicated listener resource on the remote site, the broker will pull the TNS info from it. I use dedicated listeners for our log shipping and dataguard broker services. 

Hi Larry and Dillinger, are you saying that with DGBroker, application will not hit "tcp timed out" problem as in 9iRAC even when listener only listens to physical public IP? My concerns is to have 2 listeners and to overcome limitation in 9i RAC, Oracle has introduced VIP in 10g, but it can only be 1 in each RAC environment. 

I'm going to have to admit confusion here. Please post an example of what you want to do.
Larry 

I am sorry for the confusion, but thanks for the sharing. However, I seem to find the answer:
- Only 1 public VIP is possible in a RAC environment
- If additional VIP is required, that would be an application VIP, to be created using crs_profile with referring to $CRS_HOME/bin/usrvip.
I will have to try it soon. 

hi ,
Yes in 10g rac you can add more vips using application vips using crs_profile , i have done the same in my test enviornment for testing of multiple application failover.But in 9i rac , please guide me how can i do the same as one of my site is using the 9i rac.

Related

12c Data Guard for RAC

Hello, I have an Oracle 12.2 2-Node RAC.  I am familiar and have manually performed Data Guard installations for traditional file based environments and ASM environments.  I have been walking through the steps to create a 12c DG environment for a 2-node RAC with a standard (single-instance standby) in test to learn it. All the docs I have found, including Oracle's, are not comprehensive to me.  This includes all those Doc IDs.  Also, seems some on the internet that have documented it and got it working left out vital information on how they did it. OR maybe I am nuts and the industry way is to use Enterprise Manager and press a few buttons to do this (I hear). I need your advice.1. Can anyone recommend a link that has all the accurate steps to manually implement Data Guard in a 2-node RAC with a single-instance standby for Oracle 12.2? 2. In the real production world you implement DG in, do you use Enterprise Manager (AKA Cloud Control 13c) to do this for RAC.  Is it crazy to do this manually at this point.  Which method do you use and why I am asking?  Thank you, Mary
Here is how I create a physical standby database: How to Create a Physical Standby Database  And here is how I do it with a RAC primary: How to Create a RAC Standby Database In that second paper, follow the directions up to the section titled: Convert Standby to RAC HTH,Brian
Brian your web pages are very nice!  Thank you. I have a few things still unclear please. 1a. Using vi I manually made listener.ora changes that one would usually make for non-RAC Data Guard on the two-nodes. Is that recommended or is there a RAC best practice\method when making changes to listener (via crsctl or srvctl etc.)? 1b. Any thing particular to RAC I should know when configuring listener values that a non-RAC environment would not be concerned with? 2a. If my port number is the default (1521) do I still need to have an entry for the remote_listener?  2b. If yes, what should the value be for remote_listener on the Primary RAC DB and Standby? I think I am almost there!  After I do it a few times I'll KNOW I have it. Mary
I think I worked through those. Thanks.  I am really deep diving into you Standby pages.  Your word things really well!  I have learned a lot. I want to try and create a model where the Primary and Standby directory structures are identical.  Ideally so that I don't have to use any *_FILE_NAME_CONVERT  type syntax as your pages suggest is possible (simpler etc.). So far though not there getting the below.  What can you recommend?ORA-19527: physical standby redo log must be renamedORA-00312: online log 9 thread 0: '/u01/oradata/ORCL/onlinelog/o1_mf_9_dxhgq8b3_.log'
1a. Using vi I manually made listener.ora changes that one would usually make for non-RAC Data Guard on the two-nodes. Is that recommended or is there a RAC best practice\method when making changes to listener (via crsctl or srvctl etc.)? That's how I do it, but then I'm more old school that way.  1b. Any thing particular to RAC I should know when configuring listener values that a non-RAC environment would not be concerned with? Anything that I can think of I already documented in those papers.  2a. If my port number is the default (1521) do I still need to have an entry for the remote_listener?I do not typically set REMOTE_LISTENER, near as I can remember off the top of my head.  Cheers,Brian
So far though not there getting the below. What can you recommend?ORA-19527: physical standby redo log must be renamedORA-00312: online log 9 thread 0: '/u01/oradata/ORCL/onlinelog/o1_mf_9_dxhgq8b3_.log' When you see the ORA-19527 error, then you need to use LOG_FILE_NAME_CONVERT. I think the issue is that you are using Oracle Managed Files (OMF) here. I typically do not use OMF.  Cheers,Brian
Brian, Thanks so much for the responses.  You have definitely filled in the gaps that I have come across between the Oracle docs and practical implementation of DG. Your help pages a are great!  You explain everything really well.  One thing though, you go out of your way to point out not to explicitly indicate a Thread <number> when creating SRLs.  I find that if I don't a DGMGRL> validate database <db> shows warnings that SRL not configured for a thread.  If I drop and recreate them indicating a thread it works fine and no errors.  Do you still feel SRL should be created without a thread or just on RAC environments to omit the thread? Thanks, Mary
I never use 'validate database' in dgmgrl so I had not seen this one before. If this is causing you heartburn, then by all means ignore my earlier rule of thumb and assign the SRL to a specific thread. Rules of thumb are not always to be followed. Or saying it another way, there are exceptions to every rule.   Cheers,Brian

Need help with sqlnet.ora file in a RAC environment

We have a 2 node RAC cluster, and one of our senior DBAs is concerned that the following entry is not present in our sqlnet.ora file:
sqlnet.expire_time=1
I understand the purpose of the entry, and why it would be a good setting for a stand alone database instance. What effect would it have in a RAC database? Does RAC make this entry unnecessary?
Thank you in advance for any and all advice. 
I don't think there's anything in RAC that would change dead connection detection. This parameter will ping from a server process to a client process to see if the client is still there. RAC doesn't do that on its own (just like single-instance databases), so if you have concerns about that or if this database's clients traverse a firewall to connect to the database, you would still need to set this.
In my opinion, this is one of the many parameters that don't change at all in a RAC envionment (vs a single-instance environment). 
if you have firewall (with connection idle timeout configured) between the clients and db setting this param would make sense... 
Thank you for taking time to help me understand this parameter better!

Active dataguard configuration

Hi,
Before posing the actual question let me tell my configuration:
I have a 2 node RAC sitting on IBM AIX 6.1 power 7 on a 10gb ethernet adapter.
Version of the DB is : Oracle 11.2.0.1.0
Storage used is EMC (vns 5500).
I am using ASM for my storage. (similar is the case with my standby RAC)
Before I enable my active dataguard, I would like to know what are the OS side prerequesites other than one mentioned in the installation guide of Oracle GRID Infrastructure.
Please provide me the steps to go about in setting up the active dataguard and also do consider my scan name resolutions in case of a failover. Right now I have already set up the Grid infrastructure on the standby RAC setup.
Also I need the steps to set up a dedicated ethernet interface just for the dataguard.
thanks in advance,
regards,
pras 
Hello;
For OS restrictions see -
Oracle Support note 413484.1
Given the information you provided I do not believe you have an issue.
For a private network there is no different. The only requirement is the servers can see each other.
There's a property called DGConnectIdentifier where you specify your TNS name if you use Data Broker.
Also StaticConnectIdentifier to allow you to specify the static listener again for Broker. These are Oracle 11 and later.
The setup steps as far a Data Guard is concerned are the same.
Active Data Guard has no special setup steps. Its all about how you start the Standby database.
Ex.
startup
recover managed standby database using current logfile disconnect;
Media recovery complete.Support document is
Oracle® Data Guard Concepts and Administration 11g Release 2 (11.2) E10700-02
If you want short manual setup notes here are mine :
http://www.visi.com/~mseberg/data_guard_on_oracle_11_step_by_step.html
or
http://oracleinnotiive.wordpress.com/2010/01/26/how-to-setup-11g-active-dataguard/
Best Regards
mseberg 
Thank u very much 
>
>
Also I need the steps to set up a dedicated ethernet interface just for the dataguard.Hello - for this, one way is define the NIC as a separate network,
srvctl add network -k .....
and then define a listener and and a service for that network,
srvctl add listener .... -k ...
srvctl add service ... -k ...
and make sure that no other services register with that listener. This does work, but I have had problems when using DHCP/GNS.
Good luck.

setting up TAF for our clients

Hello all.
We are running Oracle 11GR2 on Solaris 10.
I have a physical standby database configured, but not yet configured for FSFO.
I will be setting the DGBroker to faststart failover but also need to understand how to configure clients to automatically resolve the SID to the failed over database.
So in our case, we have a database with the same name on both primary and standby servers, and only the service is different.
For discussion purposes, let's call the database DGTEST and the services as DGTEST_DG1 and DGTEST_DG2, where DG1 is primary and DG2 is standby).
So, how do I configure the tnsnames for the clients to automatically resolve to the correct SID that is active (as primary)?
My first thought was something like this:
DGTEST =
        (   DESCRIPTION=
                (FAILOVER=ON)
                (ADDRESS=(PROTOCOL=tcp)(PORT=1521)(HOST=myhost1))
                (ADDRESS=(PROTOCOL=tcp)(PORT=1521)(HOST=myhost2))
                (CONNECT_DATA=(SERVICE_NAME = DGTEST_DG2))   <=========== not sure about this part
        ) 
Interesting....
What about the following:
I would think you would want to keep you service name the same so configure a service with the same name.
Perhaps configure DNS so you are always pointing to the "live host".
So in the event of a DR you would create an alias in DNS to go to your standby host. This would mean one change in DNS rather than potentially multiple changes in client side tnsnames.
So nothing on your client side tnsnames would change.
I don't think you can configure what you want so the client will always go to the primary database without changing anything.
PS: If you're using 11gR2 then why not use SCAN? Similar principle in the event of a DR your DNS for your clients would point the SCAN to your standby hosts. 
I was also looking at SCAN, and it seems a bit complicated to set up.
FCF (fast connection failover) also seems to be an option similar to TAF.
Unfortunately, our production environment is already set up using the same database name on both primary and standby server, (with the differences on the service names similar to my example above).
This shouldn't really matter and I can do a manual switchover back and forth using this method in my test environment.
My challenge is how to set up the clients so they will automatically switch to active primary database (on a different server) when the database switches over.
Loss of connection by the client is acceptable, as long as they can reconnect and when they reconnect they will reconnect to the new primary automatically.
Most of my clients (but not all) will use an application on one of four application servers. The application servers have Oracle client on them which connects to the database.
For the few clients that are not using the application, they would be using some kind of report tool like Crystal Reports, which I believe also reads the tnsnames file (either that or uses ODBC which reads the tnsnames file). 
ji li wrote:
Hello all.
We are running Oracle 11GR2 on Solaris 10.
I have a physical standby database configured, but not yet configured for FSFO.
I will be setting the DGBroker to faststart failover but also need to understand how to configure clients to automatically resolve the SID to the failed over database.
So in our case, we have a database with the same name on both primary and standby servers, and only the service is different.
For discussion purposes, let's call the database DGTEST and the services as DGTEST_DG1 and DGTEST_DG2, where DG1 is primary and DG2 is standby).
So, how do I configure the tnsnames for the clients to automatically resolve to the correct SID that is active (as primary)?
My first thought was something like this:
DGTEST =
(   DESCRIPTION=
(FAILOVER=ON)
(ADDRESS=(PROTOCOL=tcp)(PORT=1521)(HOST=myhost1))
(ADDRESS=(PROTOCOL=tcp)(PORT=1521)(HOST=myhost2))
(CONNECT_DATA=(SERVICE_NAME = DGTEST_DG2))   <=========== not sure about this part
)Hi,
You must add a new service runing when database role is PRIMARY and a trigger for when start new service when database role changed to PRIMARY.
Please check : http://www.mahir-quluzade.com/2012/05/oracle-data-guard-11g-overview-client.html
Thanks
Mahir M. Quluzade 
That's really useful Mahir.
Unfortunately, there is no sound on your video, and perhaps because of your broken English, but overall, I get the idea and it is very useful.
Thank you very much for sharing.
Ji Li 
You are welcome!

Floating VIP between primary and standby RAC databases after role transition

Dear experts,  Does anybody have experience configure clusterware VIP, which can moved between primary and standby hosts automatically after role transition?I know we can create service whith role option in both clusters, and it will be managed by clusterware during switchover.Can I link VIP with this service?In addition, how correctly define dependencies between these resources?  There is wonderful document:White Paper. Transparent Role Transitions With Oracle Data Guard and Oracle GoldenGate.http://www.oracle.com/technetwork/database/availability/ogg-adg-2422372.pdf  It states: "Oracle recommends using a virtual IP (VIP) address for the remote host name which can be moved between the primary and standby hosts. When a VIP cannot be defined for a primary and standby host in an Oracle Data Guard environment, there is a need for additional configuration to ensure that the source Data Pump always sends trail files to the current primary host."  But, I can't find any examples, step-by-step guides, implementations of this feature in docs.oracle.com, support.oracle.com, blogs, etc.  Thank you in advance.
It's starting to show some age but there's some information here: http://www.akadia.com/services/ora_rac.html  This may also provide some useful information  Data Guard: Redo Transport Services – How to use a separate network in a RAC environment. (Doc ID 1210153.1)  Best Regards mseberg
I hope that I fully understand you. You want to create a standby for your RAC?. VIP is only related to your RAC installation. It has nothing to do with dataguard. You main focus should be first implement your RAC and make sure it functions, then go through the steps needed to set up your data guard. If you need installation guide for both, then let me know.
First of all, a "clusterware VIP" stays inside a cluster. If you really have the need for a "floating VIP" that is up on the cluster with the primary database, then you'd have to come up with some custom scripts that check the monitored database's state and accordingly start or stop an IP address. I don't know if anybody has already created such scripts and most probably such an approach is not necessary and it also has some drawbacks, as it would only work in an environment where primary and standby database are in the same network segment. Why exactly are you asking, anyway? Is it for GoldenGate (since you are citing a GG Whitepaper) or some other application that needs to connect to the database, even after a role transition? For GoldenGate, the solution is to follow MOS note 1950121.1, as indicated in the Whitepaper, right after the paragraph you mentioned. Most other applications just need a properly set up tnsnames.ora to be able to reconnect to the new primary after a role transition. I think the link provided by mseberg above shows an example for that. HTH,Andris
Yes, it is for GoldenGate.MOS note 1950121.1, you provided for another case. If we don't have clusterware (single instance for e.g.), we must use shell scripts to change RTMHOST for data pump: "When a VIP cannot be defined for a primary and standby host in an Oracle Data Guard environment" Main goal don't use any scripts and make Grid Clusterware do all work for us.I assume it is possible since it declared in White Paper.
Hi, I guess with VIP the Whitepaper does not mean "virtual IP address managed by Grid Infrastructure" but rather "IP address that is decoupled from a particular network interface".It is not possible to have a VIP which is managed by one Grid Infrastructure to move to another cluster. One Grid Infrastructure only manages resources inside it's own cluster. You need some kind of "umbrella" system (for a lack of a better term) that is aware of both clusters and which is able to manage resources across clusters. This "umbrella" could be your own set of scripts or maybe some orchestration tool, like, for instance, Oracle Site Guard (Oracle Site Guard ). Personally, I think that Site Guard is a bit too much for your particular use case, and IIRC it is by no means a turnkey solution. So, better stick to MOS note 1950121.1. Andris

Categories

Resources