JNDI naming exception: javax.naming.ServiceUnavailableException

Hi,
I am running a standalone version of WLS 6.1 sp4. When I start WLS, it throws
this exception:
<Mar 19, 2004 2:39:11 PM PST> <Critical> <Log Management> <Unable
to contact managed server - med1d2ms01, at d_conitti/10.0.4.81:7301.
Domain logfile will notcontain messages from this server.
java.lang.IllegalArgumentException: JNDI naming exception: javax.naming.ServiceUnavailableException
[Root exception is java.net.UnknownHostException: d_conitti]
However, weblogic doesn't shut down after this. It continues and deploys all the
apps. What intrigues me is, where is weblogic reading the 'd_conitti' managed
server from. I am not running any cluster. It beats me totally. I searched for
'd_conitti' on my whole machine. I didn't find any file with that word.
My environment is:
Win2k Server
wls 6.1 sp4
jdk 1.3.1
I would appreciate any help.
Thanks,
Abbas

Hi,
I am running a standalone version of WLS 6.1 sp4. When I start WLS, it throws
this exception:
<Mar 19, 2004 2:39:11 PM PST> <Critical> <Log Management> <Unable
to contact managed server - med1d2ms01, at d_conitti/10.0.4.81:7301.
Domain logfile will notcontain messages from this server.
java.lang.IllegalArgumentException: JNDI naming exception: javax.naming.ServiceUnavailableException
[Root exception is java.net.UnknownHostException: d_conitti]
However, weblogic doesn't shut down after this. It continues and deploys all the
apps. What intrigues me is, where is weblogic reading the 'd_conitti' managed
server from. I am not running any cluster. It beats me totally. I searched for
'd_conitti' on my whole machine. I didn't find any file with that word.
My environment is:
Win2k Server
wls 6.1 sp4
jdk 1.3.1
I would appreciate any help.
Thanks,
Abbas

Similar Messages

  • Naming error: javax.naming.NoInitialContextException

    I get the below error message when I try to run the testing class below that. I googled the exception and read:
    This exception is thrown when no initial context implementation can be created. The policy of how an initial context implementation is selected is described in the documentation of the InitialContext class.
    // then I read this: http://publib.boulder.ibm.com/infocenter/adiehelp/index.jsp?topic=/com.sun.api.doc/javax/naming/NoInitialContextException.html
    This exception can be thrown during any interaction with the InitialContext, not only when the InitialContext is constructed. For example, the implementation of the initial context might lazily retrieve the context only when actual methods are invoked on it.
    I really dont understand what I read. Could someone please explain what my issue is and why it is occurring and how I could fix it.
    Thank you in advance,
    Crystal
    Naming error: javax.naming.NoInitialContextException: Need to specify class name
    in environment or system property, or as an applet parameter, or in an applicat
    ion resource file:  java.naming.factory.initial
    Exception in thread "main" java.lang.NullPointerException
            at notifier.notifierMethod.SiteManager(notifierMethod.java:230)
            at notifier.testing.main(testing.java:22)
    testing.java
    class testing {
        public static void main(String[] args) {
            //Display "Hello World!"
            System.out.println("Hello World!");
            notifier notifierInformation = new notifier();
            //session.setAttribute("notifier", notifierInformation);
            //get db connection
            database.DataFactory dbf = database.DataFactory.getDataFactory(database.DataFactory.sybase);
            notifierInterface notifierDB = dbf.getNotifierInterface();
            notifier sitemanager = notifierDB.SiteManager(newID, notifierInformation);  // LINE 22
    notifierMethod
    public notifier SiteManager(String newID, notifier notifierInformation) {
            try {
                ArrayList sitemgrList = new ArrayList();
                this.conn = database.SybaseDAO.grabConnection();
                cs = conn.prepareCall("{call mt."+newID+"_Notifier_SiteManager()}"); // LINE 230
                rs = cs.executeQuery();
                while(rs.next()) {
                    String owner = rs.getString(1);
                        sitemgrList.add(owner);
                notifierInformation.setSitemgrList(sitemgrList);
    }

    Aleen - Thank you for your help but I just dont get what you are saying at all! I am reading through all the links and its just not clicking with me. Is it possible for you to show me a vague example of what you mean?
    What do you mean by system properties/enviroment parameters? Do you mean what is in my web.xml/server.xml, like so?
    public static Connection grabConnection() {
            Connection conn = null;
            try {
                Context ctx = (Context)new InitialContext().lookup("java:comp/env");
                DataSource ds = (DataSource)ctx.lookup("jdbc/connectDB");
                conn = ds.getConnection();
            } catch(SQLException e) { System.err.println("SQL error: " + e);
            } catch(NamingException n) { System.err.println("Naming error: " + n);
            return conn;
    web.xml
    <description>MySQL Test App</description>
    <resource-ref>
          <description>DB Connection</description>
          <res-ref-name>jdbc/connectDB</res-ref-name>
          <res-type>javax.sql.DataSource</res-type>
          <res-auth>Container</res-auth>
    </resource-ref>
    server.xml
    <Context path="/appName" docBase="/appName"
            debug="5" reloadable="true" crossContext="true">
      <Logger className="org.apache.catalina.logger.FileLogger"
                 prefix="localhost_DBPool_log" suffix=".log"
                 timestamp="true"/>
    <Resource name="jdbc/connectDB" auth="Container" type="javax.sql.DataSource"
                   maxActive="5" maxIdle="1" maxWait="10000" removeAbandoned="true"
                removeAbandonedTimeout="60" logAbandoned="true"
                   username="myName" password="myPass" driverClassName="sun.jdbc.odbc.JdbcOdbcDriver"
                   url="jdbc:odbc:webdev"/>
    </Context>I just dont understand why if I have this code in a servlet it works fine but when I try to put it in a java class it doesnt work. And I am sorry in advance, I am not trying to be a pain in the a55 to you.. and I will keep reading
    Thanks - Crystal

  • Handlling exception: javax.naming.PartialResultException: Unprocessed Conti

    I am running the following Java Code (in an agent in Lotus Notes, hence some of the odd bits). I've searched long and hard. I know I'm getting my error because I am searching the from the base DN in AD.
    It also appears you can't get around this with referrals settings as AD doesn't support them. I having trouble with the whole global catalog thing too.
    However, my code is working and returning the field I need. I would like to handle the error and get on with things.
    Now I am not a java programmer. Is it possible to handle the error and return to the code that generated it, or am I finished with the 'try' stuff as soon as my first exception is thrown?
    Sorry if this is a stupid question.
    import lotus.domino.*;
    import javax.naming.*;
    import javax.naming.directory.*;
    import java.util.Hashtable;
    import java.util.Vector;
    public class JavaAgent extends AgentBase {
         public void NotesMain() {
              String userName="jmbramich";
              try {
                   Session session = getSession();
                   AgentContext agentContext = session.getAgentContext();
              // Hashtable stores LDAP connection specifics.
                   Hashtable env = new Hashtable();
                   env.put(Context.INITIAL_CONTEXT_FACTORY, "com.sun.jndi.ldap.LdapCtxFactory");
                   env.put(Context.PROVIDER_URL, "ldap://hqdc01.prisons.ie:389");
    //               env.put(Context.PROVIDER_URL, "ldap://hqdc01.prisons.ie:3268");
                   env.put(Context.SECURITY_PRINCIPAL, "CN=L D. dapsearch,OU=LDAP,OU=Rescon,OU=Administrators,DC=PRISONS,DC=IE");
                   env.put(Context.SECURITY_CREDENTIALS, "gu1nne55");
                   DirContext ctx = new InitialDirContext(env);
                   // Specify the ids of the attributes to return
                   String[] attrIDs = {"postOfficeBox"};
                   SearchControls ctls = new SearchControls();
                   ctls.setReturningAttributes(attrIDs);
                   ctls.setSearchScope(SearchControls.SUBTREE_SCOPE);
                   // Specify the search filter to match
                   String filter = "(&(sAMAccountName=" + userName + ")(postOfficeBox=*))";
                   // Search the subtree for objects by using the filter
                   NamingEnumeration answer = ctx.search("DC=PRISONS,DC=IE", filter, ctls);
                   while (answer.hasMore()) {
                   SearchResult sr = (SearchResult)answer.next();
                   System.out.println(">>>" + sr.getName());
                   Attributes attrs = sr.getAttributes();
                   System.out.println(attrs.get("postOfficeBox").get());                                    
                   answer.close();
                   ctx.close();               
              } catch(Exception e) {
                   e.printStackTrace();
    Errors:
    javax.naming.PartialResultException: Unprocessed Continuation Reference(s); remaining name 'DC=PRISONS,DC=IE'
         at com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:2528)
         at com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:2502)
         at com.sun.jndi.ldap.LdapNamingEnumeration.getNextBatch(LdapNamingEnumeration.java:145)
         at com.sun.jndi.ldap.LdapNamingEnumeration.hasMore(LdapNamingEnumeration.java:181)
         at JavaAgent.NotesMain(JavaAgent.java:38)
         at lotus.domino.AgentBase.runNotes(Unknown Source)
         at lotus.domino.NotesThread.run(NotesThread.java:208)
    Error cleaning up agent threads

    Ok, managed to work this out. Needed a baby try/catch around a bit of my code so the error can be ignored - once this is done the notes agent doesn't have any problems taking out the garbage at the end.
    Final code:
    import lotus.domino.*;
    import javax.naming.*;
    import javax.naming.directory.*;
    import java.util.Hashtable;
    import java.util.Vector;
    public class JavaAgent extends AgentBase {
         public void NotesMain() {
              String userName="jmbramich";
              try {
                   Session session = getSession();
                   AgentContext agentContext = session.getAgentContext();
              // Hashtable stores LDAP connection specifics.
                   Hashtable env = new Hashtable();
                   env.put(Context.INITIAL_CONTEXT_FACTORY, "com.sun.jndi.ldap.LdapCtxFactory");
                   env.put(Context.PROVIDER_URL, "ldap://hqdc01.prisons.ie:389");
    //               env.put(Context.PROVIDER_URL, "ldap://hqdc01.prisons.ie:3268");
                   env.put(Context.SECURITY_PRINCIPAL, "CN=L D. dapsearch,OU=LDAP,OU=Rescon,OU=Administrators,DC=PRISONS,DC=IE");
                   env.put(Context.SECURITY_CREDENTIALS, "gu1nne55");
         System.out.println("Creating Context.");
                   DirContext ctx = new InitialDirContext(env);
                   // Specify the ids of the attributes to return
                   String[] attrIDs = {"postOfficeBox"};
                   SearchControls ctls = new SearchControls();
                   ctls.setReturningAttributes(attrIDs);
                   ctls.setSearchScope(SearchControls.SUBTREE_SCOPE);
                   // Specify the search filter to match
                   String filter = "(&(sAMAccountName=" + userName + ")(postOfficeBox=*))";
                   // Search the subtree for objects by using the filter
         System.out.println("Running Search...");
                   NamingEnumeration answer = ctx.search("DC=PRISONS,DC=IE", filter, ctls);
                   try {
                        while (answer.hasMore()) {
                        SearchResult sr = (SearchResult)answer.next();
                        System.out.println(">>>" + sr.getName());
                        Attributes attrs = sr.getAttributes();
                             System.out.println(attrs.get("postOfficeBox").get());                                    
                   catch(PartialResultException e) {
                        //e.printStackTrace();
                   answer.close();
                   ctx.close();
              catch(Exception e) {
                   e.printStackTrace();
    }

  • JMS cluster and happen JMS Queue Exception javax.naming.NameAlreadyBoundExc

    Hi,
    Sorry I not sure how to setup JMS cluster in WLS 10.3.2. We have two manager server in two machine. And will join into one cluster. After configure the JMS module & JMS server. We found it only can work in one server. And will faill in another server. And reply the error message as below :
    Any one can help to tell me why one server success. And other is fail !
    javax.naming.NameAlreadyBoundException: JMS_Queue_misdel_a is already bound; rem
    aining name ''
    at weblogic.jndi.internal.BasicNamingNode.bindHere(BasicNamingNode.java:357)
    at weblogic.jndi.internal.ServerNamingNode.bindHere(ServerNamingNode.java:140)
    at weblogic.jndi.internal.BasicNamingNode.bind(BasicNamingNode.java:317)
    at weblogic.jndi.internal.WLEventContextImpl.bind(WLEventContextImpl.jav
    ==> config for JMS
    <jms-server>
    <name>JMS_Server_cim_a</name>
    <target>ebowls05</target>
    <persistent-store xsi:nil="true"></persistent-store>
    <hosting-temporary-destinations>true</hosting-temporary-destinations>
    <temporary-template-resource xsi:nil="true"></temporary-template-resource>
    <temporary-template-name xsi:nil="true"></temporary-template-name>
    <message-buffer-size>-1</message-buffer-size>
    <expiration-scan-interval>30</expiration-scan-interval>
    </jms-server>
    <jms-server>
    <name>JMS_Server_cim_b</name>
    <target>ebowls06</target>
    <persistent-store xsi:nil="true"></persistent-store>
    <hosting-temporary-destinations>true</hosting-temporary-destinations>
    <temporary-template-resource xsi:nil="true"></temporary-template-resource>
    <temporary-template-name xsi:nil="true"></temporary-template-name>
    <message-buffer-size>-1</message-buffer-size>
    <expiration-scan-interval>30</expiration-scan-interval>
    </jms-server>
    <migratable-target>
    <name>ebowls06 (migratable)</name>
    <notes>This is a system generated default migratable target for a server. Do
    not delete manually.</notes>
    <user-preferred-server>ebowls06</user-preferred-server>
    <cluster>ebouatCluster</cluster>
    </migratable-target>
    <migratable-target>
    <name>ebowls05 (migratable)</name>
    <notes>This is a system generated default migratable target for a server. Do
    not delete manually.</notes>
    <user-preferred-server>ebowls05</user-preferred-server>
    <cluster>ebouatCluster</cluster>
    </migratable-target>
    <jms-system-resource>
    <name>JMS_ConnFactory_cim</name>
    <target>ebouatCluster</target>
    <descriptor-file-name>jms/JMS_ConnFactory_cim/JMS_ConnFactory_cim-jms.xml</d
    escriptor-file-name>
    </jms-system-resource>
    <jms-system-resource>
    <name>JMS_Queue_promis</name>
    <target>ebouatCluster</target>
    <sub-deployment>
    <name>JMS_Queue_promis@JMS_Server_cim_a</name>
    <target>JMS_Server_cim_a</target>
    </sub-deployment>
    <sub-deployment>
    <name>JMS_Queue_promis@JMS_Server_cim_b</name>
    <target>JMS_Server_cim_b</target>
    </sub-deployment>
    <descriptor-file-name>jms/JMS_Queue_promis/JMS_Queue_promis-jms.xml</descrip
    tor-file-name>
    </jms-system-resource>
    <jms-system-resource>
    <name>JMS_Template_cim</name>
    <target>ebouatCluster</target>
    <descriptor-file-name>jms/JMS_Template_cim/JMS_Template_cim-jms.xml</descrip
    tor-file-name>
    </jms-system-resource>
    <jms-system-resource>
    <name>JMS_Queue_misdel_a</name>
    <target>ebouatCluster</target>
    <sub-deployment>
    <name>JMS_Queue_misdel_a@JMS_Server_cim_a</name>
    <target>JMS_Server_cim_a</target>
    </sub-deployment>
    <sub-deployment>
    <name>JMS_Queue_misdel_a@JMS_Server_cim_b</name>
    <target>JMS_Server_cim_b</target>
    </sub-deployment>
    <descriptor-file-name>jms/JMS_Queue_misdel_a/JMS_Queue_misdel_a-jms.xml</des
    criptor-file-name>
    </jms-system-resource>
    <jms-system-resource>
    <name>JMS_Queue_misdel_b</name>
    <target>ebouatCluster</target>
    <sub-deployment>
    <name>JMS_Queue_misdel_b@JMS_Server_cim_a</name>
    <target>JMS_Server_cim_a</target>
    </sub-deployment>
    <sub-deployment>
    <name>JMS_Queue_misdel_b@JMS_Server_cim_b</name>
    <target>JMS_Server_cim_b</target>
    </sub-deployment>
    <descriptor-file-name>jms/JMS_Queue_misdel_b/JMS_Queue_misdel_b-jms.xml</des
    criptor-file-name>
    </jms-system-resource>

    1 - JMS clustering is an advanced concept, and, in most cases, uses "distributed queues". In case you haven't already, I highly recommend reading the JMS chapter of the new book "Professional Oracle WebLogic" as well as the related chapters in the JMS Programmer's Guide in the edocs.
    2 - The basic problem below is that you have two different queues that have matching JNDI names, but are in the same cluster.
    3 - The config snippet supplied below does not include the queue configuration. Queue configuration is embedded within the referenced module files.
    4 - Please ensure that you follow configuration best practices, as per: http://download.oracle.com/docs/cd/E15523_01/web.1111/e13738/best_practice.htm#CACJCGHG

  • JNDI lookup failed:javax.naming.NameNotFoundException

    Hello:
    I have a application (not web) that publish messages to a specific topic, i want to receive these messages in a Web Service, but when the web service make the call to a class that is the JMS Client it can't find the Connection factory Name that i create in the aplication.
    I want to know what i have to do,
    I work with J2EE1.3.1 and JMS1.0.2 for the application that publish the messages
    and Jwsdp1.1, tomcat 4 and j2sdk 1.4.0 for the web service.
    I create the connection factory with this command:
    j2eeadmin -addJmsFactory jms/DurableTopicB topic -props clientID=IdTopicB
    Then in the class that the web service invoke i trying to join with this:
    try {
    jndiContext =new InitialContext();
    }catch (NamingException e){
    System.err.println("Could not create JNDI API "+
    "context:"+e.toString());
    return;
    *Look up connection factory and topic.If either  
    *does not exist,exit.                            
    try {
    topicConnectionFactory =(TopicConnectionFactory)
    jndiContext.lookup(conFacName);
    }catch (NamingException e){                      
    System.err.println("JNDI API lookup failed:"+
    e.toString());
    return;
    //System.exit(1);
    But i receive a error message in the log of Tomcat:
    JNDI API lookup failed:javax.naming.NameNotFoundException: El nombre DurableTopicB no este asociado a este contexto
    Thanks

    Hello:
    I display the full context of the connection factory in the application that publish the message:
    Full context is :
    Enviroment is : {java.naming.corba.orb=com.sun.enterprise.iiop.POAEJBORB@ec4a87}
    And in the web service when i create the initial context the full context is:
    Full context is : java:
    Enviroment is : {java.naming.factory.initial=org.apache.naming.java.javaURLContextFactory, java.naming.factory.url.pkgs=org.apache.naming}
    How can i see the connection factory in the Web Service, because the connection factory was created in other Application?

  • Exception - javax.naming.NameNotFoundException: HelloHome not bound

    Hi Friends
    I deployed the ejb jar file successfully in JBOSS app server in "jboss-4.0.3RC1\server\default\deploy\". But when I run the client file (compiled successfully) displays the following exception :-
    Exception in thread "main" javax.naming.NameNotFoundException: HelloHome not bound
    at org.jnp.server.NamingServer.getBinding(NamingServer.java:491)
    at org.jnp.server.NamingServer.getBinding(NamingServer.java:499)
    at org.jnp.server.NamingServer.getObject(NamingServer.java:505)
    at org.jnp.server.NamingServer.lookup(NamingServer.java:278)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:585)
    at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:294)
    at sun.rmi.transport.Transport$1.run(Transport.java:153)
    at java.security.AccessController.doPrivileged(Native Method)
    at sun.rmi.transport.Transport.serviceCall(Transport.java:149)
    at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460)
    at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:701)
    at java.lang.Thread.run(Thread.java:595)
    at sun.rmi.transport.StreamRemoteCall.exceptionReceivedFromServer(StreamRemoteCall.java:247)
    at sun.rmi.transport.StreamRemoteCall.executeCall(StreamRemoteCall.java:223)
    at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:126)
    at org.jnp.server.NamingServer_Stub.lookup(Unknown Source)
    at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:610)
    at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:572)
    at javax.naming.InitialContext.lookup(InitialContext.java:351)
    at HelloClientNew.main(HelloClientNew.java:17)
    My HelloClient.java file code is :-
    import examples.*;
    import javax.naming.Context;
    import javax.naming.InitialContext;
    import java.util.Properties;
    public class HelloClientNew
         public static void main(String args[]) throws Exception
              Properties env = new Properties();
              env.setProperty("java.naming.factory.initial","org.jnp.interfaces.NamingContextFactory");
              env.setProperty("java.naming.provider.url","jnp://localhost:1099");
              env.setProperty("java.naming.factory.url.pkgs","org.jboss.naming:org.jnp.interfaces");
              Context ctx=new InitialContext(env);
              Object obj=ctx.lookup("HelloHome");
              HelloHome home=(HelloHome)javax.rmi.PortableRemoteObject.narrow(obj,HelloHome.class);
              Hello hello=home.create();
              System.out.println(hello.hello());
              hello.remove();
    The package "examples" contains - Hello,HelloHome,HelloLocal,HelloLocalHome and HelloBean source and class files.
    I tried a lot but still am stuck to this problem. If anybody can tell me the solution then I will be very thankful to him.
    Thanks
    Bhoopender

    Please provide me solution for this .I am also facing the same problem.
    javax.naming.NameNotFoundException: HelloBean not bound
         at org.jnp.server.NamingServer.getBinding(NamingServer.java:529)
         at org.jnp.server.NamingServer.getBinding(NamingServer.java:537)
         at org.jnp.server.NamingServer.getObject(NamingServer.java:543)
         at org.jnp.server.NamingServer.lookup(NamingServer.java:296)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
         at java.lang.reflect.Method.invoke(Unknown Source)
         at sun.rmi.server.UnicastServerRef.dispatch(Unknown Source)
         at sun.rmi.transport.Transport$1.run(Unknown Source)
         at java.security.AccessController.doPrivileged(Native Method)
         at sun.rmi.transport.Transport.serviceCall(Unknown Source)
         at sun.rmi.transport.tcp.TCPTransport.handleMessages(Unknown Source)
         at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(Unknown Source)
         at java.lang.Thread.run(Unknown Source)
         at sun.rmi.transport.StreamRemoteCall.exceptionReceivedFromServer(Unknown Source)
         at sun.rmi.transport.StreamRemoteCall.executeCall(Unknown Source)
         at sun.rmi.server.UnicastRef.invoke(Unknown Source)
         at org.jnp.server.NamingServer_Stub.lookup(Unknown Source)
         at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:625)
         at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:587)
         at javax.naming.InitialContext.lookup(Unknown Source)
         at com.logica.Client.main(Client.java:18)
    public class Client {
    public static void main(String a[]){
         try{
              Hashtable env = new Hashtable();
              env.put(Context.INITIAL_CONTEXT_FACTORY, "org.jnp.interfaces.NamingContextFactory");
              env.put(Context.PROVIDER_URL,"localhost");
              env.put(Context.URL_PKG_PREFIXES, "org.jboss.naming:org.jnp.interfaces" );
              Context ctx=new InitialContext(env);
              System.out.println("dfhdf"+ctx);
              Object O=ctx.lookup("HelloBean");
              //System.out.println("dafjhda"+O);
              CartHome cart=(CartHome)O;
              CartRemote Rem=cart.Create();
              CartRemote Rem1=cart.Create("99");
              Rem.addBook("java1");
              Rem.addBook("java2");
              Rem1.addBook("C1");
              Rem1.addBook("C2");
              System.out.println("Details"+Rem.ShowAllBooks());
              System.out.println("Details1"+Rem.placeOrder());
              System.out.println("Details2"+Rem1.ShowAllBooks());
              System.out.println("Details djfj"+Rem1.placeOrder());
         catch (Exception e) {
    e.printStackTrace()     ;
    Thanks,
    Krishnakumar

  • Javax.naming.ServiceUnavailableException

    Hi I have following prog
    package myconnection;
    import java.sql.*;
    import java.rmi.Naming;
    import javax.naming.*;
    import javax.sql.ConnectionPoolDataSource;
    import javax.sql.PooledConnection;
    * @author Admin
    public class MyConnection {
    public static void main(String[] args) {
    java.util.Properties prop = new java.util.Properties();
    prop.put(Context.INITIAL_CONTEXT_FACTORY, "com.sun.jndi.rmi.registry.RegistryContextFactory");
    sun.jdbc.odbc.ee.ConnectionPoolDataSource cpds =
    new sun.jdbc.odbc.ee.ConnectionPoolDataSource("jdbc/OdbcPool");
    try{
    cpds.setUser("jspadmin");
    cpds.setPassword("jspadmin");
    cpds.setDatabaseName("ccsdb");
    cpds.setLoginTimeout(100);
    cpds.setMinPoolSize("10");
    cpds.setInitialPoolSize("15");
    cpds.setMaxPoolSize("20");
    cpds.setMaxIdleTime("300");
    cpds.setTimeoutFromPool("600");
    cpds.setMaintenanceInterval("900");
    InitialContext ic = new InitialContext(prop);
    ic.bind("jdbc/OdbcPool",cpds);
    InitialContext icc = new InitialContext(prop);
    javax.sql.ConnectionPoolDataSource cpd =
    (javax.sql.ConnectionPoolDataSource) icc.lookup("jdbc/OdbcPool");
    PooledConnection pc1 = cpd.getPooledConnection();
    Connection con1 = pc1.getConnection();
    PooledConnection pc2 = cpd.getPooledConnection("system","manager");
    Connection con2 = pc2.getConnection();
    Statement st = con1.createStatement();
    ResultSet rs = st.executeQuery("select * from cet_user");
    while(rs.next())
    System.out.println(rs.getString(1));
    con1.close();
    con2.close();
    Connection con3 = pc1.getConnection();
    Connection con4 = pc2.getConnection();
    pc1.close();
    pc2.close();
    }catch(Exception e){ e.printStackTrace();}
    I am getting following error
    init:
    deps-jar:
    compile:
    run:
    javax.naming.ServiceUnavailableException [Root exception is java.rmi.ConnectException: Connection refused to host: 192.168.0.32; nested exception is:
            java.net.ConnectException: Connection refused: connect]
    at com.sun.jndi.rmi.registry.RegistryContext.bind(RegistryContext.java:122)
    at com.sun.jndi.rmi.registry.RegistryContext.bind(RegistryContext.java:127)
    at javax.naming.InitialContext.bind(InitialContext.java:359)
    at myconnection.MyConnection.main(MyConnection.java:41)
    Caused by: java.rmi.ConnectException: Connection refused to host: 192.168.0.32; nested exception is:
    java.net.ConnectException: Connection refused: connect
    at sun.rmi.transport.tcp.TCPEndpoint.newSocket(TCPEndpoint.java:574)
    at sun.rmi.transport.tcp.TCPChannel.createConnection(TCPChannel.java:185)
    at sun.rmi.transport.tcp.TCPChannel.newConnection(TCPChannel.java:171)
    at sun.rmi.server.UnicastRef.newCall(UnicastRef.java:306)
    at sun.rmi.registry.RegistryImpl_Stub.bind(Unknown Source)
    at com.sun.jndi.rmi.registry.RegistryContext.bind(RegistryContext.java:116)
    ... 3 more
    Caused by: java.net.ConnectException: Connection refused: connect
    at java.net.PlainSocketImpl.socketConnect(Native Method)
    at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:333)
    at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:195)
    at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:182)
    at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:364)
    at java.net.Socket.connect(Socket.java:507)
    at java.net.Socket.connect(Socket.java:457)
    at java.net.Socket.<init>(Socket.java:365)
    at java.net.Socket.<init>(Socket.java:178)
    at sun.rmi.transport.proxy.RMIDirectSocketFactory.createSocket(RMIDirectSocketFactory.java:22)
    at sun.rmi.transport.proxy.RMIMasterSocketFactory.createSocket(RMIMasterSocketFactory.java:128)
    at sun.rmi.transport.tcp.TCPEndpoint.newSocket(TCPEndpoint.java:569)
    ... 8 more
    BUILD SUCCESSFUL (total time: 1 minute 11 seconds)
    Can anyone give me Solution on this.

    Now I set properties as
    prop.put(Context.PROVIDER_URL, "rmi://localhost:8080");
    now I am geting following exception
    javax.naming.CommunicationException [Root exception is java.rmi.ConnectIOException: error during JRMP connection establishment; nested exception is:
            java.io.EOFException]
    at com.sun.jndi.rmi.registry.RegistryContext.bind(RegistryContext.java:122)
    at com.sun.jndi.rmi.registry.RegistryContext.bind(RegistryContext.java:127)
    at javax.naming.InitialContext.bind(InitialContext.java:359)
    at myconnection.MyConnection.main(MyConnection.java:42)
    Caused by: java.rmi.ConnectIOException: error during JRMP connection establishment; nested exception is:
    java.io.EOFException
    at sun.rmi.transport.tcp.TCPChannel.createConnection(TCPChannel.java:274)
    at sun.rmi.transport.tcp.TCPChannel.newConnection(TCPChannel.java:171)
    at sun.rmi.server.UnicastRef.newCall(UnicastRef.java:306)
    at sun.rmi.registry.RegistryImpl_Stub.bind(Unknown Source)
    at com.sun.jndi.rmi.registry.RegistryContext.bind(RegistryContext.java:116)
    ... 3 more
    Caused by: java.io.EOFException
    at java.io.DataInputStream.readByte(DataInputStream.java:243)
    at sun.rmi.transport.tcp.TCPChannel.createConnection(TCPChannel.java:215)
    ... 7 more
    BUILD SUCCESSFUL (total time: 1 minute 6 seconds)

  • Javax.naming.NamingException.  Root exception is java.lang.NoSuchMethodError

    I am using WLS5.1 inside visualage environment. I am trying to run
    a Simple EJB which connects to the database and executes two simple
    queries. The client code is as shown below:
    try{
    Context ic = getInitialContext();
    System.out.println("Initial Context created......"); java.lang.Object
    objref = ic.lookup("simpleBean.AtmHome"); System.out.println("objref
    created......");
    AtmHome home = (AtmHome) PortableRemoteObject.narrow(objref, AtmHome.class);
    System.out.println("home created......");
    Atm atm = home.create();
    System.out.println("atm created......");
    atm.transfer(8, 9, 100000);
    catch (NamingException ne)
    ne.printStackTrace(System.out);
    finally {
         try {
              ic.close();
              System.out.println("Closed the connection");
         catch (Exception e) {
              System.out.println("Exception while closing context....." );
    The above code executes fine for the first time but second time
    it throws an exception "javax.naming.NamingException.
    Root exception is java.lang.NoSuchMethodError"
    javax.naming.NamingException. Root exception is java.lang.NoSuchMethodError
         java.lang.Throwable()
         java.lang.Error()
         java.lang.LinkageError()
         java.lang.IncompatibleClassChangeError()
         java.lang.NoSuchMethodError()
         void javax.naming.NameImpl.recordNamingConvention(java.util.Properties)
         void javax.naming.NameImpl.recordNamingConvention(java.util.Properties)
         javax.naming.NameImpl(java.util.Properties)
         javax.naming.CompositeName()
         weblogic.jndi.toolkit.NormalName(java.lang.String, javax.naming.NameParser)
         weblogic.jndi.toolkit.NormalName weblogic.jndi.toolkit.BasicWLContext.normalizeName(java.lang.String)
         java.lang.Object weblogic.jndi.toolkit.BasicWLContext.lookup(java.lang.String)
         weblogic.rmi.extensions.OutgoingResponse weblogic.jndi.toolkit.BasicWLContext_WLSkel.invoke(weblogic.rmi.extensions.ServerObjectReference,
    int, weblogic.rmi.extensions.IncomingRequest, weblogic.rmi.extensions.OutgoingResponse)
         java.lang.Throwable weblogic.rmi.extensions.BasicServerObjectAdapter.invoke(int,
    weblogic.rmi.extensions.IncomingRequest)
         void weblogic.rmi.extensions.BasicRequestHandler.handleRequest(weblogic.rmi.extensions.IncomingRequest)
         void weblogic.rmi.internal.BasicExecuteRequest.execute(weblogic.kernel.ExecuteThread)
         void weblogic.kernel.ExecuteThread.run()
    --------------- nested within: ------------------
    weblogic.rmi.ServerError: A RemoteException occurred in the server
    method
    - with nested exception:
    [java.lang.NoSuchMethodError:
    Start server side stack trace:
    java.lang.NoSuchMethodError
         java.lang.Throwable()
         java.lang.Error()
         java.lang.LinkageError()
         java.lang.IncompatibleClassChangeError()
         java.lang.NoSuchMethodError()
         void javax.naming.NameImpl.recordNamingConvention(java.util.Properties)
         void javax.naming.NameImpl.recordNamingConvention(java.util.Properties)
         javax.naming.NameImpl(java.util.Properties)
         javax.naming.CompositeName()
         weblogic.jndi.toolkit.NormalName(java.lang.String, javax.naming.NameParser)
         weblogic.jndi.toolkit.NormalName weblogic.jndi.toolkit.BasicWLContext.normalizeName(java.lang.String)
         java.lang.Object weblogic.jndi.toolkit.BasicWLContext.lookup(java.lang.String)
         weblogic.rmi.extensions.OutgoingResponse weblogic.jndi.toolkit.BasicWLContext_WLSkel.invoke(weblogic.rmi.extensions.ServerObjectReference,
    int, weblogic.rmi.extensions.IncomingRequest, weblogic.rmi.extensions.OutgoingResponse)
         java.lang.Throwable weblogic.rmi.extensions.BasicServerObjectAdapter.invoke(int,
    weblogic.rmi.extensions.IncomingRequest)
         void weblogic.rmi.extensions.BasicRequestHandler.handleRequest(weblogic.rmi.extensions.IncomingRequest)
         void weblogic.rmi.internal.BasicExecuteRequest.execute(weblogic.kernel.ExecuteThread)
         void weblogic.kernel.ExecuteThread.run()
    End  server side stack trace
         weblogic.rmi.extensions.WRMIInputStream weblogic.rmi.extensions.AbstractRequest.sendReceive()
         java.lang.Object weblogic.jndi.toolkit.BasicWLContext_WLStub.lookup(java.lang.String)
         java.lang.Object weblogic.jndi.toolkit.WLContextStub.lookup(java.lang.String)
         java.lang.Object javax.naming.InitialContext.lookup(java.lang.String)
         void simpleBean.AtmClient.main(java.lang.String [])
    NamingException is caught....
    I found out that it hangs at lookup function in the above code.
    Please let me know if I am missing any environment settings.
    Thanks
    Shailaja

    This problem is solved after installing service pack 8 for weblogic
    5.1
    -shailaja
    "shailaja" <[email protected]> wrote:
    >
    I am using WLS5.1 inside visualage environment. I am trying
    to run
    a Simple EJB which connects to the database and executes
    two simple
    queries. The client code is as shown below:
    try{
    Context ic = getInitialContext();
    System.out.println("Initial Context created......"); java.lang.Object
    objref = ic.lookup("simpleBean.AtmHome"); System.out.println("objref
    created......");
    AtmHome home = (AtmHome) PortableRemoteObject.narrow(objref,
    AtmHome.class);
    System.out.println("home created......");
    Atm atm = home.create();
    System.out.println("atm created......");
    atm.transfer(8, 9, 100000);
    catch (NamingException ne)
    ne.printStackTrace(System.out);
    finally {
         try {
              ic.close();
              System.out.println("Closed the connection");
         catch (Exception e) {
              System.out.println("Exception while closing context....."
    The above code executes fine for the first time but second
    time
    it throws an exception "javax.naming.NamingException.
    Root exception is java.lang.NoSuchMethodError"
    javax.naming.NamingException. Root exception is java.lang.NoSuchMethodError
         java.lang.Throwable()
         java.lang.Error()
         java.lang.LinkageError()
         java.lang.IncompatibleClassChangeError()
         java.lang.NoSuchMethodError()
         void javax.naming.NameImpl.recordNamingConvention(java.util.Properties)
         void javax.naming.NameImpl.recordNamingConvention(java.util.Properties)
         javax.naming.NameImpl(java.util.Properties)
         javax.naming.CompositeName()
         weblogic.jndi.toolkit.NormalName(java.lang.String, javax.naming.NameParser)
         weblogic.jndi.toolkit.NormalName weblogic.jndi.toolkit.BasicWLContext.normalizeName(java.lang.String)
         java.lang.Object weblogic.jndi.toolkit.BasicWLContext.lookup(java.lang.String)
         weblogic.rmi.extensions.OutgoingResponse weblogic.jndi.toolkit.BasicWLContext_WLSkel.invoke(weblogic.rmi.extensions.ServerObjectReference,
    int, weblogic.rmi.extensions.IncomingRequest, weblogic.rmi.extensions.OutgoingResponse)
         java.lang.Throwable weblogic.rmi.extensions.BasicServerObjectAdapter.invoke(int,
    weblogic.rmi.extensions.IncomingRequest)
         void weblogic.rmi.extensions.BasicRequestHandler.handleRequest(weblogic.rmi.extensions.IncomingRequest)
         void weblogic.rmi.internal.BasicExecuteRequest.execute(weblogic.kernel.ExecuteThread)
         void weblogic.kernel.ExecuteThread.run()
    --------------- nested within: ------------------
    weblogic.rmi.ServerError: A RemoteException occurred in
    the server
    method
    - with nested exception:
    [java.lang.NoSuchMethodError:
    Start server side stack trace:
    java.lang.NoSuchMethodError
         java.lang.Throwable()
         java.lang.Error()
         java.lang.LinkageError()
         java.lang.IncompatibleClassChangeError()
         java.lang.NoSuchMethodError()
         void javax.naming.NameImpl.recordNamingConvention(java.util.Properties)
         void javax.naming.NameImpl.recordNamingConvention(java.util.Properties)
         javax.naming.NameImpl(java.util.Properties)
         javax.naming.CompositeName()
         weblogic.jndi.toolkit.NormalName(java.lang.String, javax.naming.NameParser)
         weblogic.jndi.toolkit.NormalName weblogic.jndi.toolkit.BasicWLContext.normalizeName(java.lang.String)
         java.lang.Object weblogic.jndi.toolkit.BasicWLContext.lookup(java.lang.String)
         weblogic.rmi.extensions.OutgoingResponse weblogic.jndi.toolkit.BasicWLContext_WLSkel.invoke(weblogic.rmi.extensions.ServerObjectReference,
    int, weblogic.rmi.extensions.IncomingRequest, weblogic.rmi.extensions.OutgoingResponse)
         java.lang.Throwable weblogic.rmi.extensions.BasicServerObjectAdapter.invoke(int,
    weblogic.rmi.extensions.IncomingRequest)
         void weblogic.rmi.extensions.BasicRequestHandler.handleRequest(weblogic.rmi.extensions.IncomingRequest)
         void weblogic.rmi.internal.BasicExecuteRequest.execute(weblogic.kernel.ExecuteThread)
         void weblogic.kernel.ExecuteThread.run()
    End  server side stack trace
         weblogic.rmi.extensions.WRMIInputStream weblogic.rmi.extensions.AbstractRequest.sendReceive()
         java.lang.Object weblogic.jndi.toolkit.BasicWLContext_WLStub.lookup(java.lang.String)
         java.lang.Object weblogic.jndi.toolkit.WLContextStub.lookup(java.lang.String)
         java.lang.Object javax.naming.InitialContext.lookup(java.lang.String)
         void simpleBean.AtmClient.main(java.lang.String [])
    NamingException is caught....
    I found out that it hangs at lookup function in the above
    code.
    Please let me know if I am missing any environment settings.
    Thanks
    Shailaja

  • Javax.naming.NoInitialContextException - jndi.properties

    I created an Enterprise application and deployed an Ejb project to the JBoss server.When I try to connect to the JNDI like this:
    Object o = initialContext.lookup(JNDI_NAME); I get this exception:
    javax.naming.NoInitialContextException: Need to specify class name in environment or system property, or as an applet parameter, or in an application resource file:  java.naming.factory.initial
    I put the jndi.properties file both into the client app and the bean project, near the .java files.
    here is the jndi.properties file:
    java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory
    java.naming.provider.url=http://localhost:1099
    java.naming.factory.url.pkgs=org.jboss.naming:org.jnp.interfaces
    I'm really confused...
    thanks..

    xyzt wrote:
    I put the jndi.properties file both into the client app and the bean project, near the .java files.
    here is the jndi.properties file:
    java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory
    java.naming.provider.url=http://localhost:1099
    java.naming.factory.url.pkgs=org.jboss.naming:org.jnp.interfaces
    I think that goes in
    ${JBOSS_HOME}/server/default/deploy/jms/jms-ds.xml

  • WL5.1 SP* javax.naming.NameNotFoundException

    I am looking for advice ... I started getting a NameNotFoundException when I
    moved from SP6 to SP8 running on a Solaris machine (NO code changes).
    Anyone have any ideas as to the problem? As the deployment names seem
    correct, it is not obvious to me where the problem lies.
    ejb-jar.xml snippet
    =============
    <session>
    <description>ProductHierarchy EJB</description>
    <display-name>ProductHierarchy</display-name>
    <ejb-name>ProductHierarchy</ejb-name>
    <home>com.redcelsius.ecommerce.product.ejb.ProductHierarchyHome</home>
    <remote>com.redcelsius.ecommerce.product.ejb.ProductHierarchy</remote>
    <ejb-class>com.redcelsius.ecommerce.product.ejb.ProductHierarchyBean</ejb-cl
    ass>
    <session-type>Stateless</session-type>
    <transaction-type>Bean</transaction-type>
    </session>
    weblogic-ejb-jar.xml snippet
    ===================
    <weblogic-enterprise-bean>
    <ejb-name>ProductHierarchy</ejb-name>
    <caching-descriptor>
    </caching-descriptor>
    <jndi-name>ecommerce.ProductHierarchyHome</jndi-name>
    </weblogic-enterprise-bean>
    client home lookup snippet
    ==================
    InitialContext ctx =
    AbstractResourceFactory.getResourceFactory().getInitialContext();
    Object ref = ctx.lookup("ecommerce.ProductHierarchyHome");
    Weblogic deployment
    ===============
    Thu Mar 01 12:18:31 GMT-05:00 2001:<I> <EJB JAR deployment
    ./myserver/redcelsius/ecommerce-server.jar> EJB home interface:
    'com.redcelsius.ecommerce.product.ejb.ProductHierarchyHome' deployed bound
    to the JNDI name: 'ecommerce.ProductHierarchyHome'
    Exception
    =======
    javax.naming.NameNotFoundException: 'ecommerce.ProductHierarchyHome';
    remaining name 'ecommerce.ProductHierarchyHome'
    at
    weblogic.jndi.toolkit.BasicWLContext.resolveName(BasicWLContext.java:745)
    at
    weblogic.jndi.toolkit.BasicWLContext.lookup(BasicWLContext.java:133)
    at
    weblogic.jndi.toolkit.BasicWLContext.lookup(BasicWLContext.java:574)
    at javax.naming.InitialContext.lookup(InitialContext.java:350)
    at
    com.redcelsius.ecommerce.product.web.ProductBean.getEJB(ProductBean.java:68)

    I solved the problem. We read vendor specific values (such as
    Context.PROVIDER_URL and Context.INITIAL_CONTEXT_FACTORY) from a property
    file in a startup class in a static initializer.
    It seems that the timing of when the startup class is loaded changed between
    sp6 and sp8; as a result the static initializer could not find our property
    file to set the values required when InitialContext(Properties) is called.
    Everything now works.
    Alan Koop
    "Rob Woollen" <[email protected]> wrote in message
    news:[email protected]...
    Are you sure that you are looking up the EJB on the WLS server that
    deployed it? (I have to ask.)
    Otherwise, there shouldn't be any required code changes between SP6 and
    SP8. We certainly test 1000s of EJBs against the service pack so JNDI
    lookups should work fine.
    Have you made any environmental changes?
    If you go back to SP6, does it still work?
    -- Rob
    Alan Koop wrote:
    I am looking for advice ... I started getting a NameNotFoundException
    when I
    moved from SP6 to SP8 running on a Solaris machine (NO code changes).
    Anyone have any ideas as to the problem? As the deployment names seem
    correct, it is not obvious to me where the problem lies.
    ejb-jar.xml snippet
    =============
    <session>
    <description>ProductHierarchy EJB</description>
    <display-name>ProductHierarchy</display-name>
    <ejb-name>ProductHierarchy</ejb-name>
    <home>com.redcelsius.ecommerce.product.ejb.ProductHierarchyHome</home>
    <remote>com.redcelsius.ecommerce.product.ejb.ProductHierarchy</remote>
    <ejb-class>com.redcelsius.ecommerce.product.ejb.ProductHierarchyBean</ejb-cl
    ass>
    <session-type>Stateless</session-type>
    <transaction-type>Bean</transaction-type>
    </session>
    weblogic-ejb-jar.xml snippet
    ===================
    <weblogic-enterprise-bean>
    <ejb-name>ProductHierarchy</ejb-name>
    <caching-descriptor>
    </caching-descriptor>
    <jndi-name>ecommerce.ProductHierarchyHome</jndi-name>
    </weblogic-enterprise-bean>
    client home lookup snippet
    ==================
    InitialContext ctx =
    AbstractResourceFactory.getResourceFactory().getInitialContext();
    Object ref = ctx.lookup("ecommerce.ProductHierarchyHome");
    Weblogic deployment
    ===============
    Thu Mar 01 12:18:31 GMT-05:00 2001:<I> <EJB JAR deployment
    ./myserver/redcelsius/ecommerce-server.jar> EJB home interface:
    'com.redcelsius.ecommerce.product.ejb.ProductHierarchyHome' deployedbound
    to the JNDI name: 'ecommerce.ProductHierarchyHome'
    Exception
    =======
    javax.naming.NameNotFoundException: 'ecommerce.ProductHierarchyHome';
    remaining name 'ecommerce.ProductHierarchyHome'
    at
    weblogic.jndi.toolkit.BasicWLContext.resolveName(BasicWLContext.java:745)
    at
    weblogic.jndi.toolkit.BasicWLContext.lookup(BasicWLContext.java:133)
    at
    weblogic.jndi.toolkit.BasicWLContext.lookup(BasicWLContext.java:574)
    at javax.naming.InitialContext.lookup(InitialContext.java:350)
    at
    com.redcelsius.ecommerce.product.web.ProductBean.getEJB(ProductBean.java:68)
    >
    Coming Soon: Building J2EE Applications & BEA WebLogic Server
    by Michael Girdley, Rob Woollen, and Sandra Emerson
    http://learnweblogic.com

  • Javax.naming.NameAlreadyBoundException: Failed to bind remote object

    I am getting an error while deploying wli-ejbs.ear file. This ear uses oracle thin drivers to connect to database. But while deploying i am receiving an error as below. Can anyone please help me to solve this problem?
    Deployer:149033]preparing application wli-ejbs on managed2_cvf01
    [Deployer:149033]preparing application wli-ejbs on managed1_cvf01
    [Deployer:149033]prepared application wli-ejbs on managed1_cvf01
    [Deployer:149033]prepared application wli-ejbs on managed2_cvf01
    [Deployer:149033]activating application wli-ejbs on managed1_cvf01
    [Deployer:149033]activating application wli-ejbs on managed2_cvf01
    [Deployer:149034]An exception occurred for task [Deployer:149026]Deploy application wli-ejbs on cvf01_cluster.: weblogic.management.DeploymentException:
    Exception:weblogic.management.ApplicationException: activate failed for calendar/oracle
    Module: calendar/oracle Error: Exception activating module: EJBModule(calendar/oracle,status=PREPARED)
    Unable to deploy EJB: RemoteCalendarBean from calendar/oracle:
    [EJB:011008]Unable to bind EJB Home Interface to the JNDI name: RemoteCalendarBean.
    javax.naming.NameAlreadyBoundException: Failed to bind remote object (ClusterableRemoteRef(704752282736664516S:172.24.206.163:[7003,7003,7004,7004,7003,7004,-1,0,0]:172.24.206.163:7003,172.24.206.163:7003:cvf01:managed1_cvf01 null)/948 [com.bea.wli.calendar.api.BusinessCalendarHome+javax.ejb.EJBHome+weblogic.ejb20.interfaces.RemoteHome]) to replica aware stub at RemoteCalendarBean(ClusterableRemoteRef(704752282736664516S:172.24.206.163:[7003,7003,7004,7004,7003,7004,-1,0,0]:172.24.206.163:7003,172.24.206.163:7003:cvf01:managed1_cvf01 [704752282736664516S:172.24.206.163:[7003,7003,7004,7004,7003,7004,-1,0,0]:172.24.206.163:7003,172.24.206.163:7003:cvf01:managed1_cvf01/944, -8505871579836432025S:172.24.206.163:[7005,7005,7006,7006,7005,7006,-1,0,0]:172.24.206.163:7003,172.24.206.163:7003:cvf01:managed2_cvf01/1008])/944 [com.bea.wli.calendar.api.BusinessCalendarHome+javax.ejb.EJBHome+weblogic.ejb20.interfaces.RemoteHome]); remaining name ''
    at weblogic.rmi.cluster.ClusterableRemoteObject.onBind(ClusterableRemoteObject.java:177)
    at weblogic.jndi.internal.BasicNamingNode.bindHere(BasicNamingNode.java:347)
    at weblogic.jndi.internal.ServerNamingNode.bindHere(ServerNamingNode.java:124)
    at weblogic.jndi.internal.BasicNamingNode.bind(BasicNamingNode.java:291)
    at weblogic.jndi.internal.WLEventContextImpl.bind(WLEventContextImpl.java:279)
    at weblogic.jndi.internal.WLContextImpl.bind(WLContextImpl.java:386)
    at weblogic.ejb20.deployer.ClientDrivenBeanInfoImpl.activate(ClientDrivenBeanInfoImpl.java:1141)
    at weblogic.ejb20.deployer.EJBDeployer.activate(EJBDeployer.java:1385)
    at weblogic.ejb20.deployer.EJBModule.activate(EJBModule.java:631)
    at weblogic.j2ee.J2EEApplicationContainer.activateModule(J2EEApplicationContainer.java:3315)
    at weblogic.j2ee.J2EEApplicationContainer.activate(J2EEApplicationContainer.java:2194)
    at weblogic.j2ee.J2EEApplicationContainer.activate(J2EEApplicationContainer.java:2167)
    at weblogic.management.deploy.slave.SlaveDeployer$ComponentActivateTask.activateContainer(SlaveDeployer.java:2503)
    at weblogic.management.deploy.slave.SlaveDeployer$ActivateTask.doCommit(SlaveDeployer.java:2421)
    at weblogic.management.deploy.slave.SlaveDeployer$Task.commit(SlaveDeployer.java:2138)
    at weblogic.management.deploy.slave.SlaveDeployer.commitUpdate(SlaveDeployer.java:676)
    at weblogic.drs.internal.SlaveCallbackHandler$2.execute(SlaveCallbackHandler.java:35)
    at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:219)
    at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:178)

    run the sync.bat file as mentioned in the instructions...
    or through EBCC(select sampleportal-project dir, app name "sampleportal")...
    good luck
    Vijay
    "ellen" <[email protected]> wrote:
    >
    I installed sampleportal and did all the changes according to the documents,
    when
    the server started, there is this error:
    Unable to deploy EJB: CatalogWebService from catalogwe.jar:
    Unable to bind EJB Home Interface to the JNDI name: sampleportal.BEA_commerce.CatalogWebService.
    The error was: javax.naming.nameAlreadyBoundException: Failed to bind remote
    object...to
    replica aware stub at CatalogWebService; remaining name'sampleportal.BEA_commerce'
    After the server started with the above error, I tried to run the app, here
    is what
    occured:
    PortalPersistenceManager: portal'sampleportal/sampleportal' not found.
    Has anybody seen this before?
    Ellen

  • Javax.naming.NamingException    Please Helppppp !!

    Hi,
    There is my code :
    "PropertyResourceBundle namingProperties =
    (PropertyResourceBundle) PropertyResourceBundle.getBundle("MyAppNaming");
    Hashtable properties = getPropertyFromRB(namingProperties);
    initContext = new javax.naming.InitialContext(properties);
    java.lang.Object obj = initialContext.lookup(jndiName);"
    The last line returns an Exception :
    javax.naming.NamingException: Error during resolve [Root exception is java.lang.NullPointerException]
    The Application server containing the EJBs is well started, and the JNDI name for the EJbs in the application server and in my application are the same...
    Where am i wrong ??
    Thanks in advance for your help
    Steve

    Help me please, i become crazy with this problem !!
    Thanks
    Steve

  • Javax.naming.NameNoteFoundException on admin server startup

    On a WLS6.1+SP1 installation, I've created an Admin server and a Managed
    Server. Of a sudden, I'm noticing a naming exception in the beans deployed
    in the managed server. So, backtracking the problem, I bring up my admin
    server (managed server is down) and see the following when I open up a
    browser page for the admin server's JNDI tree and click on the java.comp
    link:
    javax.naming.NameNotFoundException: Unable to resolve comp. Resolved: ''
    Unresolved:'comp' ; remaining name ''
         <>
    Current Date
    Mon Mar 18 10:08:45 CST 2002
    Console Release Build
    Console Build
    Server Release Build
    6.1.1.0
    Server Build
    WebLogic Temporary Patch for CR064232 01/15/2002 06:32:18
    All Server Product Versions
    WebLogic Temporary Patch for CR064232 01/15/2002 06:32:18
    WebLogic Server 6.1 SP1 09/18/2001 14:28:44 #138716
    WebLogic XML Module 6.1 SP1 09/18/2001 14:43:02 #138716
    Server System Properties
    awt.toolkit = sun.awt.windows.WToolkit bea.home = e:/bea file.encoding =
    Cp1252 file.encoding.pkg = sun.io file.separator = \ java.awt.fonts =
    java.awt.graphicsenv = sun.awt.Win32GraphicsEnvironment java.awt.printerjob
    = sun.awt.windows.WPrinterJob java.class.path =
    .;.\lib\CR058838_61sp1.jar;.\lib\CR064232_61sp1.jar;.\lib\weblogic_sp.jar;.\
    lib\weblogic.jar java.class.version = 47.0 java.ext.dirs =
    e:\bea\jdk131\jre\lib\ext java.home = e:\bea\jdk131\jre java.io.tmpdir =
    E:\DOCUME~1\ewhite\LOCALS~1\Temp\ java.library.path =
    e:\bea\jdk131\bin;.;E:\WINNT\System32;E:\WINNT;.\bin;e:/bea/jdk131/bin;.\;d:
    \java\jdk1.3.1_02\bin;D:\Java\Jikes-1.15\bin;d:\java\jdk1.3.1_02\jre\bin;d:\
    mssdk\bin\.;d:\mssdk\bin\winnt\.;e:\oracle\ora81\bin;e:\program
    files\oracle\jre\1.1.7\bin;d:\bin;e:\devstudio\vc98\bin;e:\devstudio\common\
    msdev98;e:\devstudio\common\tools\winnt;e:\devstudio\common\tools;d:\mks\bin
    ;d:\mks\bin\x11;d:\mks\mksnt;e:\winnt\system32;e:\winnt;e:\winnt\system32\wb
    em;e:\program files\perforce;e:\program files\microsoft sql
    server\80\tools\binn;e:\devstudio\common\msdev98\bin;d:\bugseeker2\bin;E:\Pr
    ogram
    Files\doxygen\bin;d:\polyhedra\4.1\win32\i386\bin;d:\src\db-4.0.14\build_win
    32\Release;E:\Program Files\JavaSoft\JRE\1.3.0_02\bin\hotspot;
    java.naming.factory.initial = weblogic.jndi.WLInitialContextFactory
    java.naming.factory.url.pkgs = weblogic.jndi.factories
    java.protocol.handler.pkgs =
    weblogic.net|weblogic.management|weblogic.net|weblogic.net|weblogic.utils|we
    blogic.utils|weblogic.utils java.runtime.name = Java(TM) 2 Runtime
    Environment, Standard Edition java.runtime.version = 1.3.1-b24
    java.security.policy = =e:/bea\wlserver6.1sp1/lib/weblogic.policy
    java.specification.name = Java Platform API Specification
    java.specification.vendor = Sun Microsystems Inc. java.specification.version
    = 1.3 java.vendor = Sun Microsystems Inc. java.vendor.url =
    http://java.sun.com/ java.vendor.url.bug =
    http://java.sun.com/cgi-bin/bugreport.cgi java.version = 1.3.1 java.vm.info
    = mixed mode java.vm.name = Java HotSpot(TM) Client VM
    java.vm.specification.name = Java Virtual Machine Specification
    java.vm.specification.vendor = Sun Microsystems Inc.
    java.vm.specification.version = 1.0 java.vm.vendor = Sun Microsystems Inc.
    java.vm.version = 1.3.1-b24 javax.rmi.CORBA.PortableRemoteObjectClass =
    weblogic.iiop.PortableRemoteObjectDelegateImpl javax.rmi.CORBA.UtilClass =
    weblogic.iiop.UtilDelegateImpl javax.xml.parsers.DocumentBuilderFactory =
    weblogic.xml.jaxp.RegistryDocumentBuilderFactory
    javax.xml.parsers.SAXParserFactory =
    weblogic.xml.jaxp.RegistrySAXParserFactory
    javax.xml.transform.TransformerFactory =
    weblogic.xml.jaxp.RegistrySAXTransformerFactory jmx.implementation.name =
    JMX RI jmx.implementation.vendor = Sun Microsystems
    jmx.implementation.version = 1.0 jmx.specification.name = Java Management
    Extensions jmx.specification.vendor = Sun Microsystems
    jmx.specification.version = 1.0 Final Release line.separator =
    org.xml.sax.driver = weblogic.apache.xerces.parsers.SAXParser os.arch = x86
    os.name = Windows 2000 os.version = 5.0 path.separator = ;
    sun.boot.class.path =
    e:\bea\jdk131\jre\lib\rt.jar;e:\bea\jdk131\jre\lib\i18n.jar;e:\bea\jdk131\jr
    e\lib\sunrsasign.jar;e:\bea\jdk131\jre\classes sun.boot.library.path =
    e:\bea\jdk131\jre\bin sun.cpu.endian = little sun.cpu.isalist = pentium i486
    i386 sun.io.unicode.encoding = UnicodeLittle user.dir =
    E:\bea\wlserver6.1sp1 user.home = E:\Documents and Settings\ewhite
    user.language = en user.name = ewhite user.region = US user.timezone =
    America/Chicago weblogic.Domain = cfgdomain weblogic.Name = cfgserver
    weblogic.ProductionModeEnabled = true
    Request Info
    Protocol: HTTP/1.1
    ServerName: seven
    ServerPort: 7031
    Secure: false
    ContextPath: /console
    ServletPath: /common/error.jsp
    QueryString:
    context=java%3Acomp&server=cfgdomain%3AName%3Dcfgserver%2CType%3DServer
    PathInfo: null
    PathTranslated: null
    RequestURI: /console/common/error.jsp
    AuthType: null
    ContentType: null
    CharacterEncoding: null
    Locale: en_US
    Method: GET
    Session:
    weblogic.servlet.internal.session.MemorySessionData@ca001
    RequestedSessionId:
    PJYQ1qF2jHmBElsIY3UWeyAv28eGyCuiyz4yM26b1118N4Tm3SXg!1873029388!169017744!70
    31!7032!1016467710213
    RequestedSessionIdFromCookie: true
    RequestedSessionIdFromURL: false
    UserPrincipal: system
    RemoteUser: system
    RemoteAddr: 10.19.1.144
    RemoteHost: seven.vignette.com
    Parameters
    context = java:comp server = cfgdomain:Name=cfgserver,Type=Server
    Attributes
    wlinternalaction =
    weblogic.management.console.actions.internal.InternalActionContext@36f7e6
    java.util.Locale = en_US javax.servlet.error.exception_type = class
    javax.naming.NameNotFoundException javax.servlet.error.message = Unable to
    resolve comp. Resolved: '' Unresolved:'comp' javax.servlet.jsp.jspException
    = javax.naming.NameNotFoundException: Unable to resolve comp. Resolved: ''
    Unresolved:'comp' ; remaining name '' weblogic.auth.status = 0
    weblogic.httpd.user = system weblogic.management.console.catalog.Catalog =
    weblogic.management.console.catalog.XmlCatalog@192223
    weblogic.management.console.helpers.BrowserHelper = User-Agent: Mozilla/4.0
    (compatible; MSIE 6.0; Windows NT 5.0; Q312461) IE: true Netscape: false
    Supported: false JavscriptHrefs: false TableCellClick: true
    DocumentReloadedOnResize: false DropdownStretchable: true CellSpacingBlank:
    false EmptyCellBlank: false ImgOnclickSupported: true TableBorderFancy: true
    PartialToWideTables: false DisabledControlSupported: true
    weblogic.management.console.helpers.DebugHelper =
    weblogic.management.console.helpers.DebugHelper@5caa65
    weblogic.management.console.helpers.UnitsHelper =
    weblogic.management.console.helpers.UnitsHelper@104bc9
    weblogic.management.console.helpers.UrlHelper =
    weblogic.management.console.helpers.UrlHelper@4d3bec
    Headers
    Accept = image/gif, image/x-xbitmap, image/jpeg, image/pjpeg,
    application/vnd.ms-powerpoint, application/vnd.ms-excel, application/msword,
    */* Accept-Encoding = gzip, deflate Accept-Language = en-us Connection =
    Keep-Alive Cookie =
    JSESSIONID=PJYQ1qF2jHmBElsIY3UWeyAv28eGyCuiyz4yM26b1118N4Tm3SXg!1873029388!1
    69017744!7031!7032 Host = seven:7031 User-Agent = Mozilla/4.0 (compatible;
    MSIE 6.0; Windows NT 5.0; Q312461)
    BrowserInfo
    User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0;
    Q312461)
    IE: true
    Netscape: false
    Supported: false
    JavscriptHrefs: false
    TableCellClick: true
    DocumentReloadedOnResize: false
    DropdownStretchable: true
    CellSpacingBlank: false
    EmptyCellBlank: false
    ImgOnclickSupported: true
    TableBorderFancy: true
    PartialToWideTables: false
    DisabledControlSupported

    There is a known problem in 6.1 SP1. The known problem was
    corrected in SP2. Your symptoms are similar to the known
    problem ...
    DESCRIPTION: If you go to the examples server and view
    the JNDI tree, there is a naming context called comp/env.
    If you click on that naming context, you get message in
    the JNDI tree in the left pane that says access denied.
    You get the following exception in the right pane:
    javax.naming.NameNotFoundException: Unable to
    resolve comp.env Resolved: '' Unresolved:'comp' ;
    remaining name 'env'
    <>
    --------------- nested within: ------------------
    weblogic.management.console.actions.ActionException: Unable to resolve comp.env
    Resolved: '' Unresolved:'comp' - with nested exception:
    [javax.naming.NameNotFoundException: Unable to resolve comp.env Resolved:
    '' Unresolved:'comp' ; remaining name 'env']
    at weblogic.management.console.actions.ErrorAction.(ErrorAction.java:38)
    at weblogic.management.console.actions.jndi.ViewJndiContextAction.perform(ViewJndiContextAction.java:50)
    at weblogic.management.console.actions.internal.ActionServlet.doAction(ActionServlet.java:167)
    at weblogic.management.console.actions.internal.ActionServlet.doGet(ActionServlet.java:91)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
    at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:265)
    at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:200)
    at weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServletContext.java:2456)
    at weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl.java:2039)
    at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:139)
    at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120)
    Developer Relations Engineer
    BEA Support

  • Javax.naming.NotContextException when trying to bind to a context

    Hi all.
    I am trying to use file system service provider.
    This is how I create the context:
    Hashtable env = new Hashtable();
    env.put(Context.INITIAL_CONTEXT_FACTORY,
    "com.sun.jndi.fscontext.RefFSContextFactory");
    env.put(Context.PROVIDER_URL, "file:/test");
    DirContext ctx = new InitialDirContext(env);
    When I try to invoke bind on ctx ;
    ctx.bind(name, obj, attrs)
    I get exception:
    javax.naming.NotContextException: Not an instance of DirContext
    at javax.naming.directory.InitialDirContext.getURLOrDefaultInitDirCtx(Unknown Source)
    Can anyone help me get around this problem.
    thanks.

    I don't think that
    com.sun.jndi.fscontext.RefFSContextFactory
    supports DirContext; just Context.

  • Javax.naming.AuthenticationNotSupportedException:[LDAP:error Code 13

    package test;
    import java.util.Hashtable;
    import java.util.Enumeration;
    import javax.naming.*;
    import javax.naming.directory.*;
    import javax.naming.ldap.*;
    public class Test1{
    public static void main(String[] args) {
         try{
              Hashtable env = new Hashtable();
                   env.put(Context.INITIAL_CONTEXT_FACTORY,INITCTX);
                   env.put(Context.PROVIDER_URL,My_HOST);     
                   env.put(Context.SECURITY_AUTHENTICATION,"simple");
                   env.put(Context.SECURITY_PRINCIPAL,MGR_DN);
                   env.put(Context.SECURITY_CREDENTIALS,MGR_PW);
                   DirContext ctx=new InitialDirContext(env);
              }catch(Exception e){
                   e.printStackTrace();
                   System.exit(1);
         public static String INITCTX="com.sun.jndi.ldap.LdapCtxFactory";
         public static String My_HOST="ldap://192.168.0.88:389";
         public static String MGR_DN="uid=kvaughan,ou=people,o=airius.com";
         public static String MGR_PW="bribery";
         public static String MY_SEARCHBASE="o=Airius.com";
    javax.naming.AuthenticationNotSupportedException:[LDAP:error Code 13 Confidentiality Required]

    i have the same Exception
    this post from 2003 and no one post an advice!!
    the exception
    javax.naming.AuthenticationNotSupportedException: [LDAP: error code 48 - Inappropriate Authentication]
    but i found that it is related the
    env.put(Context.SECURITY_AUTHENTICATION, "simple"); // 'simple' = username + password
    simple, EXTERNAL, none
    but after adding this line i still have the same error!!

Maybe you are looking for