JDBC url for oracle RAC
Posted by Enrico Giurin Thu, 12 Apr 2007 01:07:00 GMT
If you have to connect to oracle RAC (Real Application Cluster) using JDBC with thin driver, the classic url:jdbc:oracle:thin:@<HOST>:1521:<SID>Instead, you must use this url:
jdbc:oracle:thin:@(DESCRIPTION=(LOAD_BALANCE=on)
(ADDRESS=(PROTOCOL=TCP)(HOST=host1) (PORT=1521))
(ADDRESS=(PROTOCOL=TCP)(HOST=host2) (PORT=1521))
(CONNECT_DATA=(SERVICE_NAME=service)))



I kept getting this error over and over. I was hoping that a simple copy paste will solve it, as I just got sooooo annoyed from trying to solve it in the last 2 hours… and praise the lord it worked :) Changing the URLs as u stated did the trick and the connection worked flawlessly.
THANKS A LOT !
Thanks Enrico , it is very helpful for me
Unfortunately for me even this didn’t work. I’m using a WebSphere 5 server with connection pools on a system with a 9i client connecting to a 10g RAC. When the client didn’t work I tried using jdbc as above, however I still get : Connection not available while invoking method queueRequest for resource jdbc/racserver. I can test the connection successfully but can’t create a pooled connection. J2CA0020E: The Connection Pool Manager could not allocate a Managed Connection: com.ibm.websphere.ce.j2c.ConnectionWaitTimeoutException
Thanks alot, this artical help me much
Use this url: jdbc:oracle:thin:@host1^host2:1521:service_name
Thanks a lot for the posting.. It helped us to get through
Some oracle forum posts seems to suggest that there is some issue with DB, but this post really helped.
Gracias…
\o/ It’s incredible right!
I agree,all children, even those with suspected or known mitochondrial diseases, should receive the recommended vaccinations.Thanks for sharing this information Bali Property
Good ! The information stated here is very useful, thanks! Like to read more. Prateek Stylome
I read your blog,it was awesome as it helped me gain so much of information about your website, i would be desperate to see such kind of more interesting blog in the near future.Prateek Noida. Prateek Stylome Noida
I gone through your blog it was very informative as it helped me to enhance ny knowledge to a great extent. looking forward for such kind of more blog in your website.Prateek Stylome
prateek stylome
I was reading your blog, i really found it very interesting and would like to see more such kind blogs at your website at its sooner. Prateek Stylome Noida prateek stylome noida
This works.. Thanks
thanks a lot…though the rac url looks nasty, i guess thatz the way to go….good job :)
jdbc:oracle:thin:@:1521:
in the above URL ’@’ stands for what ????
Thanks so much. It helped me to fix an issue.