Antwort: Re: Trying to wrap my head around TAF

From: Martin Klier <>
Date: Mon, 22 Jun 2009 09:53:43 +0200
Message-ID: <>

Hi Charles,
  1. I've written two blog entries on this topic some time ago. Maybe they can light up the topic a bit, though they do not explicitely handle MAA. (the typo in the URI is correct :) )
  2. I can see one problem on the TNSNAMES.ORA you provided: loadbalance=yes over the whole (prim+stb) address block will result in regularly longer answer times because the listeners of CHICAGO1 and CHICAGO2 will be asked every now and then if they currently provide the service name specified. If not, you will "connection-failover-light" to the next entry. But I don't know out of the box, if it's possible to failover betewwen two address blocks, and load balance within each, I will have to try that (or, preferably, you can do it by yourself and let me know).
  3. Load Balancing:
  4. A TAF setup has two nearly independent load balancing mechanisms. The ordinary one is the connection load balancing specified in TNSNAMES.ORA. It simply round-robins between your address block entries, so it knows nothing about the REAL load and the real NEED to rebalance.
  5. The far better way is the server side load balancing. To understand it, you have to know how the TNS connect works: The listener of BOSTON1 is asked on port 1521 for a connection. He knows on a once-per-30-seconds-basis whether node BOSTON1 or BOSTON2 has more or less load than the other. If the local node has the lower load profile, the connection is handled like any conventional connect, the listener makes the DB openeing a port, and send this port back to the client, and terminates the 1521 connection. If not, so if BOSTON1 is on high load and BOSTON2 is on low load, the listener BOSTON1 talks the database BOSTON2 into opening a port, an IP:PORT tuple is sent back, and the 1521 connection is terminated. All of the (b) behaviour is configured by dbms_service, since the DB has to be prepared for it.
  6. the combination of (a) and (b) ensures a profile-adapted load balancing AND a balanced listener access (no hot spot, no SPOF)

Hope this helps, if there are further questions, just let me/the list know.


Mit freundlichem Gruß

Martin Klier
Senior Oracle Database Administrator

Klug GmbH integrierte Systeme
Lindenweg 13, D-92552 Teunz
Tel.:  +49 9671/9216-245
Fax.: +49 9671/9216-112

Geschäftsführer: Johann Klug, Roman Sorgenfrei
Sitz der Gesellschaft: Teunz, USt-ID-Nr. DE175481608,
HRB Nr. 2037, Amtsgericht Amberg

| Von: |
>--------------------------------------------------------------------------------------------------------------------------------------------------| |Charles Schultz <> | >--------------------------------------------------------------------------------------------------------------------------------------------------|
| An: |
>--------------------------------------------------------------------------------------------------------------------------------------------------| |ORACLE-L <> | >--------------------------------------------------------------------------------------------------------------------------------------------------|
| Datum: |
>--------------------------------------------------------------------------------------------------------------------------------------------------| |19.06.2009 22:06 | >--------------------------------------------------------------------------------------------------------------------------------------------------|
| Betreff: |
>--------------------------------------------------------------------------------------------------------------------------------------------------| |Re: Trying to wrap my head around TAF | >--------------------------------------------------------------------------------------------------------------------------------------------------|
| Gesendet | | von: |
>--------------------------------------------------------------------------------------------------------------------------------------------------| | | >--------------------------------------------------------------------------------------------------------------------------------------------------| For #2, I do see table 95-3, but I missed how it specified "server-side TAF". How does a server transparently failover? On Fri, Jun 19, 2009 at 14:56, Charles Schultz <> wrote: [Warning: High acronym content] So I have been reading the online documentation and giving myself a headache. =) Interesting how easy it is to get distracted and start reading about FCF, ONS, FAN and the like. I have two points that I think are specific to TAF and would appreciate clarification from those that have used these things in Real Life(tm). 1) The MAA documentation sets constantly refers to using both RAC and DG for HA.Yet only in a very few places do I see TAF configurations utilizing both RAC and DG. For example, here is snippet from "Client Failover Best Practices for Highly Available Oracle Databases: Oracle Database 10g Release 2": SALESOCI =   (DESCRIPTION =     (ADDRESS_LIST =       (ADDRESS = (PROTOCOL = TCP)(HOST = BOSTON1)(PORT = 1521))       (ADDRESS = (PROTOCOL = TCP)(HOST = BOSTON2)(PORT = 1521))       (ADDRESS = (PROTOCOL = TCP)(HOST = CHICAGO1)(PORT = 1521))       (ADDRESS = (PROTOCOL = TCP)(HOST = CHICAGO2)(PORT = 1521))       (LOAD_BALANCE = yes)     )     (CONNECT_DATA=       (SERVICE_NAME=salesOCI)     )   ) Additionally, in other bodies of work I very rarely see this combination. I am curious, if this is a "Best Practice", how come it is not more widely used? Surely this is not that new (while the whitepaper cited above is from March of 2009, the features are from Oracle 10gR2). Are folks using this type of connection string in Real Life, to not only go between nodes in one cluster, but also to "failover" to standby nodes? Note that in the quoted example, this is not a stretch cluster (between Chicago and Boston! Wow!), but rather a Primary/Standby environment. 2) Similar to this, I am trying to understand the different TAF parameters used in dbms_service.create_service. The documentation has very little to say about them (just the bare bones - the 11g documentation is exactly the same I think), and when one implicitly creates a service by modifying the SERVICE_NAMES parameter, all the parameters default to null (according to dba_services). Are those TAF parameters actually used, or are they merely place-holders for "future" functionality? If they do play a role in TAF, what and how? Thanks for your time and help. -- Charles Schultz -- Charles Schultz --
Received on Mon Jun 22 2009 - 02:53:43 CDT

Original text of this message