| Oracle FAQ | Your Portal to the Oracle Knowledge Grid | |
Home -> Community -> Usenet -> c.d.o.server -> Re: RAC, the Listener and Weblogic
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?
Hi Bonk!
A few things:
1 - the thin driver won't be using the tnsnames.ora file.
2 - "Unfortunately, we cannot use the XA driver" Why is that?
3 - "and we are aware that on the weblogic side there will be
some issues during the failure." What issues? If you are not
doing XA, there should be no issues.
4 - Are you using WebLogic multipools?
configured to only know their local instance. Otherwise the
listener you're talking to might decide to connect to a
remote instance anyway, and might possibly confound the
load-balancing at the driver.
6 - WebLogic won't discard a functioning JDBC connection, and doesn't
know what RAC node it's connected to. If WLS starts with 20 cons to
node A and 20 cons to node B, and then B goes down, WebLogic will
replace the broken connections. The driver will give WebLogic new
connections, all to node A. Until you kill those connections, we'll
use them. Multipools are what you want, instead of driver level
load balancing.
Let me know if you have any more questions, Joe Weinstein at BEA Systems Received on Mon Dec 12 2005 - 11:26:40 CST
![]() |
![]() |