db-torque-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Thomas Fischer <fisc...@seitenbau.net>
Subject RE: Problem connecting to Oralce-10g server in an RAC cluster
Date Mon, 25 Jul 2005 17:10:00 GMT




Hi,

I have seen trouble before if one tries using the thin protocol and a
connection string instead of a sid.
Try to define the service name in tnsnames.ora, and use the oci protocol
instead of the thin protocol. The connection url looks like
jdbc:oracle:oci:@ABCDE.WXYZ

Trouble is that oci is more complicated to use than thin, e.g. an oracle
client has to be installed on the client, the jar version from the
installed client has to be used etc. But to check that, you need not use
Torque, you can also use plain jdbc, e.g. DriverManager.getConnection(url,
user, password), then you do not have to startup torque every time. (Which
means: It is not a Torque problem, but a jdbc problem)

     Thomas

JiLong Rao <torq4j@sbcglobal.net> schrieb am 25.07.2005 18:23:50:

>
> I have been using Jetspeed-1.4/1.5 connected to Oralce-8i and 9i via
> Torque for years. It has always been working very well until now
> when we shift the connection to a new Oralce-10g DB server with an
> RAC cluster. Only thing I changed in torque.properties file is:
>
> torque.dsfactory.default.connection.url = jdbc:oracle:thin:@xxx.xxx.
> xxx.xxx:1521:ABCDE
>
> of course with correct user ID and password. Then a fatal error
> comes out, connection is failed (detailed info is attached).
>
>
>
> Only source I can realize is as follows: In previous successful
> connections, ABCDE is always the value of SID. However, the
> Oralce-10g DB server is configured now in an RAC cluster and gives
> us its connection string with SERVICE_NAME = ABCDE.WXYZ as:
>
> ABCDE =
>
>   (DESCRIPTION =
>
>     (ADDRESS = (PROTOCOL = TCP)(HOST = xxx.xxx.xxx.xxx)(PORT = 1521))
>
>     (ADDRESS = (PROTOCOL = TCP)(HOST = yyy.yyy.yyy.yyy)(PORT = 1521))
>
>     (LOAD_BALANCE = yes)
>
>     (CONNECT_DATA =
>
>       (SERVER = DEDICATED)
>
>       (SERVICE_NAME = ABCDE.WXYZ)
>
>     )
>
>   )
>
> It means that the string ABCDE is not the SID anymore and is not
> service_name either. It is rather be the tnsname in tnsnames.ora
> file where the Tomcat is located.  It is corresponding to the
> SERVICE_NAME of ABCDE.WXYZ in the above string. This might the
> source triggering the error since that torque could ask a valid
> format of "host:port:sid" in its properties file.
>
>
>
> Therefore, the question might become: how to set torque.dsfactory.
> default.connection.url correctly when using SERVICE_NAME rather than
> SID ?  Please be aware:
>
> the SID is always a one word string and SERVICE_NAME in an RAC
> cluster is a dot separated multi-words string.
>
>
>
> Thanks for your help.
>
>
>
> James
>
>
>
> Attached: Error message
>
>
>
> Jul 22, 2005 10:45:19 AM org.apache.torque.oid.IDBroker <init>
>
> WARNING: IDBroker is being used with db 'default', which does not
> support transactions. IDBroker attempts to use transactions to limit
> the possibility of duplicate key generation.  Without transactions,
> duplicate key generation is possible if multiple JVMs are used or
> other means are used to write to the database.
>
> Jul 22, 2005 10:45:19 AM org.apache.torque.util.BasePeer initTableSchema
>
> SEVERE: org.apache.torque.TorqueException: Io exception: Connection
> refused(DESC
>
> RIPTION=(TMP=)(VSNNUM=168821504)(ERR=12505)
> (ERROR_STACK=(ERROR=(CODE=12505)(EMFI
>
> =4))))
>
> Jul 22, 2005 10:45:19 AM org.apache.jetspeed.om.security.turbine.
> BaseTurbineUser
>
> Peer initClass
>
> SEVERE: A FATAL ERROR has occurred which should not have happened
> under any circ
>
> umstance.  Please notify the Torque developers <turbine-torque-
> dev@jakarta.apach
>
> e.org> and give as many details as possible (including the error stack
trace).
>
> java.lang.Error: Error in BasePeer.initTableSchema(TURBINE_USER):
Ioexception:
>
> Connection refused(DESCRIPTION=(TMP=)(VSNNUM=168821504)(ERR=12505)
> (ERROR_STACK=(
>
> ERROR=(CODE=12505)(EMFI=4))))
>
>         at
org.apache.torque.util.BasePeer.initTableSchema(BasePeer.java:274)
>
>         at
org.apache.torque.util.BasePeer.initTableSchema(BasePeer.java:249)
>
> (Detailed error stack trace will be suplyed upon request))
>
>
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
For additional commands, e-mail: torque-user-help@db.apache.org


Mime
View raw message