Pls help: Io exception: Connection refused

My application was running fine and one days i got this error
Io exception: Connection refused(DESCRIPTION=(TMP=)(VSNNUM=168821248)(ERR=12514)(ERROR_STACK=(ERROR=(CODE=12514)(EMFI=4))))
I am using a remote oracle server in my application .....the service provider is saying that every thing is ok and he didn't know wht is wrong in my schema object.....
the method of connetion is
DriverManager.registerDriver (new oracle.jdbc.driver.OracleDriver());
                         connect = DriverManager.getConnection("jdbc:oracle:thin:@//host_ip/orcl.oracle.com%","user","password");
// @machineName:port:SID, userid, password
I am struck now and i have no idea wht to do now and wht should i ask to my service provider to do.....
pls help

The error 12514 means 'TNS:listener could not resolve SERVICE_NAME given in connect descriptor'. In your connect string what is the service_name?
The format for a connect string is :
("jdbc:oracle:thin:@myhost:<PORT>:<SERVICE_NAME>","<USERNAME>", "<PASSWORD>");

Similar Messages

  • Help! - Io exception: Connection refused(DESCRIPTION...

    This has been bugging me for weeks.... I get this error only on some tables and not all of them so I am wondering if maybe it is a permissions grant thing. This web application I have allows a visitor to post information into the DB, this works fine, but the weird thing is that when they click to view the information they submitted only the information that is generated server side is displayed yet all the information the visitor submitted was entered into the table! Here is all the info I think you will need to figure this one out...
    Note that it has nothing to do with my web application I know this because as I said it works fine on some of the tables...
    Here is the exception I am getting...
    Io exception: Connection refused(DESCRIPTION=(TMP=)(VSNNUM=153093120)(ERR=12505)(ERROR_STACK=(ERROR=(CODE=12505)(EMFI=4))))
    java.sql.SQLException: Io exception: Connection refused(DESCRIPTION=(TMP=)(VSNNUM=153093120)(ERR=12505)(ERROR_STACK=(ERROR=(CODE=12505)(EMFI=4))))
    at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:134)
    at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:179)
    at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:333)
    at oracle.jdbc.driver.OracleConnection.<init>(OracleConnection.java:404)
    at oracle.jdbc.driver.OracleDriver.getConnectionInstance(OracleDriver.java:468)
    at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:314)
    at java.sql.DriverManager.getConnection(DriverManager.java:512)
    at java.sql.DriverManager.getConnection(DriverManager.java:171)
    When I run lsnrctl services this is what I get...
    [oracle@ds26 network]$ lsnrctl services
    LSNRCTL for Linux: Version 9.2.0.4.0 - Production on 17-JUL-2005 19:54:40
    Copyright (c) 1991, 2002, Oracle Corporation. All rights reserved.
    Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC)))
    Services Summary...
    Service "PLSExtProc" has 1 instance(s).
    Instance "PLSExtProc", status UNKNOWN, has 1 handler(s) for this service...
    Handler(s):
    "DEDICATED" established:0 refused:0
    LOCAL SERVER
    Service "db9i" has 2 instance(s).
    Instance "db9i", status UNKNOWN, has 1 handler(s) for this service...
    Handler(s):
    "DEDICATED" established:0 refused:0
    LOCAL SERVER
    Instance "db9i", status READY, has 2 handler(s) for this service...
    Handler(s):
    "D000" established:762 refused:0 current:73 max:1002 state:ready
    DISPATCHER
    (ADDRESS=(PROTOCOL=tcp)(HOST=203.432.54.66)(PORT=32769))
    "DEDICATED" established:0 refused:0 state:ready
    LOCAL SERVER
    The command completed successfully
    Here is my listener.ora file...
    # LISTENER.ORA Network Configuration File: /home/oracle/Oracle9i/product/9.2.0/network/admin/listener.ora
    # Generated by Oracle configuration tools.
    LISTENER =
    (DESCRIPTION_LIST =
    (DESCRIPTION =
    (ADDRESS_LIST =
    (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC))
    (ADDRESS_LIST =
    (ADDRESS = (PROTOCOL = TCP)(HOST = some.domain.net)(PORT = 1521))
    SID_LIST_LISTENER =
    (SID_LIST =
    (SID_DESC =
    (SID_NAME = PLSExtProc)
    (ORACLE_HOME = /home/oracle/Oracle9i/product/9.2.0)
    (PROGRAM = extproc)
    (SID_DESC =
    (GLOBAL_DBNAME = db9i)
    (ORACLE_HOME = /home/oracle/Oracle9i/product/9.2.0)
    (SID_NAME = db9i)
    Here is my tnsnames.ora...
    # TNSNAMES.ORA Network Configuration File: /home/oracle/Oracle9i/product/9.2.0/network/admin/tnsnames.ora
    # Generated by Oracle configuration tools.
    DB9I.432.54.66 =
    (DESCRIPTION =
    (ADDRESS_LIST =
    (ADDRESS = (PROTOCOL = TCP)(HOST = some.domain.net)(PORT = 1521))
    (CONNECT_DATA =
    (SERVICE_NAME = db9i)
    EXTPROC_CONNECTION_DATA.432.54.66 =
    (DESCRIPTION =
    (ADDRESS_LIST =
    (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC))
    (CONNECT_DATA =
    (SID = PLSExtProc)
    (PRESENTATION = RO)
    INST1_HTTP.432.54.66 =
    (DESCRIPTION =
    (ADDRESS_LIST =
    (ADDRESS = (PROTOCOL = TCP)(HOST = 127.0.0.1)(PORT = 1521))
    (CONNECT_DATA =
    (SERVER = SHARED)
    (SERVICE_NAME = MODOSE)
    (PRESENTATION = http://HRService)
    Here is the listener.log file...
    TNSLSNR for Linux: Version 9.2.0.1.0 - Production on 16-MAY-2005 23:37:18
    Copyright (c) 1991, 2002, Oracle Corporation. All rights reserved.
    System parameter file is /home/oracle/Oracle9i/product/9.2.0/network/admin/listener.ora
    Log messages written to /home/oracle/Oracle9i/product/9.2.0/network/log/listener.log
    Trace information written to /home/oracle/Oracle9i/product/9.2.0/network/trace/listener.trc
    Trace level is currently 0
    Started with pid=11876
    Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC)))
    Error listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=432.54.66.203.sfldmi01.ce.domain.net)(PORT=1521)))
    TNS-12545: Connect failed because target host or object does not exist
    TNS-12560: TNS:protocol adapter error
    TNS-00515: Connect failed because target host or object does not exist
    No longer listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC)))
    And my sqlnet.ora file...
    # SQLNET.ORA Network Configuration File: /home/oracle/Oracle9i/product/9.2.0/network/admin/sqlnet.ora
    # Generated by Oracle configuration tools.
    NAMES.DEFAULT_DOMAIN = 432.54.66
    NAMES.DIRECTORY_PATH= (TNSNAMES, ONAMES, HOSTNAME)
    Here is the output from a tnsping...
    [oracle@ds26 oracle]$ tnsping DB9I.432.54.66
    TNS Ping Utility for Linux: Version 9.2.0.4.0 - Production on 18-JUL-2005 23:24:15
    Copyright (c) 1997 Oracle Corporation. All rights reserved.
    Used parameter files:
    /home/oracle/Oracle9i/product/9.2.0/network/admin/sqlnet.ora
    Used TNSNAMES adapter to resolve the alias
    Attempting to contact (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = some.domain.net)(PORT = 1521))) (CONNECT_DATA = (SERVICE_NAME = db9i)))
    OK (10 msec)
    And I can connect fine with...
    sqlplus user/[email protected]

    Posting the meaning of the error is always helpful;
    12505, 00000, "TNS:listener could not resolve SID given in connect descriptor"
    // *Cause:  The SID in the CONNECT_DATA was not found in the listener's tables.
    // *Action: Check to make sure that the SID specified is correct.
    // The SIDs that are currently registered with the listener can be obtained by
    // typing "LSNRCTL SERVICES <listener name>". These SIDs correspond to
    // SID_NAMEs in TNSNAMES.ORA, or db_names in INIT.ORA.
    // *Comment: This error will be returned if the database instance has not
    // registered with the listener; the instance may need to be started.
    And, a most peculiar hostname you have: 432.54.66.203.sfldmi01.ce.domain.net
    I suggest you change that to sfldmi01.ce.domain.net, and also change the names.default domain in sqlnet.ora to ce.domain.net.
    Also, check if your IP-address is indeed 203.432.54.66.
    Then, change tnsnames.ora, and let your entries end with the same ce.domain.net, not the numeric notitation.
    And you are not getting this on some tables, but on some connections, because you close and open your connecions - hence the use of MTS (which listens on address 203.432.54.66), probably. So you might readup on MTS, and make up your mind: now your using both MTS and dedicated (the latter configured in listener.ora, the former in the instance)

  • HELP! - Io exception: Connection refused(DESCRIPTION=(TMP=)(...

    Can anyone help me figure out this exception?
    TIA!
    Io exception: Connection refused(DESCRIPTION=(TMP=)(VSNNUM=153093120)(ERR=12505)(ERROR_STACK=(ERROR=(CODE=12505)(EMFI=4))))
    java.sql.SQLException: Io exception: Connection refused(DESCRIPTION=(TMP=)(VSNNUM=153093120)(ERR=12505)(ERROR_STACK=(ERROR=(CODE=12505)(EMFI=4))))
         at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:134)
         at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:179)
         at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:333)
         at oracle.jdbc.driver.OracleConnection.<init>(OracleConnection.java:404)
         at oracle.jdbc.driver.OracleDriver.getConnectionInstance(OracleDriver.java:468)
         at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:314)
         at java.sql.DriverManager.getConnection(DriverManager.java:512)
         at java.sql.DriverManager.getConnection(DriverManager.java:171)
         at org.apache.jsp.view_jsp._jspService(view_jsp.java:77)
         at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:137)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
         at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:210)
         at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:295)
         at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241)
         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:256)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
         at org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2415)
         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:180)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
         at org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:171)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641)
         at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:172)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641)
         at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:509)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:174)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
         at org.apache.coyote.tomcat4.CoyoteAdapter.service(CoyoteAdapter.java:223)
         at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:261)
         at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:360)
         at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:604)
         at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:562)
         at org.apache.jk.common.SocketConnection.runIt(ChannelSocket.java:679)
         at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:619)
         at java.lang.Thread.run(Thread.java:534)

    When I run lsnrctl services this is what I get...
    [oracle@ds26 network]$ lsnrctl services
    LSNRCTL for Linux: Version 9.2.0.4.0 - Production on 17-JUL-2005 19:54:40
    Copyright (c) 1991, 2002, Oracle Corporation. All rights reserved.
    Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC)))
    Services Summary...
    Service "PLSExtProc" has 1 instance(s).
    Instance "PLSExtProc", status UNKNOWN, has 1 handler(s) for this service...
    Handler(s):
    "DEDICATED" established:0 refused:0
    LOCAL SERVER
    Service "db9i" has 2 instance(s).
    Instance "db9i", status UNKNOWN, has 1 handler(s) for this service...
    Handler(s):
    "DEDICATED" established:0 refused:0
    LOCAL SERVER
    Instance "db9i", status READY, has 2 handler(s) for this service...
    Handler(s):
    "D000" established:762 refused:0 current:73 max:1002 state:ready
    DISPATCHER <machine: some.domain.net, pid: 1903>
    (ADDRESS=(PROTOCOL=tcp)(HOST=203.432.54.66)(PORT=32769))
    "DEDICATED" established:0 refused:0 state:ready
    LOCAL SERVER
    The command completed successfully
    [oracle@ds26 network]$

  • Io exception: Connection refused

    I have a main process flow that incorporates a number of sub-process flows to perform a complete warehouse load. Whenever I execute this process flow, it fails with the error shown below. It fails at a different subprocess each time I run it, and when I execute just that subprocess by itself, the subprocess completes successfully. I have no idea what causes this error or how to prevent it from re-occuring:
    RPE-02083: Process ITM_LOAD has errored Activities. Dependent objects may not have been deployed. You can use Oracle Workflow Monitor to retry the activities or abort the Process.
    RPE-02018: Oracle Workflow schema OWF_MGR on host <hostname> cannot be accessed using service <database name> through port 1521. Please check the location details and try again.
    Io exception: Connection refused(DESCRIPTION=(TMP=)(VSNNUM=153092352)(ERR=12516)(ERROR_STACK=(ERROR=(CODE=12516)(EMFI=4))))
    I would really appreciate any help on this!!

    Julie,
    Can you check the location registration for all locations? It looks like you hit TNS-12516:
    TNS-12516 TNS:listener could not find available handler with matching protocol stack
    Cause: None of the known and available service handlers for the given SERVICE_NAME support the client's protocol stack: transport, session, and presentation protocols.
    Action: Check to make sure that the service handlers (for example, dispatchers) for the given SERVICE_NAME are registered with the listener, are accepting connections, and that they are properly configured to support the desired protocols.
    Mark.

  • Java.sql.SQLException: Io exception: Connection Refused

    Hi,
    Got struck in this since yesterday. I am trying to connect to an Oracle server and the code is pretty much simple and am reproducing the relevant portion here.
    Class.forName("oracle.jdbc.driver.OracleDriver");
    Connection conn = null;
    try {
    conn = DriverManager.getConnection("jdbc:oracle:thin:@host_IP:1521:****","****","****");
    } catch(Exception e) { System.out.println(e); }
    conn.setAutoCommit(true);
    Statement s = conn.createStatement();
    ResultSet rs;
    It gives me the following exception.
    >>
    java.sql.SQLException: Io exception: Connection refused(DESCRIPTION=(TMP=)(VSNNUM=135294976)(ERR=12500)(ERROR_STACK=(ERROR=(CODE=12500)(EMFI=4))(ERROR=(CODE=12560)(EMFI=4))(ERROR=(CODE=530)(EMFI=4))(ERROR=(BUF='32-bit Windows Error: 2: No such file or directory'))))
    Exception in thread "main" java.lang.NullPointerException
    at Test.main(Test.java:17)
    <<
    The line 17 is actually the statement,
    conn.setAutoCommit(true);
    Any help is highly appreciated.
    Thanks,
    Baskaran

    Hi Baskaran
    Actually i had the same problem which you are currently facing.
    Iam on unix box and when i tried to connect to DB for the first time using the same code piece which you wrote i got the same error and after breaking my head i came to know that the Oracle_SID i gave is incorrect
    Please check these entries in your code
    conn = DriverManager.getConnection("jdbc:oracle:thin:@host_IP:1521:*DBUsername,DBPassword,Oracle_SID*);
    To know oracle SID on unix box type this command
    $ ps -ef|grep -i smon
    oracle 740 1 0 ������� ? 1:27 ora_smon_support
    oracle 29685 29681 0 17:24:47 pts/12 0:00 grep -i smon
    $ echo $ORACLE_SID
    support
    $
    On windows box logon to the Oracle Box (i.e., on which oracle is installed) and open the regedit and search for ORACLE_SID.
    Also make sure you give the correct oracleIPAddress, dbusername, dbpassword.
    Hope it will work fine.
    Regards,
    Imas

  • Io exception: Connection refused Error

    I am trying to configure a connection pool on Weblogic 8.1 using Oracle thin client.
    When I click on the Test Driver configuration, I get the following error:
    Io exception: Connection refused(DESCRIPTION=(TMP=)(VSNNUM=153092352)(ERR=12505)(ERROR_STACK=(ERROR=(CODE=12505)(EMFI=4))))
    I have verified that the username/url are correct.
    Any ideas?

    Sreeram wrote:
    I am not sure how to run utils.dbping.Try this:
    C:\> java utils.dbping
    It will print out a usage message.
    Anyway, I am able to connect to the database using SQLPlus. I have the following
    entry in my tnsnames ora:
    dbalias.world=
    (DESCRIPTION =
    (ADDRESS_LIST =
    (ADDRESS = (PROTOCOL = TCP)(HOST = server.xx.com)(PORT = 1521))
    (CONNECT_DATA =
    (service_name = dbname)
    )Ok, and how did you define the pool? What were the properties and URL?
    Did your URL contain 'dbname' as the SID, or did you set the SID in the properties?
    show me the pool definition and show me how you start SQL-PLUS.
    Joe
    Thanks!
    Joe Weinstein <[email protected]> wrote:
    Sreeram wrote:
    I am trying to configure a connection pool on Weblogic 8.1 using Oraclethin client.
    When I click on the Test Driver configuration, I get the followingerror:
    Io exception: Connection refused(DESCRIPTION=(TMP=)(VSNNUM=153092352)(ERR=12505)(ERROR_STACK=(ERROR=(CODE=12505)(EMFI=4))))
    I have verified that the username/url are correct.The SID is probably wrong. What does utils.dbping show?
    Joe
    Any ideas?

  • Helppp meeee!!! Io exception: Connection refused..

    I'm trying to connect to an Oracle 8i (version 8.1.6.0.0) DB through a lan using an applet running on a Win NT 4 system. I also use jdk1.3.1. The code that i'm using is the following:
    import java.sql.*;
    public class ConnectionToDB {
    private Connection con;
    final private oracle.jdbc.driver.OracleDriver driver;
    public ConnectionToDB() {
    driver = new oracle.jdbc.driver.OracleDriver();
    try{
    DriverManager.registerDriver(driver);
    catch(SQLException _) {
    System.err.println(_.getMessage());
    System.exit(-1);
    try {
    con = DriverManager.getConnection("jdbc:oracle:thin:@myhost:1521:orcl","scott", "tiger");
    con.setAutoCommit(true);
    catch (SQLException _){
    System.err.println(_.getMessage());
    System.err.println("NOT CONNECTED TO THE DB.");
    try {
    Statement stmt = con.createStatement();
    ResultSet rs = stmt.executeQuery("SELECT COL1 FROM TABLE ");
    while (rs.next()){
    System.out.println(rs.getString(1));
    con.close();
    catch (SQLException _) {
    System.err.println(_.getMessage());
    The Error that i get is:
    Io exception: Connection refused(DESCRIPTION=(TMP=)(VSNNUM=135290880)(ERR=12500)(ERROR_STACK=(ERROR=(CODE=12500)(EMFI=4))(ERROR=(CODE=12560)(EMFI=4))(ERROR=(CODE=530)(EMFI=4))(ERROR=(BUF='32-bit Windows Error: 2: No such file or directory'))))
    NOT CONNECTED TO THE DB.
    Can anyone give me a hint please??
    Thanks.

    I'm trying to connect to an Oracle 8i (version
    8.1.6.0.0) DB through a lan using an applet running on
    a Win NT 4 system. I also use jdk1.3.1. The code that
    i'm using is the following:
    import java.sql.*;
    public class ConnectionToDB {
    private Connection con;
    final private oracle.jdbc.driver.OracleDriver
    ver driver;
    public ConnectionToDB() {
    driver = new oracle.jdbc.driver.OracleDriver();
    try{
    DriverManager.registerDriver(driver);
    catch(SQLException _) {
    System.err.println(_.getMessage());
    System.exit(-1);
    try {
    con =
    con =
    =
    DriverManager.getConnection("jdbc:oracle:thin:@myhost:1
    21:orcl","scott", "tiger");
    con.setAutoCommit(true);
    catch (SQLException _){
    System.err.println(_.getMessage());
    System.err.println("NOT CONNECTED TO THE
    TO THE DB.");
    try {
    Statement stmt = con.createStatement();
    ResultSet rs = stmt.executeQuery("SELECT COL1
    CT COL1 FROM TABLE ");
    while (rs.next()){
    System.out.println(rs.getString(1));
    con.close();
    catch (SQLException _) {
    System.err.println(_.getMessage());
    }The Error that i get is:
    Io exception: Connection
    refused(DESCRIPTION=(TMP=)(VSNNUM=135290880)(ERR=12500)
    ERROR_STACK=(ERROR=(CODE=12500)(EMFI=4))(ERROR=(CODE=12
    60)(EMFI=4))(ERROR=(CODE=530)(EMFI=4))(ERROR=(BUF='32-b
    t Windows Error: 2: No such file or directory'))))
    NOT CONNECTED TO THE DB.
    Can anyone give me a hint please??
    Thanks.

  • Socket Listener  - Exception (Connection refused, reset)

    Dear All,
    We are developing a Socket Listener for an application. when we try to check the performance the below errors came.
    Code
    public static void main(String[] args) {
              ServerSocket ss = null;
              Socket s = null;
              try {
                   ss = new ServerSocket(Integer.parseInt(property
                             .getProperty("SERVER_PORT")), 1500 );
                   while ((s = ss.accept()) != null) {
                        Thread current = new Thread(new ServerSocketListener(s));
                        current.setDaemon(true);
                        // start the user's thread
                        current.start();
              } catch (Exception exp) {
                   exp.printStackTrace();
    Exception 1
    java.net.ConnectException: Connection refused: connect     
         at java.net.PlainSocketImpl.socketConnect(Native Method)
         at java.net.PlainSocketImpl.doConnect(Unknown Source)
         at java.net.PlainSocketImpl.connectToAddress(Unknown Source)
         at java.net.PlainSocketImpl.connect(Unknown Source)
         at java.net.SocksSocketImpl.connect(Unknown Source)
         at java.net.Socket.connect(Unknown Source)
         at java.net.Socket.connect(Unknown Source)
         at java.net.Socket.<init>(Unknown Source)
         at java.net.Socket.<init>(Unknown Source)
         at srm.ServerSocketListener.run(ServerSocketListener.java:143)
         at java.lang.Thread.run(Unknown Source)
    Exception 2
    java.net.SocketException: Connection reset
    Test
    Invoking the Socket Server Listener with 1500 client (Java and .NET) requests.
    Then the above exceptions occurred.
    Help me
    1) Maximum client a port can supports?
    2) Is there any code or property change required?
    3) any other way

                        Thread current = new Thread(new ServerSocketListener(s));
    java.net.ConnectException: Connection refused: connect     Nothing is listening at the host:port you are trying to connect a new socket to.
         at srm.ServerSocketListener.run(ServerSocketListener.java:143)You are trying to create a new Socket inside the ServerSocketListener. Why? You already have a connected socket.
    java.net.SocketException: Connection resetStack trace please. This usually means you have written to a connection that has already been closed by the other end, but there are other possibilities.
    1) Maximum client a port can supports?Please restate your question in standard english.
    2) Is there any code or property change required?Required for what?
    3) any other wayAny other way to do what?

  • Pls help for Exception "Too Few Parameters : Expected 35"

    Hi,
    I am expericing with the exception
    "Too Few Parameters : Expected 35".
    What's wrong with it? The following is my code.
    try {                                                                                                                                                                                                                
    String DRIVER = ("sun.jdbc.odbc.JdbcOdbcDriver");               
    String URL = "jdbc:odbc:Industrial_One_DSN";
    String sql = "UPDATE BusinessRegistration " +
    "SET [Date] = ?, ISIC = ?, BizName = ?, BizAddress = ?, " +
    "OwnerName = ?, OwnerNRC = ?, Investment = ?, EstablishedYear = ?, " +
    "L_Male = ?, L_Female = ?, F_Male = ?, F_Female = ?, " +
    "OwnershipType = ?, Remarks = ?, IndustialZoneName = ?, Unit = ?, " +
    "Fuel = ?, FactoryType = ?, FactoryName = ?, Township = ? " +
    "MainProductName = ?, MainProductCountType = ?, " +
    "MainProductQuantity = ?, MainProductValue = ?, RMName = ?, " +
    "RMCountType = ?, RMQuantity = ?, RMValue = ?, EnergyName = ?, " +
    "MachinePower = ?, AmountGallon = ?, StateDiv = ?, BizSize = ?  " +
    "WHERE RegistrationID = ?";
    Class.forName(DRIVER);
    Connection con = DriverManager.getConnection(URL);
    PreparedStatement pstmt = con.prepareStatement(sql);
    int ilmale = Integer.parseInt(lmale);
    int ilfemale = Integer.parseInt(lfemale);
    int ifmale = Integer.parseInt(fmale);
    int iffemale = Integer.parseInt(ffemale);
    int impq = Integer.parseInt(mpq);
    int impv = Integer.parseInt(mpv);
    int irmq = Integer.parseInt(rmq);
    int irmv = Integer.parseInt(rmv);
    int iamountgallon = Integer.parseInt(amountgallon);
    pstmt.setString(1, date);
    pstmt.setString(2, isic);
    pstmt.setString(3, bizname);
    pstmt.setString(4, bizaddress);
    pstmt.setString(5, ownername);
    pstmt.setString(6, ownernrc);
    pstmt.setString(7, investment);
    pstmt.setString(8, eyear);
    pstmt.setInt(9, ilmale);
    pstmt.setInt(10, ilfemale);
    pstmt.setInt(11, ifmale);
    pstmt.setInt(12, iffemale);
    pstmt.setString(13, ownershiptype);
    pstmt.setString(14, remark);
    pstmt.setString(15, izn);
    pstmt.setString(16, unit);
    pstmt.setString(17, fuel);
    pstmt.setString(18, ft);
    pstmt.setString(19, fname);
    pstmt.setString(20, township);
    pstmt.setString(21, mpn);
    pstmt.setString(22, mpct);
    pstmt.setInt(23, impq);               
    pstmt.setInt(24, impv);
    pstmt.setString(25, rmname);
    pstmt.setString(26, rmct);
    pstmt.setInt(27, irmq);
    pstmt.setInt(28, irmv);
    pstmt.setString(29, ename);
    pstmt.setString(30, mpower);
    pstmt.setInt(31, iamountgallon);
    pstmt.setString(32, statediv);
    pstmt.setString(33, bizsize);
    pstmt.setInt(34, Integer.parseInt(rid));
    pstmt.executeUpdate();
    }I have got 35 fields in my db. But I wanna edit 34 fields only. I have no primary key in my table. Is't alright?
    pls help me.
    With thanks,
    WTDAHL

    I presume you are using SQL server, hence the [Date] in your SQL?
    I counted 34 question marks in your SQL statement, And 34 parameters supplied.
    Looks ok to me.
    You say you have no primary key? What is RegistrationId then?
    My suggestion for debugging: start smaller.
    Try updating it with only 5 fields, then 10 then 15 and build it up like that.
    Trying to debug 35 fields is a nightmare - you have to break it down to solve it.
    Good luck,
    evnafets

  • SQL Exception: Connection refused

    Hi,
    If have a serious problem connecting to an Oracle Database.
    From time to time I get following exception when I try to get a
    Connection:
    java.sql.SQLException: Connection
    refused(DESCRIPTION=(TMP=)(VSNNUM=134238208)(ERR=12500)(ERROR_STA
    CK=(ERROR=(CODE=12500)(EMFI=4))(ERROR=(CODE=12560)(EMFI=4))(ERROR
    =(CODE=530)(EMFI=4))(ERROR=(BUF=''))))
    at
    oracle.jdbc.dbaccess.DBError.check_error(DBError.java:406)
    at
    oracle.jdbc.driver.OracleConnection.<init>(OracleConnection.java:
    169)
    at
    oracle.jdbc.driver.OracleDriver.getConnectionInstance(OracleDrive
    r.java:231)
    at
    oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:208)
    at java.sql.DriverManager.getConnection(Unknown Source)
    at java.sql.DriverManager.getConnection(Unknown Source)
    Sometimes connecting works without any problems.
    I am using Oracle 8.0.5 on NT4SP5, JDK 1.2.2 and JDBC Thin Driver
    8.1.6 SDK.
    Someone out there who knows a solution for this problem?
    regards, PG
    null

    Hi,
    From my point of view, the error is on the server side not on
    the client side.
    Error 12500 : TNS:listener failed to start a dedicated server
    process
    Error 12560 : TNS:protocol adapter error.
    Both messages are related to a problem on the listener process
    of the server. Take a look to the listener log file on the
    server and check that other type of client (SQL+ for example)
    may connect properly. You surely have the same error with all
    network connections.
    Hope this can help.
    pg (guest) wrote:
    : Hi,
    : If have a serious problem connecting to an Oracle Database.
    : From time to time I get following exception when I try to get
    a
    : Connection:
    : java.sql.SQLException: Connection
    : refused(DESCRIPTION=(TMP=)(VSNNUM=134238208)(ERR=12500)
    (ERROR_STA
    : CK=(ERROR=(CODE=12500)(EMFI=4))(ERROR=(CODE=12560)(EMFI=4))
    (ERROR
    : =(CODE=530)(EMFI=4))(ERROR=(BUF=''))))
    : at
    : oracle.jdbc.dbaccess.DBError.check_error(DBError.java:406)
    : at
    : oracle.jdbc.driver.OracleConnection.<init>
    (OracleConnection.java:
    : 169)
    : at
    : oracle.jdbc.driver.OracleDriver.getConnectionInstance
    (OracleDrive
    : r.java:231)
    : at
    : oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:208)
    : at java.sql.DriverManager.getConnection(Unknown Source)
    : at java.sql.DriverManager.getConnection(Unknown Source)
    : Sometimes connecting works without any problems.
    : I am using Oracle 8.0.5 on NT4SP5, JDK 1.2.2 and JDBC Thin
    Driver
    : 8.1.6 SDK.
    : Someone out there who knows a solution for this problem?
    : regards, PG
    null

  • SOAP Exception, Connection refused error in jdeveloper 11g

    Hello,
    I am using jdeveloper 11g 11.1.2.3.0.
    I have been experiencing the following error everytime I try to run the applicaiton. I use webservices in my applicaiton and recently the webservices url were changed pointing now to dev instead of the lab environment. The code has been migrated to dev environment, I tested the webservices in my browser, they seem to be working fine and are pulling up the required data.
    ERROR:
    javax.xml.soap.SOAPException: Message send failed: Connection refused: connect
    Error     
    Message send failed: Connection refused: connect
    Error     
    Connection refused: connect
    I am not sure what is causing this. Any help would be appreciated.
    Thanks in advance,
    Sal

    Hello Frank,
    Thanks for your response. I checked the browser proxy settings in Jdeveloper, nothing is set there right now. Use HTTP Proxy Server is unchecked. What do I need to set this to?
    Thanks,
    Sal

  • Add User/ Communication Exception: Connection refused!

    Hello,
    I've searched the entire forum , for sample code for adding a user to the Active directory.However, the code that I use , refuses to budge past this line, and gives a
    *Problem creating object: javax.naming.CommunicationException: mydc.antipodes.com:389 [Root exception is java.net.UnknownHostException: mydc.antipodes.com]*
    // Create the initial directory context
    LdapContext ctx = new InitialLdapContext(env,null);
    When i change the ldap url to 'ldap://localhost:389', it gives me this exception
    *Problem creating object: javax.naming.CommunicationException: localhost:389 [Root exception is java.net.ConnectException: Connection refused: connect]*
    I also could not follow , how the LDAP url is formed, and those CN=,DC= attributes.I also typed in the LDAP url in the browser, and an External Protocol request popped up , that had a search for people names and email.
    Can someone please enlighten me , on where i was going wrong.I'm working on a windows XP machine with JDK1.6 with Netbeans.
    The same functionality is also done , in .NET using the activeds.tlb file and it is working fine.Is there a way in Java, where i can added a reference/COM component , in the same way as above , and add users?
    import java.util.Hashtable;
    import javax.naming.ldap.*;*
    *import javax.naming.directory.*;
    import javax.naming.*;*
    *import javax.net.ssl.*;
    import java.io.*;
    public class NewUser
         public static void main (String--] args)--
    --          Hashtable env = new Hashtable();--
    --          String adminName = "CN=Administrator,CN=jomy,CN=Users,DC=antipodes,DC=com";--
    --          String adminPassword = "jj2007";--
    --          String userName = "CN=Albert Einstein,CN=jomy,OU=Research,DC=antipodes,DC=com";--
    --          String groupName = "CN=All Research,CN=Administrators,OU=Research,DC=antipodes,DC=com";--
    --          env.put(Context.INITIAL_CONTEXT_FACTORY,"com.sun.jndi.ldap.LdapCtxFactory");--
    --          //set security credentials, note using simple cleartext authentication--
    --          env.put(Context.SECURITY_AUTHENTICATION,"simple");--
    --          env.put(Context.SECURITY_PRINCIPAL,adminName);--
    --          env.put(Context.SECURITY_CREDENTIALS,adminPassword);--
    --          //connect to my domain controller--
    --          env.put(Context.PROVIDER_URL, "ldap://mydc.antipodes.com:389");--
    --                //env.put(Context.PROVIDER_URL, "winnt://localhost");--
    --          try {--
    --               // Create the initial directory context--
    --               LdapContext ctx = new InitialLdapContext(env,null);--
    --               // Create attributes to be associated with the new user--
    --                   Attributes attrs = new BasicAttributes(true);--
    --               //These are the mandatory attributes for a user object--
    --               //Note that Win2K3 will automagically create a random--
    --               //samAccountName if it is not present. (Win2K does not)--
    --               attrs.put("objectClass","user");--
    --                   attrs.put("samAccountName","AlbertE");--
    --               attrs.put("cn","Albert Einstein");--
    --               //These are some optional (but useful) attributes--
    --               attrs.put("giveName","Albert");--
    --               attrs.put("sn","Einstein");--
    --               attrs.put("displayName","Albert Einstein");--
    --               attrs.put("description","Research Scientist");--
    --                   attrs.put("userPrincipalName","[email protected]");--
    --                   attrs.put("mail","[email protected]");--
    --               attrs.put("telephoneNumber","999 123 4567");--
    --               //some useful constants from lmaccess.h--
    --               int UF_ACCOUNTDISABLE = 0x0002;--
    --               int UF_PASSWD_NOTREQD = 0x0020;--
    --               int UF_PASSWD_CANT_CHANGE = 0x0040;--
    --               int UF_NORMAL_ACCOUNT = 0x0200;--
    --               int UF_DONT_EXPIRE_PASSWD = 0x10000;--
    --               int UF_PASSWORD_EXPIRED = 0x800000;--
    --               //Note that you need to create the user object before you can--
    --               //set the password. Therefore as the user is created with no--
    --               //password, user AccountControl must be set to the following--
    --               //otherwise the Win2K3 password filter will return error 53--
    --               //unwilling to perform.--
    --                   attrs.put("userAccountControl",Integer.toString(UF_NORMAL_ACCOUNT + UF_PASSWD_NOTREQD + UF_PASSWORD_EXPIRED+ UF_ACCOUNTDISABLE));--
    --               // Create the context--
    --               Context result = ctx.createSubcontext(userName, attrs);--
    --               System.out.println("Created disabled account for: " + userName);--
    --               //now that we've created the user object, we can set the--
    --               //password and change the userAccountControl--
    --               //and because password can only be set using SSL/TLS--
    --               //lets use StartTLS--
    --               StartTlsResponse tls = (StartTlsResponse)ctx.extendedOperation(new StartTlsRequest());--
    --               tls.negotiate();--
    --               //set password is a ldap modfy operation--
    --               //and we'll update the userAccountControl--
    --               //enabling the acount and force the user to update ther password--
    --               //the first time they login--
    --               ModificationItem[-- mods = new ModificationItem[2];
                   //Replace the "unicdodePwd" attribute with a new value
                   //Password must be both Unicode and a quoted string
                   String newQuotedPassword = "\"Password2000\"";
                   byte[] newUnicodePassword = newQuotedPassword.getBytes("UTF-16LE");
                   mods[0] = new ModificationItem(DirContext.REPLACE_ATTRIBUTE, new BasicAttribute("unicodePwd", newUnicodePassword));
                   mods[1] = new ModificationItem(DirContext.REPLACE_ATTRIBUTE, new BasicAttribute("userAccountControl",Integer.toString(UF_NORMAL_ACCOUNT + UF_PASSWORD_EXPIRED)));
                   // Perform the update
                   ctx.modifyAttributes(userName, mods);
                   System.out.println("Set password & updated userccountControl");
                   //now add the user to a group.
                        try     {
                             ModificationItem member[] = new ModificationItem[1];
                             member[0]= new ModificationItem(DirContext.ADD_ATTRIBUTE, new BasicAttribute("member", userName));
                             ctx.modifyAttributes(groupName,member);
                             System.out.println("Added user to group: " + groupName);
                        catch (NamingException e) {
                              System.err.println("Problem adding user to group: " + e);
                   //Could have put tls.close()  prior to the group modification
                   //but it seems to screw up the connection  or context ?
                   tls.close();
                   ctx.close();
                   System.out.println("Successfully created User: " + userName);
              catch (NamingException e) {
                   System.err.println("Problem creating object: " + e);
              catch (IOException e) {
                   System.err.println("Problem creating object: " + e);               }
    }

    Sometimes there are posts that are so funny, that I really do fall off my chair and writhe on the floor laughing hysterically.
    mydc.antipodes.com is my domain controller, it's most certainly not yours !
    If you are running Active Directory (although I somehow seem to think that you are not), the LDAP URL will contain the fully qualified DNS name of your domain controller and the distingushed name of your Active Directory domain (or part thereof).
    Because you are most certainly do not have access to my domain, nor would my domain controller be registered with your DNS server or listed in your hosts file, that explains why you receive the Unknown Host Exception.
    Now the reason why I think you aren't runnning Active Directory is that you say you are running on Windows XP and when you use ADSI (winnt://localhost) it all works.
    The ADSI provider WINNT, uses the Windows NT/LM API's which are used to access either the local Windows account store which is sometimes referred to as Security Accounts Manager (SAM), or a Windows NT 4 domain. (Actually it could be used to access Active Directory, albeit using the NT/LM API's rather than LDAP). The JNDI LDAP provider supports the LDAP protocol, it does not support NT/LM.
    If on the other hand I'm wrong, and you do have Active Directory present in your network, either ask the admin for the DNS name of the domain controller,and the distinguished name of your domain, look up the LDAP Resource Records (RR's) in your DNS, or use the Windows LDP.EXE tool, leave everything blank, hit the connect button and look at the Root DSE for the naming contexts and dns host name values.

  • Pls Help! Cant connect to LDAP Microsoft AD Server from Unix, error

    Hello,
    Does anybody encounter error configuring BOE X2 - CE10 - from Solaris to connect  Microsoft AD LDAP.  The error message is below.  I confirmed credentials are correct as we used the same params to connect using WebSphere and Windows. It always prompt error
    "secLdap plugin failed "
    [Thu Aug  7 09:34:40 2008]      15613   37      trace message: CInfoStore::Commit SI_info_abuse details: OCA_Abuse exception 1
    0505 at [exceptionmapper.cpp : 77]  49412 {,
    , secLDAP}
            ...The secLdap plugin failed to verify the server administration credentials. Plugin error: SecLdap Error: invalid par
    ameters in ExtractParasFromParasSeq().
    Thanks,
    Roberto

    Roberto,
    BO XI R2 actually does not require ADAM.See this thread: [Windows AD configuration with Linux;.
    The short answer is that the secLDAP plugin can connect directly to AD. This probably has a certain patch level requirement (you'll have to verify this with Tech Support).
    How are you specifying your LDAP Server Administration Credentials ? i.e. what format? I presume you're using the CN=Business Objects User,CN=Users,DC=xxx,DC=net format.
    I get the error you have if I specify the credentials as DomainUser (xxxxBoUser).
    I have been trying to configure AD with Linux (RHEL) using the the secLDAP plugin (thus far, unsuccessfully).Please note that I am however on XI3.0. Also note that I still do not have this working (I get a different error).
    In any case. it would probably be best to open a ticket with BO regarding this.
    Srinivas

  • Pls Help Out: Exception Details: CrystalDecisions.CrystalReports.Engine.LogOnException: Logon failed.

    Post Author: olabisi
    CA Forum: .NET
    Hello All,
    i am working on a project and try to come up with a report using crystal report that is embedded with vs 2003.net and the following error was generated.
    this is the error in detail:
    Server Error in '/BISI' Application.
    Logon failed.
    Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: CrystalDecisions.CrystalReports.Engine.LogOnException: Logon failed.Source Error:
    An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below. Stack Trace:
    &#91;LogOnException: Logon failed.&#93;
        . I(String   , EngineExceptionErrorID   )
        . D(Int16   , Int32   )
        . C(Int16   )
       CrystalDecisions.CrystalReports.Engine.FormatEngine.GetLastPageNumber(ReportPageRequestContext reqContext)
       CrystalDecisions.ReportSource.LocalReportSourceBase.GetLastPageNumber(ReportPageRequestContext reqContext)
       CrystalDecisions.Web.ReportAgent.get_LastPageNumber()
       CrystalDecisions.Web.ReportAgent.u(Boolean  n)
       CrystalDecisions.Web.CrystalReportViewer.OnPreRender(EventArgs e)
       System.Web.UI.Control.PreRenderRecursiveInternal()
       System.Web.UI.Control.PreRenderRecursiveInternal()
       System.Web.UI.Control.PreRenderRecursiveInternal()
       System.Web.UI.Page.ProcessRequestMain()
    Version Information: Microsoft .NET Framework Version:1.1.4322.573; ASP.NET Version:1.1.4322.573
    Note: this report has a main report that have three subreport in it. It was working fine until i added the third sub report to the main form.I will be glad if a solution could come up fast. This is  my email : [email protected] or [email protected]
    Jacobs

    Post Author: mewdied
    CA Forum: .NET
    You need to make sure that you are passing the database logon code to the third sub-report correctly.  If you are currently only passing database logon to the main report, it may be that the other two subreports are using the same connection as the main, but the third one is using something different.

  • Help! Network Connection Refused hooking to Itunes store

    I have never had this issue before...
    Everything else is working fine, I have a trip to colombia tomorrow and wanted some movies, but Itunes store is not working....
    Here is what I get when I run diagnostics
    Microsoft Windows XP Professional Service Pack 2 (Build 2600)
    Sony Corporation VGN-T350P
    iTunes 7.1.1.5
    Current user is an administrator.
    Network Adapter Information
    Adapter Name: {64E43FE8-4E86-4C10-9841-9F1DECF4C645}
    Description: Intel(R) PRO/Wireless 2200BG Network Connection - Packet Scheduler Miniport
    IP Address: 192.168.3.107
    Subnet Mask: 255.255.255.0
    Default Gateway: 192.168.3.1
    DHCP Enabled: Yes
    DHCP Server: 192.168.3.1
    Lease Obtained: Wed Apr 04 15:39:22 2007
    Lease Expires: Thu Apr 05 15:39:22 2007
    DNS Servers: 192.168.1.254
    Adapter Name: {D2464F5E-C19F-48A0-9063-A739F1116295}
    Description: Intel(R) PRO/100 VE Network Connection - Packet Scheduler Miniport
    IP Address: 0.0.0.0
    Subnet Mask: 0.0.0.0
    Default Gateway:
    DHCP Enabled: Yes
    DHCP Server: 192.168.15.1
    Lease Obtained: Sat Mar 17 11:52:50 2007
    Lease Expires: Sat Mar 17 12:52:50 2007
    DNS Servers:
    Adapter Name: {B5C036D0-A380-4892-A3FC-27035658C63B}
    Description: Bluetooth Device (Personal Area Network)
    IP Address: 0.0.0.0
    Subnet Mask: 0.0.0.0
    Default Gateway:
    DHCP Enabled: Yes
    DHCP Server:
    Lease Obtained: Sat Mar 17 12:52:50 2007
    Lease Expires: Sat Mar 17 12:52:50 2007
    DNS Servers:
    Network Connection Information
    Active Connection: LAN Connection
    Connected: Yes
    Online: Yes
    Using Modem: No
    Using LAN: Yes
    Using Proxy: No
    SSL 3.0 Support: Enabled
    TLS 1.0 Support: Enabled
    Firewall Information
    Windows Firewall is off.
    Connection attempt to Apple web site was unsuccessful.
    The network connection was refused.
    Connection attempt to iTunes Store was unsuccessful.
    The network connection was refused.
    Secure connection attempt to iTunes Store was unsuccessful.
    The network connection was refused.

    You disabled everything using MSConfig and the network connection was still refused? That's odd.
    There may be some issue with your ISP, then. Do you have the ability to connect to the internet a different way, like a wireless access point? The fact that your connection was refused as opposed to simply timed out makes me think that there's something that is actively preventing iTunes from connecting to the iTunes Store.

Maybe you are looking for