4 Replies Latest reply on Jan 6, 2003 6:17 AM by Hao.Zeng

    JBoss can't find data source

    Hao.Zeng Newbie

      Hi!

      Environment:

      Windows2000 Server
      MS SQLServer2000 with JDBC driver installed
      JBuilder7 integrated with JBoss3.0.2

      When deploying an EJB 2.0 CMP entity bean, jboss

      can't find the specified data source, the error

      message is as follows:




      18:54:01,421 WARN [ServiceController] Problem starting service jboss.j2ee:service=EJB,jndiName=OrderRemote

      org.jboss.deployment.DeploymentException: Error: can't find data source: Enterprise; - nested throwable: (javax.naming.NameNotFoundException: Enterprise not bound)

      at org.jboss.ejb.plugins.cmp.jdbc.bridge.JDBCEntityBridge.(JDBCEntityBridge.java:99)

      at org.jboss.ejb.plugins.cmp.jdbc.JDBCStoreManager.initStoreManager(JDBCStoreManager.java:397)

      at org.jboss.ejb.plugins.cmp.jdbc.JDBCStoreManager.start(JDBCStoreManager.java:339)

      at org.jboss.ejb.plugins.CMPPersistenceManager.start(CMPPersistenceManager.java:198)

      at org.jboss.ejb.EntityContainer.start(EntityContainer.java:376)

      at org.jboss.ejb.Container.invoke(Container.java:764)

      at org.jboss.ejb.EntityContainer.invoke(EntityContainer.java:1055)

      at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:517)

      at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:967)

      at $Proxy5.start(Unknown Source)

      at org.jboss.system.ServiceController.start(ServiceController.java:396)

      at java.lang.reflect.Method.invoke(Native Method)

      at org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284)

      at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:517)

      at org.jboss.util.jmx.MBeanProxy.invoke(MBeanProxy.java:174)

      at $Proxy73.start(Unknown Source)

      at org.jboss.ejb.EjbModule.startService(EjbModule.java:430)

      at org.jboss.system.ServiceMBeanSupport.start(ServiceMBeanSupport.java:164)

      at java.lang.reflect.Method.invoke(Native Method)

      at org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284)

      at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:517)

      at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:967)

      at $Proxy5.start(Unknown Source)

      at org.jboss.system.ServiceController.start(ServiceController.java:396)

      at java.lang.reflect.Method.invoke(Native Method)

      at org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284)

      at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:517)

      at org.jboss.util.jmx.MBeanProxy.invoke(MBeanProxy.java:174)

      at $Proxy8.start(Unknown Source)

      at org.jboss.ejb.EJBDeployer.start(EJBDeployer.java:394)

      at org.jboss.deployment.MainDeployer.start(MainDeployer.java:802)

      at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:616)

      at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:580)

      at java.lang.reflect.Method.invoke(Native Method)

      at org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284)

      at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:517)

      at org.jboss.util.jmx.MBeanProxy.invoke(MBeanProxy.java:174)

      at $Proxy4.deploy(Unknown Source)

      at org.jboss.deployment.scanner.URLDeploymentScanner.deploy(URLDeploymentScanner.java:427)

      at org.jboss.deployment.scanner.URLDeploymentScanner.scan(URLDeploymentScanner.java:553)

      at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.doScan(AbstractDeploymentScanner.java:212)

      at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.loop(AbstractDeploymentScanner.java:225)

      at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.run(AbstractDeploymentScanner.java:202)

      + nested throwable:

      javax.naming.NameNotFoundException: Enterprise not bound

      at org.jnp.server.NamingServer.getBinding(NamingServer.java:495)

      at org.jnp.server.NamingServer.getBinding(NamingServer.java:503)

      at org.jnp.server.NamingServer.getObject(NamingServer.java:509)

      at org.jnp.server.NamingServer.lookup(NamingServer.java:282)

      at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:456)

      at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:440)

      at javax.naming.InitialContext.lookup(InitialContext.java:350)

      at org.jboss.ejb.plugins.cmp.jdbc.bridge.JDBCEntityBridge.(JDBCEntityBridge.java:96)

      at org.jboss.ejb.plugins.cmp.jdbc.JDBCStoreManager.initStoreManager(JDBCStoreManager.java:397)

      at org.jboss.ejb.plugins.cmp.jdbc.JDBCStoreManager.start(JDBCStoreManager.java:339)

      at org.jboss.ejb.plugins.CMPPersistenceManager.start(CMPPersistenceManager.java:198)

      at org.jboss.ejb.EntityContainer.start(EntityContainer.java:376)

      at org.jboss.ejb.Container.invoke(Container.java:764)

      at org.jboss.ejb.EntityContainer.invoke(EntityContainer.java:1055)

      at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:517)

      at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:967)

      at $Proxy5.start(Unknown Source)

      at org.jboss.system.ServiceController.start(ServiceController.java:396)

      at java.lang.reflect.Method.invoke(Native Method)

      at org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284)

      at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:517)

      at org.jboss.util.jmx.MBeanProxy.invoke(MBeanProxy.java:174)

      at $Proxy73.start(Unknown Source)

      at org.jboss.ejb.EjbModule.startService(EjbModule.java:430)

      at org.jboss.system.ServiceMBeanSupport.start(ServiceMBeanSupport.java:164)

      at java.lang.reflect.Method.invoke(Native Method)

      at org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284)

      at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:517)

      at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:967)

      at $Proxy5.start(Unknown Source)

      at org.jboss.system.ServiceController.start(ServiceController.java:396)

      at java.lang.reflect.Method.invoke(Native Method)

      at org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284)

      at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:517)

      at org.jboss.util.jmx.MBeanProxy.invoke(MBeanProxy.java:174)

      at $Proxy8.start(Unknown Source)

      at org.jboss.ejb.EJBDeployer.start(EJBDeployer.java:394)

      at org.jboss.deployment.MainDeployer.start(MainDeployer.java:802)

      at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:616)

      at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:580)

      at java.lang.reflect.Method.invoke(Native Method)

      at org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284)

      at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:517)

      at org.jboss.util.jmx.MBeanProxy.invoke(MBeanProxy.java:174)

      at $Proxy4.deploy(Unknown Source)

      at org.jboss.deployment.scanner.URLDeploymentScanner.deploy(URLDeploymentScanner.java:427)

      at org.jboss.deployment.scanner.URLDeploymentScanner.scan(URLDeploymentScanner.java:553)

      at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.doScan(AbstractDeploymentScanner.java:212)

      at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.loop(AbstractDeploymentScanner.java:225)

      at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.run(AbstractDeploymentScanner.java:202)

      18:54:01,437 INFO [EjbModule] Started

      18:54:01,437 INFO [MainDeployer] Deployed package: file:/E:/Soft/JBoss/jboss/jboss-3.0.2/jboss-3.0.2/jboss-3.0.2/server/all/deploy/Entity2.jar

      18:54:01,437 ERROR [URLDeploymentScanner] MBeanException: Exception in MBean operation 'checkIncompleteDeployments()'
      Cause: Incomplete Deployment listing:
      Packages waiting for a deployer:

      Incompletely deployed packages:

      MBeans waiting for classes:

      MBeans waiting for other MBeans:
      [ObjectName: jboss.j2ee:service=EJB,jndiName=OrderRemote
      state: FAILED
      I Depend On:
      Depends On Me: org.jboss.deployment.DeploymentException: Error: can't find data source: Enterprise; - nested throwable: (javax.naming.NameNotFoundException: Enterprise not bound)]




      How to eliminate it?

        • 1. Re: JBoss can't find data source
          patrick Novice

          Did you have a look at
          localhost:8080/jmx-console

          Search for the jndi list thing and all bound jndi names will be displayed.

          My guess is that your name in the cmp2 isn't configured as a ???-service.xml

          • 2. Re: JBoss can't find data source
            Hao.Zeng Newbie

            While opening the address localhost:8080/jmx-console with

            IE, it shows the following error:




            HTTP ERROR: 500 sun/tools/javac/Main
            RequestURI=/jmx-console/






            At the same time, the following error message is shown in

            the JBoss console window:






            20:19:01,625 WARN [jbossweb] WARNING: Exception for /jmx-console/
            java.lang.NoClassDefFoundError: sun/tools/javac/Main

            at org.apache.jasper.compiler.SunJavaCompiler.compile(SunJavaCompiler.java:136)

            at org.apache.jasper.compiler.Compiler.compile(Compiler.java:276)

            at org.apache.jasper.servlet.JspServlet.loadJSP(JspServlet.java:548)

            at org.apache.jasper.servlet.JspServlet$JspServletWrapper.loadIfNecessary(JspServlet.java:176)

            at org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServlet.java:188)

            at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:381)

            at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:473)

            at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)

            at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:344)

            at org.mortbay.jetty.servlet.WebApplicationHandler.dispatch(WebApplicationHandler.java:313)

            at org.mortbay.jetty.servlet.Dispatcher.forward(Dispatcher.java:204)

            at org.mortbay.jetty.servlet.Default.handleGet(Default.java:222)

            at org.mortbay.jetty.servlet.Default.service(Default.java:142)

            at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)

            at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:344)

            at org.mortbay.jetty.servlet.WebApplicationHandler.dispatch(WebApplicationHandler.java:313)

            at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:554)

            at org.mortbay.jetty.servlet.WebApplicationHandler.handle(WebApplicationHandler.java:199)

            at org.mortbay.http.HttpContext.handle(HttpContext.java:1572)

            at org.mortbay.http.HttpContext.handle(HttpContext.java:1522)

            at org.mortbay.http.HttpServer.service(HttpServer.java:795)

            at org.jboss.jetty.Jetty.service(Jetty.java:531)

            at org.mortbay.http.HttpConnection.service(HttpConnection.java:784)

            at org.mortbay.http.HttpConnection.handleNext(HttpConnection.java:941)

            at org.mortbay.http.HttpConnection.handle(HttpConnection.java:799)

            at org.mortbay.http.SocketListener.handleConnection(SocketListener.java:186)

            at org.mortbay.util.ThreadedServer.handle(ThreadedServer.java:322)

            at org.mortbay.util.ThreadPool$JobRunner.run(ThreadPool.java:716)

            at java.lang.Thread.run(Thread.java:484)










            What's the matter?

            • 3. Re: JBoss can't find data source
              Adrian Brock Master

              JAVA_HOME

              Regards,
              Adrian

              • 4. Re: JBoss can't find data source
                Hao.Zeng Newbie

                It seems that there's nothing to do with JAVA_HOME, since

                the same error messages are shown, either with JAVA_HOME

                or without JAVA_HOME.