Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: JDBC Connection problem ORA-12505 SID does not exist

Re: JDBC Connection problem ORA-12505 SID does not exist

From: Douglas Hawthorne <douglashawthorne_at_yahoo.com.au>
Date: Mon, 08 May 2006 21:37:58 GMT
Message-ID: <WSO7g.61$S7.58@news-server.bigpond.net.au>


<brent.ryan_at_gmail.com> wrote in message news:1147118577.608410.90030_at_i40g2000cwc.googlegroups.com...
>I have a problem with a java application connecting to a test Oracle DB
> and everything works fine. However, once we were ready to move to
> production I changed the database URL and SID to connect to the new
> database and I get an error. Below are the configurations that I
> changed in my properties file and the error that was received from the
> TNS listener.
>
> OLD
> driver=oracle.jdbc.driver.OracleDriver
> url=jdbc:oracle:thin:@host:1521:h8sontst
>
> NEW
> driver=oracle.jdbc.driver.OracleDriver
> url=jdbc:oracle:thin:@new_host:1521:h8sontst
>
> Listener refused the connection with the following error:
> ORA-12505, TNS:listener does not currently know of SID given in connect
> descriptor
> The Connection descriptor used by the client was:
> (DESCRIPTION=(ADDRESS=(HOST=new_host)(PROTOCOL=tcp)(PORT=1521))(CONNECT_DATA=(SID=h8sontst)))
>
> I can connect using sqlplus with no issues from that server. Please
> help if you have any ideas? Both the test server and production server
> are running the same version of Oracle.
>

You may have to do a few more diagnostic tests before you can resolve the problem.

What does the result of 'lsnrctl status <LISTENER_NAME>' say? What you would be looking for is an indication that the listener has the Oracle instance registered.

The problem would appear to be on the server side. You have only given us information on the client side. You did not indicate how you connected to the Oracle instance on the server.

<esp>Without any other information, my guess is that you have a typo in listener.ora.</esp>

Douglas Hawthorne Received on Mon May 08 2006 - 16:37:58 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US