Oracle JDBC Connection Error code 12505 in J2EE

Hi All,
I'm in a great problem.Could not connect my J2EE server to my Oracle database server.
My config/resource.properties file as follows
================================
jdbcDataSource.5.name=jdbc/iisdb
jdbcDataSource.5.url=jdbc:oracle:thin:@128.51.12.33:15 21:iisals.rsapps;create=true
jdbcDriver.1.name=oracle.jdbc.driver.OracleDriver
My config/default.properties file as follows
================================
jdbcDatasources=jdbc/iisdb|jdbc:oracle:thin:@128.51.12.33:1521:iisals.rsapps
Deployment is successful but while running the application through browser the error is as follows
=======================================
javax.ejb.CreateException: java.sql.SQLException: Io exception: Connection refused(DESCRIPTION=(TMP=)(VSNNUM=135286784)(ERR=12505)(ERROR_STACK=(ERROR=(CODE=12505)(EMFI=4))))
which is for either SID identification problem or TCP/IP
port problem.
But from my PC the same database can be connected through sql plus.
So I am n't getting where is the problem ??????
Whether any properties file has to be changed ???
Can anyone help me in this regards,

Hai everybody,
I do have the same problem. I am trying to connet to the oracle8.1.7 database in linux machine from windows98. I am able to connect to the database thro' sqlplus, but when i try to connect using JDBC i am getting the follg error :
java.sql.SQLException: Io exception: Connection refused(DESCRIPTION=(TMP=)(VSNNU
M=135294976)(ERR=12505)(ERROR_STACK=(ERROR=(CODE=12505)(EMFI=4))))
can any one rectify this problem. I checked even java.policy file. Everything seems to be ok.
Thx & regards
jagan

Similar Messages

  • Tomcat 5.5.20 / Oracle  JDBC connection error

    Hi All,
    I am using Eclipse 3.2/ Tomcat 5.5.20/ Oracle 8i
    Inside my java class; right after finding the context, it gives error on line:
    conn = dataSource.getConnection();
    my server.xml <Resource> settings are proper within one tag...
    I am loosing my hair faster... please someone help me..
    Error Stack:
    javax.servlet.ServletException
         org.apache.struts.action.RequestProcessor.processException(RequestProcessor.java:545)
         org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:486)
         org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:274)
         org.apache.struts.action.ActionServlet.process(ActionServlet.java:1482)
         org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:525)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
    root cause
    java.lang.NullPointerException
         com.nibtt.beans.ConnectionBean.getConnection(ConnectionBean.java:80)
         com.nibtt.actions.LoginAction.execute(LoginAction.java:44)
         org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:484)
         org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:274)
         org.apache.struts.action.ActionServlet.process(ActionServlet.java:1482)
         org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:525)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
    Regards
    Hepzi

    Hi Zadok,
    I am going insane. Thank God you replied. I am pasting my code here.
    I have setup Tomcat5.5.20 <resource> tag as follows: for connection pooling
    <Resource      name="jdbc/TestStrutsDB" auth="Container"
              type="javax.sql.DataSource" factory="org.apache.commons.dbcp.BasicDataSourceFactory"
              username="SCOTT" password="TIGER"
              driverClassName="oracle.jdbc.driver.OracleDriver" url="jdbc:oracle:thin:@111.1.1.1:1521:TEST"
              maxActive="8" maxIdle="4"/>
    my application web.xml code:
    <resource-ref>
    <description>Oracle DB Connection</description>
    <res-ref-name>jdbc/TestStrutsDB</res-ref-name>
    <res-type>javax.sql.DataSource</res-type>
    <res-auth>Container</res-auth>
    </resource-ref>
    my java code:
    public Connection getConnection() throws Exception{
              Context ctx = new InitialContext();
    Context envContext = (Context)ctx.lookup("java:/comp/env");
    javax.sql.DataSource dataSource = null;
         ResultSet rst = null;
         Statement stmt = null;
         try {
              if(envContext == null ) {
         System.out.println( "context is NULL");
              } else
         System.out.println( "context is NOT NULL");
    dataSource = (javax.sql.DataSource)envContext.lookup("jdbc/TestStrutsDB");
              if (dataSource != null) {
                   System.out.println( "before actual connection to database: "+dataSource.toString() );
                   try {
                        conn = dataSource.getConnection();
                   } catch (Exception connEx) {
                        System.out.println( connEx.getStackTrace());
              if(conn != null) {
         System.out.println( "Got Connection "+conn.toString());
         stmt=conn.createStatement();
         rst=stmt.executeQuery("select username from testTomcat");
         while(rst.next()){
              System.out.println("User Name is: " + rst.getString("username"));
         rst.close();
         rst = null;
         stmt.close();
    stmt = null;
    conn.close();
         conn = null;
         // do what you wish with Connection
         } catch (SQLException e) {
              while((e = e.getNextException()) != null) {
                        System.out.println("SQLException: " + e.getMessage());
                        System.out.println("SQLState: " + e.getSQLState());
                        System.out.println("VendorError: " + e.getErrorCode());
                        System.out.println(e.getStackTrace());
         } finally {
         try {
         conn.close();
         } catch (SQLException ex) {
              System.out.println(ex.getStackTrace());
              return conn;
         } //End of Connection function
    Please let me know if had gone wrong somewhere
    Thanks in advance
    Regards
    Hepzi

  • Oracle JDBC Connection Error ?

    Hi all .. i have JDeveloper9.0 and oracle database i have created the following page (which is the first !) to test the connection to oracle database,
    <%@ page contentType="text/html;charset=WINDOWS-1252"%>
    <%@ page import="java.sql.*"%>
    <%@ page import="oracle.jdbc.driver.*"%>
    <HTML>
    <HEAD>
    <META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=WINDOWS-1252">
    <META NAME="GENERATOR" CONTENT="Oracle JDeveloper">
    <TITLE>
    Hello World
    </TITLE>
    </HEAD>
    <BODY>
    <%
    out.println("good things comes for the ones whos wait");
    // testing Database Connection
    Class.forName("oracle.jdbc.driver.OracleDriver");
    Connection conn = DriverManager.getConnection("jdbc:oracle:thin:@10.0.24.23:1513:test","ap1s","ap1s");
    Statement st = conn.createStatement();
         ResultSet rs= st.executeQuery("select * from XX_CNSLTNT");
         while(rs.next())
    System.out.println(rs.getString(1));
    %>
    <form method="POST" action="untitled1.jsp">
    <p>
    <input type="text" name="T1" size="20">
    <input type="submit" value="Submit" name="B1">
    <input type="reset" value="Reset" name="B2">
    </p>
    </form>
    </BODY>
    </HTML>
    and its generating me this error, when i compile :
    Error: cannot access directory oracle\jdbc\driver; verify that directory is reachable from classpath and/or sourcepath
    so, does any one have a clue of the problem is ??
    thanx in advance

    Is ojdbc14.jar or classes12.jar in the Classpath?

  • JDBC Connections in Oracle9iAS Containers for J2EE

    does anyone have an idea as to what jdev libraries aside from j2ee and jdbc that i can include to get the OTN article "JDBC Connections in Oracle9iAS Containers for J2EE" to at least compile?
    Thank you
    Jim
    The url for the excellent article is;
    http://www.oracle.com/technology/sample_code/tech/java/codesnippet/j2ee/jdbc/JDBC_in_J2EE.html

    gday to you mate!
    The solution is probably very simple it is just that i can't see it. i am getting the following messages from jdev9.0.5.2 build 1618 debug with the j2ee and Oracle JDBC libraries on this code:
    60     javax.naming.InitialContext ic = new javax.naming.InitialContext();
    61     oracle.jdbc.pool.OracleConnectionPoolDataSource ds = (oracle.jdbc.pool.OracleConnectionPoolDataSource)ic.lookup("jdbc/pool/OracleConnectionPoolDS");
    62 oracle.jdbc.pool.OraclePooledConnection pc = ds.getPooledConnection();
    63 oracle.jdbc.driver.OracleConnection conn1 = pc.getConnection();
    Project: C:\JDev\jdev\mywork\DVDOrdering\ViewController\ViewController.jpr
    C:\JDev\jdev\mywork\DVDOrdering\ViewController\src\view\InsertOrder.java
    Error(62,86): incompatible types; found: javax.sql.PooledConnection, required: oracle.jdbc.pool.OraclePooledConnection
    Error(63,82): incompatible types; found: java.sql.Connection, required: oracle.jdbc.driver.OracleConnection
    Thanks again!

  • ADF: Gracefully handling JDBC connection errors?  Part II

    Hi gang
    I while back I posted a forum post to find a solution to "display a specific web page when the JDBC connection drops out on our ADF application, specifically the following error: oracle.jbo.DMLException: JBO-26061: Error while opening JDBC connection"
    ...you can see the original post here:
    Re: ADF: Gracefully handling JDBC connection errors?
    For the life of me I can't get this to work now. It appears I can't redirect to another page during the call to reportException. I've had a play with different methods of redirecting, as seen in the following code sample:
    public class ErrorHandlerImpl extends DCErrorHandlerImpl {
      public ErrorHandlerImpl() {
        super(true);
      @Override
      public void reportException(DCBindingContainer dCBindingContainer, Exception exception) {
    //    try {
          String message = exception.getMessage();
          if (message.indexOf("JBO-26061") >= 0) {
            // Method 1
            FacesContext fc = FacesContext.getCurrentInstance();
            UIViewRoot viewRoot =
            fc.getApplication().getViewHandler().createView(fc, "faces/errorPage.jspx");
            fc.setViewRoot(viewRoot);
            fc.renderResponse();
            // Method 2              
            // FacesContext fc = FacesContext.getCurrentInstance();
            // fc.getApplication().getNavigationHandler().handleNavigation(fc, null, "goError");
            // fc.responseComplete();
            // Method 3 - required IOExcepition handler
            // FacesContext.getCurrentInstance().getExternalContext().redirect("faces/errorPage.jspx");
          } else
              super.reportException(dCBindingContainer, exception);
    //    } catch (IOException e) {
    }... with no success.
    Has anyobody any other solutions or advice on getting this to work?
    Your help appreciated.
    Thanks & regads,
    CM.
    PS. JDev 11gR1 ADF BC + ADF Faces RC

    Hi Frank
    Yep, I' tried redirect, that was method 3 (you can see all 3 methods I've attempted, last 2 are commented out).
    With the declarative ADFc exception handler, problem is it's a catch all, not specifically for JBO-26061. Can you think of a way I can tailor fit it for JBO-26061 with a custom message "Database down"?
    In addition the exception handler is not consistently called. As example, if you're moving between pages rather than operating on 1 page, the standard af:messages error dialog is shown if the db connection has been dropped, rather than navigating to the exception handler page. As such it seems the DCErrorHandlerImpl.reportExceptions is the better chokepoint to work from.
    Cheers,
    CM.

  • The Network Adapter could not establish the connection Error Code: 17002

    Hi,
    after upgrade b41 to b49, I get error from subject, without any changes in my app.
    This occurs only on Oracle AS, on standalone OC4J application works OK.
    I use connection defined in persistence.xml:
    <non-jta-data-source>jdbc/MyAppDS</non-jta-data-source>
    and can successfully test this connection in Enterprise manager.
    Also, I tried all tricks mentioned here:
    http://www.websina.com/bugzero/kb/oracle-connection.html
    I know, that this is JDBC layer problem, but I am sure, that my connection is OK, and
    after downgrade to b48 this problem fall away.
    Bye,
    Lumir

    Could you provide the full stack trace to the exception.Exception [TOPLINK-4002] (Oracle TopLink Essentials - 2.0 (Build b50-beta3 (06/07/2007))): oracle.toplink.essentials.exceptions.DatabaseException
    Internal Exception: java.sql.SQLException: Výjimka vstupu/výstupu: The Network Adapter could not establish the connection
    Error Code: 17002
         at oracle.toplink.essentials.exceptions.DatabaseException.sqlException(DatabaseException.java:305)
         at oracle.toplink.essentials.jndi.JNDIConnector.connect(JNDIConnector.java:150)
         at oracle.toplink.essentials.sessions.DatasourceLogin.connectToDatasource(DatasourceLogin.java:185)
         at oracle.toplink.essentials.internal.databaseaccess.DatasourceAccessor.connect(DatasourceAccessor.java:233)
         at oracle.toplink.essentials.internal.databaseaccess.DatabaseAccessor.connect(DatabaseAccessor.java:242)
         at oracle.toplink.essentials.internal.databaseaccess.DatasourceAccessor.connect(DatasourceAccessor.java:309)
         at oracle.toplink.essentials.threetier.ConnectionPool.buildConnection(ConnectionPool.java:117)
         at oracle.toplink.essentials.threetier.ExternalConnectionPool.startUp(ExternalConnectionPool.java:135)
         at oracle.toplink.essentials.threetier.ServerSession.connect(ServerSession.java:458)
         at oracle.toplink.essentials.internal.sessions.DatabaseSessionImpl.login(DatabaseSessionImpl.java:586)
         at oracle.toplink.essentials.ejb.cmp3.EntityManagerFactoryProvider.login(EntityManagerFactoryProvider.java:235)
         at oracle.toplink.essentials.internal.ejb.cmp3.EntityManagerSetupImpl.deploy(EntityManagerSetupImpl.java:227)
         at oracle.toplink.essentials.internal.ejb.cmp3.base.EntityManagerFactoryImpl.getServerSession(EntityManagerFactoryImpl.java:93)
         at oracle.toplink.essentials.internal.ejb.cmp3.base.EntityManagerFactoryImpl.createEntityManagerImpl(EntityManagerFactoryImpl.java:126)
         at oracle.toplink.essentials.internal.ejb.cmp3.base.EntityManagerFactoryImpl.createEntityManagerImpl(EntityManagerFactoryImpl.java:120)
         at oracle.toplink.essentials.internal.ejb.cmp3.EntityManagerFactoryImpl.createEntityManager(EntityManagerFactoryImpl.java:91)
         at idea.isko.db.service.impl.AbstractServiceImpl.createEntityManager(AbstractServiceImpl.java:77)
    How have you deployed your application exactly, i.e. what is the structure of your ear. I use standard war for deploy.
    Is the DataSource defined in your server, or your application? Defined on server, test on Enterprise manager passed successfully.
    Try using a direct JDBC connection in your persistence.xml (driver/url), does this work?Not work, this same exception.
    How do you access your entity manager? (managed, non-managed, jta, non-jta?)non-managed, non-jta.
    FYI, I make downgrade to build 48, and this works - it is last version without this problem.
    I added some tracing code to my SessionCustomizer:customize():
    DatabaseLogin login = session.getLogin();
    logger.fine("URL is :" + login.getDatabaseURL());
    With build 48, connection defined using toplink.jdbc.* , the output is:
    07/06/11 10:04:36.218 10.1.3.1.0 Started
    07/06/11 10:04:43.593 MyApp: 10.1.3.1.0 Started
    07/06/11 10:05:18.578 MyApp: FINE - Customizing session - directProperties
    07/06/11 10:05:18.578 MyApp: FINE - URL is :jdbc:oracle:thin:@(DESCRIPTION ... (cut)
    07/06/11 10:07:16.875 MyApp: 10.1.3.1.0 Stopped
    And after upgrade to build 50:
    07/06/11 10:10:12.703 10.1.3.1.0 Started
    07/06/11 10:10:30.953 MyApp: 10.1.3.1.0 Started
    07/06/11 10:10:52.281 MyApp: FINE - Customizing session - directProperties
    07/06/11 10:10:52.296 MyApp: FINER - THROW
    Local Exception Stack:
    Exception [TOPLINK-28014] (Oracle TopLink Essentials - 2.0 (Build b50-beta3 (06/07/2007))): oracle.toplink.essentials.exceptions.EntityManagerSetupException
    Exception Description: Exception was thrown while processing property [toplink.session.customizer] with value [idea.jpa.util.ToplinkSessionCustomizer].
    Internal Exception: Exception [TOPLINK-7058] (Oracle TopLink Essentials - 2.0 (Build b50-beta3 (06/07/2007))): oracle.toplink.essentials.exceptions.ValidationException
    Exception Description: Invalid Connector [JNDIConnectordatasource name=>null] (must be of type DefaultConnector).
    It seems to me, that Login is not properly initialized when app. run in Oracle AS.
    Bye,
    Lumir

  • Configure JDBC connection ERROR: no ocijdbc9 in java.library.path

    ERROR: no ocijdbc9 in java.library.path
    step 6 is where I need help!? thanx.
    When configuring a database connection, I chose
    1. Oracle JDBC (connection type)
    2. Authentication (username/password of my D2K repository)
    3. Driver: oci8
    4. Hostname: pmurphy1 (my local machine where my db is)
    5. Port: 1521 default (odbc works on this)
    * 6. Enter custom JDBC url (? please help ?) left blank!!
    I really wanna get started with this cool toy!!!
    Cheers,
    Paully

    I am assuming you are using JDeveloper 3.2x
    Please see the online help for additional details.
    Search help for "JDBC Connection Properties" - With the
    quotations and you will find a page names "JDBC Connection
    Properties"
    This page contains the following info and additional links.
    -John
    ------------- COPIED FROM HELP ---------------
    Oracle JDBC-OCI8 Driver
    Use this type 2 driver when creating a Java application that
    runs against an Oracle8i server. This is a thick driver
    optimized for the Oracle8i database: it cannot be used with
    applets. This driver handles any database protocol (TCP, IPX,
    BEQ, and so on). It is required for applications which are run
    from the machine they are stored on. It can also be used against
    an Oracle7 database.
    This driver requires client software installation. The project
    must also include the correct version of the driver in a library
    and include no other Oracle JDBC library. This driver is
    included in the default Oracle JDBC library for all projects.
    The library is named Oracle 8.1.7 JDBC and it includes both the
    Thin JDBC and JDBC-OCI8 driver library components. For all OCI
    and type 2 JDBC drivers, see Connection Requirements for OCI and
    Type 2 JDBC Drivers.
    ------------- COPIED FROM HELP ---------------

  • Heart beat could not open connection, error code 110

    Hi, where can I find error codes for NFR and NSM?
    I have problems with some agents connecting to the engine:
    2/17/2010 16:02:55 EngineInterface: Heart beat could not open connection, error code 110
    Both engine and agent runs on the same server (10.236.19.147):
    AgentNCP Service Config
    Host Address: 10.236.19.147
    Service Ports: HTTPS: 3037 HTTP: 0
    Data Path: /var/opt/novell/filereporter/agentncp
    Debug Logging: Enabled
    Heartbeat: 60 seconds
    Engine Address: 10.239.19.147:3035
    Use SSL: Yes
    Alternate Hostname: huanovellfs1
    Engine Service Config
    Host Address: 10.236.19.147
    Service Ports
    Client HTTPS: 3033 HTTP: 0
    Agent HTTPS: 3035 HTTP: 0
    Data Path: /var/opt/novell/filereporter/engine
    Debug Logging: Enabled
    Heartbeat: 60 seconds
    DSI Address: 10.236.19.89:8009
    Use SSL: Yes
    Scans per Volume: 2
    Another OES2 server connects fine to the engine, butI have a Netware agent, which also fails to connect:
    Feb 17, 2010 4:08:11 PM SR Interface: Heart beat could not open connection.
    NFR is 1.0.0
    Thanks for any input.
    Istvan

    Hi Istvan! Sorry for the delay in our response! we are in the process
    of building a list of error codes for everyone! in the meantime the 110
    means the following:
    // Couldn't create a new network interface
    #define CC_STATUS_CCS_CANT_CREATE 110
    Is this an NSM integration installation?
    Also, remove the alternate hostname.
    If you don't mind, let's move this support issue to
    filereporter"@"novell.com!
    Thank you!
    icseke wrote:
    > Hi, where can I find error codes for NFR and NSM?
    >
    > I have problems with some agents connecting to the engine:
    >
    > 2/17/2010 16:02:55 EngineInterface: Heart beat could not open
    > connection, error code 110
    >
    > Both engine and agent runs on the same server (10.236.19.147):
    >
    >
    > AgentNCP Service Config
    > ------------------------------------------------------------------------------
    > Host Address: 10.236.19.147
    > Service Ports: HTTPS: 3037 HTTP: 0
    >
    > Data Path: /var/opt/novell/filereporter/agentncp
    > Debug Logging: Enabled
    > Heartbeat: 60 seconds
    > Engine Address: 10.239.19.147:3035
    > Use SSL: Yes
    > Alternate Hostname: huanovellfs1
    >
    > Engine Service Config
    > ------------------------------------------------------------------------------
    > Host Address: 10.236.19.147
    > Service Ports
    > Client HTTPS: 3033 HTTP: 0
    > Agent HTTPS: 3035 HTTP: 0
    >
    > Data Path: /var/opt/novell/filereporter/engine
    > Debug Logging: Enabled
    > Heartbeat: 60 seconds
    > DSI Address: 10.236.19.89:8009
    > Use SSL: Yes
    > Scans per Volume: 2
    >
    > Another OES2 server connects fine to the engine, butI have a Netware
    > agent, which also fails to connect:
    >
    > Feb 17, 2010 4:08:11 PM SR Interface: Heart beat could not open
    > connection.
    >
    > NFR is 1.0.0
    >
    > Thanks for any input.
    >
    > Istvan
    >
    >

  • Receiving oracle.jdbc.driver error when trying to connect

    Setup:
    Windows 7 64bit
    4GB ram
    SQL Developer 3.2.20.09
    Java platform 1.6.0_37
    Oracle IDE 3.2.20.09.87
    Hello, I'm going to start by saying I'm a rank amateur when it comes to using and understand SQL developer. My entire need for this program is to connect to a virt server at my office and test out my SQL queries against our tables. It's been working great for this purpose until yesterday when I received this error:
    An error was encountered performing the requested operation:
    oracle.jdbc.driver.T2CConnection.getLibraryVersionNumber()I
    Vendor code 0
    I did some searching and found a few references to this error but due to my inexperience I was unable to follow the resolutions and fix the error. This connection was working fine until yesterday afternoon which seemed odd. Based on my control panel, here is what I installed yesterday, I believe I installed both Java's after the error occurred seeing if they would alleviate the issue.
    MySQL Administrator 1.1
    Java SE Development Kit 6 Update 41 (64-bit)
    MySQL Workbench 5.2 CE
    Java 6 Update 41 (64-bit)
    Could one of these be the root of the issue?
    Thanks for the help and sorry for the lack of technical expertise, my need is very narrow and up until now this program has worked great for me.
    -Brad
    Edited by: 998110 on Apr 4, 2013 9:46 AM

    >
    Could one of these be the root of the issue?
    >
    More likely to be that you are now using the wrong version of the oracle jdbc jar file.
    Post the name and version of the JDBC jar file that you think you are using.
    Search the pc for ALL such files.
    Examine the environment variables (e.g. PATH) to see if they reference jdbc jars other than the ojdbc6 jar you should be using.

  • Connect to an Oracle database by using oracle.jdbc.OracleDriver: error

    Hi,
    I'm trying to connect to an Oracle database so we can retrieve notes of tables, views and packages.
    By using the API of Data Modeler (transformation script) we want to add these notes to corresponding objects in Data Modeler.
    I'm starting with this:
    importPackage(java.lang);
    importPackage(java.awt);
    importPackage(java.sql); 
    java.lang.Class.forName("oracle.jdbc.OracleDriver");
    An error occurs when I run this code:
    It has to be a Java thing...
    Anyone a suggestion?

    Problem solved! One of my colleagues referred to this post: Import user defined properties from Oracle Designer
    More in detail: it's about this couple of lines:
    // Copy the ojdbc6.jar file to ..\datamodeler-home\jlib directory 
    // Add this line to datamodeler.conf 
    //      AddJavaLibFile  ../../jlib/ojdbc6.jar 
    I changed my datamodeler.conf file, restarted DM and now there's no longer an error when I am trying to use the Oracle JDBC drive.

  • JDBC connection error -- unknown SID

    Hello,
    I am trying to run my first JDBC application (using the thin driver) -- the Oracle DMLSample example. But I am getting a connection error related to SID:
    "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=(PROTOCOL=tcp)(PORT=1521)(HOST=127.0.0.1))(CONNECT_DATA=(SID=dmsdm)))"
    Here is my setup:
    I have started the listener -- here is the result of "lsnctl start" command:
    Starting /usr/lib/oracle/xe/app/oracle/product/10.2.0/server/bin/tnslsnr: please wait...
    TNSLSNR for Linux: Version 10.2.0.1.0 - Production
    System parameter file is /usr/lib/oracle/xe/app/oracle/product/10.2.0/server/network/admin/listener.ora
    Log messages written to /usr/lib/oracle/xe/app/oracle/product/10.2.0/server/network/log/listener.log
    Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC_FOR_XE)))
    Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=qella.array.ca)(PORT=1521)))
    Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC_FOR_XE)))
    STATUS of the LISTENER
    Here is the listener.ora file content
    Alias LISTENER
    Version TNSLSNR for Linux: Version 10.2.0.1.0 - Production
    Start Date 25-MAY-2007 09:46:36
    Uptime 0 days 0 hr. 0 min. 0 sec
    Trace Level off
    Security ON: Local OS Authentication
    SNMP OFF
    Default Service XE
    Listener Parameter File /usr/lib/oracle/xe/app/oracle/product/10.2.0/server/network/admin/listener.ora
    Listener Log File /usr/lib/oracle/xe/app/oracle/product/10.2.0/server/network/log/listener.log
    Listening Endpoints Summary...
    (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC_FOR_XE)))
    (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=qella.array.ca)(PORT=1521)))
    Services Summary...
    Service "PLSExtProc" has 1 instance(s).
    Instance "PLSExtProc", status UNKNOWN, has 1 handler(s) for this service...
    The command completed successfully
    The application is built with JDevloper and tries to connect to the DB (located on the same Linux machine where the Oracle installed) with the following parameters:
    HostName = qella.array.ca
    SID = dmsdm
    Port = 1521
    UserName = hr
    Password = hr
    Here is the listener.ora file contents:
    # listener.ora Network Configuration File:
    SID_LIST_LISTENER =
    (SID_LIST =
    (SID_DESC =
    (SID_NAME = PLSExtProc)
    (ORACLE_HOME = /usr/lib/oracle/xe/app/oracle/product/10.2.0/server)
    (PROGRAM = extproc)
    LISTENER =
    (DESCRIPTION_LIST =
    (DESCRIPTION =
    (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC_FOR_XE))
    (ADDRESS = (PROTOCOL = TCP)(HOST = qella.array.ca)(PORT = 1521))
    DEFAULT_SERVICE_LISTENER = (XE)
    Here is the listener.ora file contents:
    # tnsnames.ora Network Configuration File:
    XE =
    (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = qella.array.ca)(PORT = 1521))
    (CONNECT_DATA =
    (SERVER = DEDICATED)
    (SERVICE_NAME = XE)
    EXTPROC_CONNECTION_DATA =
    (DESCRIPTION =
    (ADDRESS_LIST =
    (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC_FOR_XE))
    (CONNECT_DATA =
    (SID = PLSExtProc)
    (PRESENTATION = RO)
    My questions:
    1. What is wrong/missing in my setup?
    2. In case I don't remember the SID -- how can I find it?
    Thanks very much!
    Mark.

    Mark,
    You asked:
    What is wrong/missing in my setup?Possibly nothing. My guess is the problem is with your code. Excuse me, but I couldn't find that in your post.
    You also asked:
    In case I don't remember the SID -- how can I find it?In one of the data dictionary views. The Oracle documentation will tell you which one.
    (I don't remember right now.)
    Note, however, that the connection URL you use in JDBC may contain either the SID or the service name and you have posted the service name, namely:
    (SERVICE_NAME = XE)For your information I have Oracle database express edition (XE) installed on my Windows machine. The connection URL I use to connect to the sample HR schema is:
    jdbc:oracle:thin:HR/hr@//localhost:1521/XEIf you haven't already done so, I recommend reading the Oracle documentation first, in particular the JDBC User's Guide and Reference.
    Good Luck,
    Avi.

  • Oracle JDBC Connectivity

    I am trying to connect to oracle8.0.5 database from JDK1.3 on
    windows 2000 os
    my program code is as follows
    import java.sql.*;
    class JEmpt{
    public static void main (String args [])
         throws SQLException {
         try
              Class.forName("oracle.jdbc.driver.OracleDriver");
              Connection conn =
              DriverManager.getConnection
    ("jdbc:oracle:thin:@127.0.0.1:1521:ORCL","SYSTEM","MANAGER");
              Statement stmt = conn.createStatement ();
              ResultSet rset = stmt.executeQuery ("select
    ENAME from EMP");
              while (rset.next ()) {
              System.out.println (rset.getString (1));
         catch(Exception e)
              System.out.println("Exception : "+e.getMessage
    but i get the following error
    Exception in thread "main" java.sql.SQLException: Connection
    refused: no further information
    at oracle.jdbc.dbaccess.DBError.check_error<DBError.java:228>
    at
    oracle.jdbc.driver.OracleConnection.<init><OracleConnection.java:
    110>
    at oracle.jdbc.driver.OracleDriver.connect<OracleDriver.java:148>
    at java.sql.DriverManager.getConnection<Unknown Source>
    at java.sql.DriverManager.getConnection<Unknown Source>
    at Employee.main<Employee.java:23>
    your help wii be highly appreciated
    looking forward for yr reply
    lekha

    Hi lekha
    try this:
    import oracle.jdbc.driver.*;
    DriverManager.registerDriver(new OracleDriver());
    conn = DriverManager.getConnection(...)
    and ensure that your CLASSPATH can see
    classes111.zip/classes12.zip.
    Tarik

  • Oracle.jdbc.driver error using jdk1.2.2 on Win 2k

    Im trying to run a jsp page that is dependent on an oricle database. However whenever I try to connect to the database over a thin line client I always get a java.lang.ClassNotFoundException error. I've gone over the path and classpath serveral time, and can't get it to work.
    classpath =
    C:\jdk1.2.2\lib\tools.jar;C:\Program Files\Tomcat4.0\common\lib\servlet.jar;C:\ORANT\jdbc\lib\classes102.zip;
    C:\ORANT\jdbc\lib\classes111.zip;C:\jdk1.2.2\bin\java.exe;
    C:\jdk1.2.2\lib\tools.jar;C:\jdk1.2.2\lib\dt.jar;
    path =
    C:\WINNT\system32;C:\WINNT\system32;C:\jdk1.2.2\bin\java.exe;C:\ORANT\jdbc\lib;
    If anyone knows how to fix this problem Id appreciate it.

    it doesn't say, it just gives me this error message.
    javax.servlet.ServletException: oracle.jdbc.driver.OracleDriver
         at org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:463)
         at org.apache.jsp.index$jsp._jspService(index$jsp.java:105)
         at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:107)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
         at org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServlet.java:202)
         at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:382)
         at org.apache.jasper.servlet.JspServlet.service(JspServlet.java, Compiled Code)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:247)
         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:193)
         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:243)
         at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java, Compiled Code)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java, Compiled Code)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java, Compiled Code)
         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:190)
         at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java, Compiled Code)
         at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:475)
         at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java, Compiled Code)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java, Compiled Code)
         at org.apache.catalina.core.StandardContext.invoke(StandardContext.java, Compiled Code)
         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:180)
         at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java, Compiled Code)
         at org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:170)
         at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java, Compiled Code)
         at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:170)
         at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java, Compiled Code)
         at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java, Compiled Code)
         at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java, Compiled Code)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java, Compiled Code)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java, Compiled Code)
         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:174)
         at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java, Compiled Code)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java, Compiled Code)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java, Compiled Code)
         at org.apache.catalina.connector.http.HttpProcessor.process(HttpProcessor.java, Compiled Code)
         at org.apache.catalina.connector.http.HttpProcessor.run(HttpProcessor.java, Compiled Code)
         at java.lang.Thread.run(Thread.java:472)
    root cause
    java.lang.ClassNotFoundException: oracle.jdbc.driver.OracleDriver
         at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java, Compiled Code)
         at java.lang.Exception.(Exception.java, Compiled Code)
         at java.lang.ClassNotFoundException.(ClassNotFoundException.java, Compiled Code)
         at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java, Compiled Code)
         at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java, Compiled Code)
         at org.apache.jasper.servlet.JasperLoader.loadClass(JasperLoader.java, Compiled Code)
         at org.apache.jasper.servlet.JasperLoader.loadClass(JasperLoader.java, Compiled Code)
         at java.lang.ClassLoader.loadClassInternal(ClassLoader.java, Compiled Code)
         at java.lang.Class.forName0(Native Method)
         at java.lang.Class.forName(Class.java, Compiled Code)
         at org.apache.jsp.index$jsp._jspService(index$jsp.java:87)
         at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:107)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
         at org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServlet.java:202)
         at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:382)
         at org.apache.jasper.servlet.JspServlet.service(JspServlet.java, Compiled Code)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:247)
         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:193)
         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:243)
         at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java, Compiled Code)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java, Compiled Code)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java, Compiled Code)
         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:190)
         at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java, Compiled Code)
         at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:475)
         at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java, Compiled Code)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java, Compiled Code)
         at org.apache.catalina.core.StandardContext.invoke(StandardContext.java, Compiled Code)
         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:180)
         at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java, Compiled Code)
         at org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:170)
         at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java, Compiled Code)
         at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:170)
         at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java, Compiled Code)
         at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java, Compiled Code)
         at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java, Compiled Code)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java, Compiled Code)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java, Compiled Code)
         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:174)
         at org.apache.catalina.core.StandardPipeline.invokeNext(StandardPipeline.java, Compiled Code)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java, Compiled Code)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java, Compiled Code)
         at org.apache.catalina.connector.http.HttpProcessor.process(HttpProcessor.java, Compiled Code)
         at org.apache.catalina.connector.http.HttpProcessor.run(HttpProcessor.java, Compiled Code)
         at java.lang.Thread.run(Thread.java:472)

  • Enable SSL between oracle JDBC Connection in weblogic server.

    Hi ALL,
    I have an requirement to enable SSL Mechanism in weblogic JDBC Connection Pool.we are using Oracle9i Enterprise Edition Release 9.2.0.7.0 - 64bit Production and Driver as "jdbc:oracle:thin@..." / oracle.jdbc.OracleDriver.
    weblogic server 8.1 SP4
    can anybody know what are the steps / configuration has to be done for enable Oracle Advanced Security encryption on the JDBC Oracle Thin driver with a WebLogic JDBC Connection Pool.
    Thanks,
    Karthik,

    Hi,
    I changed the code as given below. Still getting the same error. Can I migrate my question to jdbc section? I am new to this forum.
    import java.sql.*;
    public class jdbc {
    public static void main(String[] args) throws ClassNotFoundException, SQLException
    Class.forName("oracle.jdbc.driver.OracleDriver");
    String url = "jdbc:oracle:thin:@localhost:1521:xe";
    Connection conn =
    DriverManager.getConnection(url,"jestin","jj");
    conn.setAutoCommit(false);
    Statement stmt = conn.createStatement();
    ResultSet rset =
    stmt.executeQuery("select BANNER from SYS.V_$VERSION");
    while (rset.next()) {
    System.out.println (rset.getString(1));
    stmt.close();
    System.out.println ("Ok.");
    jestinjoy@debian:~/java$ javac -classpath /usr/lib/java/ jdbc.java
    jestinjoy@debian:~/java$ java jdbc
    Exception in thread "main" java.lang.ClassNotFoundException: oracle.jdbc.driver.OracleDriver
         at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
         at java.security.AccessController.doPrivileged(Native Method)
         at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
         at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
         at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
         at java.lang.ClassLoader.loadClass(ClassLoader.java:248)
         at java.lang.Class.forName0(Native Method)
         at java.lang.Class.forName(Class.java:169)
         at jdbc.main(jdbc.java:7)
    same error when I give the command without classpath

  • ADF: Gracefully handling JDBC connection errors?

    Hi gang
    We've a use case to display a specific web page when the JDBC connection drops out on our ADF application, specifically the following error:
    oracle.jbo.DMLException: JBO-26061: Error while opening JDBC connection.
    I've been researching solutions to this and came up with a near solution of placing the following entry in the application's web.xml file:
    <error-page>
      <exception-type>oracle.jbo.DMLException</exception-type>
      <location>/MyErrorPage.jsp</location>
    </error-page>This works okay but is a blunt mechanism as it captures all DMLExceptions which includes insert/update/delete failures, as well as the JDBC connection drop out.
    Has anybody come up with a better solution for handling JDBC connection drop outs?
    Thanks & regards,
    CM.
    PS. (JDev 11g build 5188, ADF BC + ADF Faces RC)

    Thanks John, that's the solution. For some reason I'd forgotten that DCErrorHandlerImpl exists in the controller layer, not the model layer, so it makes perfect sense to override it and do the redirect.
    Here's what I came up with:
    @Override
    public void reportException(DCBindingContainer dCBindingContainer,
                                Exception exception) {
        try {
            String message = exception.getMessage();
            if (message.indexOf("JBO-26061") >= 0) {
                FacesContext.getCurrentInstance().getExternalContext().redirect("faces/ErrorPageJDBCFailure.jspx");
            } else
                super.reportException(dCBindingContainer, exception);
        } catch (IOException e) {
    }The following OTN post shows some other methods to do the redirect: JSF forward Vs redirect
    Cheers!
    CM.

Maybe you are looking for

  • Extracting a Deleted Item

    This is with regarding to a deleted item. I had created a PO with ten line items. The sequence of the PO line items also plays an important role in our org. Due to some sequential internal assebling parts. Unfortunately i deleated the  firstline item

  • I tried to restore my iPod touch4 but iTunes shows "This device isn't eligible for requested build" so what can I do ?

    I tried to restore my iPod touch4 but iTunes shows "This device isn't eligible for requested build" so what can I do ?

  • Edit Palette Set disabled?

    recently lost my hard drive so just reinstalled LabVIEW 8.6.1f1 and 9.0f3 now (and this is in both 8.6 and 2009) when I right click the Function palette and Control palette open on the Express; for years I have been opening to Functions to Programmin

  • InetAddress.isReachable() only returns true

    Hello, Im trying to use the InetAddress.isReachable() method to get the host reacheability, but it only returns true to all addresses, being available or not...... in sniffer all appear to be ok, i can see the icmp packets incoming and outgoing.... S

  • Old HP DesignJet printer bypasses RIP after upgrade to Leopard

    My hp DesignJet 10ps has a print driver that has been bundled in the new OS, but when I print documents they bypasses the RIP software and my color quality is poor. The hp website says the driver is included in the OS & has nothing for me to download