Path: dp-news.maxwell.syr.edu!spool.maxwell.syr.edu!drn.maxwell.syr.edu!news.maxwell.syr.edu!newsfeed.stanford.edu!sn-xit-03!sn-xit-08!sn-post-01!supernews.com!corp.supernews.com!not-for-mail
From: DA Morgan <damorgan@psoug.org>
Newsgroups: comp.databases.oracle.server
Subject: Re: RAC, the Listener and Weblogic
Date: Mon, 12 Dec 2005 10:28:12 -0800
Organization: Ye 'Ol Disorganized NNTPCache groupie
Message-ID: <1134412089.500595@jetspin.drizzle.com>
User-Agent: Mozilla Thunderbird 1.0.6 (Windows/20050716)
X-Accept-Language: en-us, en
MIME-Version: 1.0
References: <1134406882.190608.87520@g44g2000cwa.googlegroups.com>
In-Reply-To: <1134406882.190608.87520@g44g2000cwa.googlegroups.com>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
Cache-Post-Path: jetspin.drizzle.com!unknown@oracle.advtechserv.com
X-Cache: nntpcache 3.0.1 (see http://www.nntpcache.org/)
X-Complaints-To: abuse@supernews.com
Lines: 99
Xref: dp-news.maxwell.syr.edu comp.databases.oracle.server:257576

Bonk wrote:
> We have a two node Oracle RAC cluster (10.2g on Linux), which we will
> be accessing via weblogic (8.1 sp5 on Linux) and we are working to
> connect the two using the JDBC thin driver.
> 
> We are trying to setup the connection pools on the weblogic side so
> that it attempts spread its connections across the two servers as
> evenly as possible. In the event of a database node failure, we would
> like the connections to failover to the remote oracle node with minimal
> delay. Unfortunately, we cannot use the XA driver, and we are aware
> that on the weblogic side there will be some issues during the failure.
> 
> Currently our configuration on the Weblogic side looks like this:
> 
> jdbc:oracle:thin:@(description
> =(address_list=(address=(host=one-vip.com)(protocol=tcp)(port=1521))(address=(host=two-vip.com)(protocol=tcp)(port=1521))(load_balance=yes)(failover=yes))(connect_data=(service_name=SID.com)))
> 
> In the tnsnames.ora on  the rac side:
> 
> SID =
>   (DESCRIPTION =
>     (ADDRESS = (PROTOCOL = TCP)(HOST = one-vip.COM)(PORT = 1521))
>     (ADDRESS = (PROTOCOL = TCP)(HOST = two-vip.COM)(PORT = 1521))
>     (LOAD_BALANCE = yes)
>     (CONNECT_DATA =
>       (SERVER = DEDICATED)
>       (SERVICE_NAME = SID.COM)
>     )
>   )
> 
> LISTENERS_SID =
>   (ADDRESS_LIST =
>     (ADDRESS = (PROTOCOL = TCP)(HOST = one-vip.COM)(PORT = 1521))
>     (ADDRESS = (PROTOCOL = TCP)(HOST = two-vip.COM)(PORT = 1521))
>   )
> 
> 
> SID2 =
>   (DESCRIPTION =
>     (ADDRESS = (PROTOCOL = TCP)(HOST = two-vip.COM)(PORT = 1521))
>     (CONNECT_DATA =
>       (SERVER = DEDICATED)
>       (SERVICE_NAME = SID.COM)
>       (INSTANCE_NAME = SID2)
>     )
>   )
> 
> SID1 =
>   (DESCRIPTION =
>     (ADDRESS = (PROTOCOL = TCP)(HOST = one-vip.COM)(PORT = 1521))
>     (CONNECT_DATA =
>       (SERVER = DEDICATED)
>       (SERVICE_NAME = SID.COM)
>       (INSTANCE_NAME = SID1)
>     )
>   )
> 
> SID.COM =
>   (DESCRIPTION =
>     (ADDRESS = (PROTOCOL = TCP)(HOST = one-vip.COM)(PORT = 1521))
>     (ADDRESS = (PROTOCOL = TCP)(HOST = two-vip.COM)(PORT = 1521))
>     (LOAD_BALANCE = yes)
>     (CONNECT_DATA =
>       (SERVER = DEDICATED)
>       (SERVICE_NAME = SID.COM)
>       (FAILOVER_MODE =
>         (TYPE = SELECT)
>         (METHOD = BASIC)
>         (RETRIES = 180)
>         (DELAY = 5)
>       )
>     )
>   )
> 
> 
> During my latest test with this configuration I saw the following:
> 
> 1. Uneven distrabution of the connection arcoss the two rac nodes.
> 2. Doing a netstat -an I saw connection on both nodes to VIP's and the
> real IPs of the systems.
> 
> 3. In a rac node failure situation, the connections moved to the
> running system. The weblogic machines did not seem to re-establish back
> to the second RAC node after is was brought back up.
> 
> 
> Any idea, how to setup the Weblogic connection pools so that they only
> use the VIP addresses of the RAC cluster, and balance the connections a
> little better?

1. Use the thick driver
2. Let RAC handle load balancing
3. Unless you put some real load on the system Oracle will not
necessarily spread the connections. It isn't round-robin.
-- 
Daniel A. Morgan
http://www.psoug.org
damorgan@x.washington.edu
(replace x with u to respond)
