Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Oracle DataSource --Driver Not Found

13 views
Skip to first unread message

curmudgeon99

unread,
Dec 18, 2006, 4:04:45 PM12/18/06
to
Although I have the Correct Jar files in every conceivable location, and the
Admin Console reports that it can connect to the data source, I always get the
error below when starting the JRun server from Eclipse (MyEclipse). Any ideas?

resources.xml, error: {1}
java.lang.ClassNotFoundException: oracle.jdbc.driver.OracleDriver
at jrunx.util.JRunURLClassLoader.findClass(JRunURLClassLoader.java:161)
at java.lang.ClassLoader.loadClass(Unknown Source)
at jrunx.util.JRunURLClassLoader.loadClass(JRunURLClassLoader.java:77)
at jrunx.util.JRunURLClassLoader.loadClass(JRunURLClassLoader.java:69)
at java.lang.ClassLoader.loadClassInternal(Unknown Source)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Unknown Source)
at jrun.sql.pool.JDBCPool.createPhysicalConnection(JDBCPool.java:580)
at jrun.sql.pool.JDBCPool.create(JDBCPool.java:550)
at jrun.sql.pool.JDBCPool.create(JDBCPool.java:541)
at jrunx.pool.ObjectPool.checkOut(ObjectPool.java:240)
at jrunx.pool.ObjectPool.init(ObjectPool.java:73)
at jrun.sql.pool.JDBCPool.init(JDBCPool.java:179)
at jrun.sql.pool.JDBCPool.<init>(JDBCPool.java:102)
at jrun.sql.pool.JDBCManager.createPool(JDBCManager.java:53)
at jrun.sql.management.DataSourceService.start(DataSourceService.java:75)
at sun.reflect.GeneratedMethodAccessor13.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at com.sun.jmx.mbeanserver.StandardMetaDataImpl.invoke(Unknown Source)
at com.sun.jmx.mbeanserver.MetaDataImpl.invoke(Unknown Source)
at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(Unknown
Source)
at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(Unknown Source)
at
jrun.deployment.resource.ResourceDeployer.startDataSources(ResourceDeployer.java
:225)
at jrun.deployment.resource.ResourceDeployer.start(ResourceDeployer.java:84)
at sun.reflect.GeneratedMethodAccessor13.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at com.sun.jmx.mbeanserver.StandardMetaDataImpl.invoke(Unknown Source)
at com.sun.jmx.mbeanserver.MetaDataImpl.invoke(Unknown Source)
at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(Unknown
Source)
at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(Unknown Source)
at jrunx.kernel.ServiceAdapter.invokeMethod(ServiceAdapter.java:705)
at
jrunx.kernel.JRunServiceDeployer.invokeOnServices(JRunServiceDeployer.java:460)
at
jrunx.kernel.JRunServiceDeployer.startServices(JRunServiceDeployer.java:312)
at
jrunx.kernel.JRunServiceDeployer.startLifecycle(JRunServiceDeployer.java:260)
at
jrunx.kernel.JRunServiceDeployer.deployServices(JRunServiceDeployer.java:87)
at jrunx.kernel.DeploymentService.loadServices(DeploymentService.java:46)
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 com.sun.jmx.mbeanserver.StandardMetaDataImpl.invoke(Unknown Source)
at com.sun.jmx.mbeanserver.MetaDataImpl.invoke(Unknown Source)
at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(Unknown
Source)
at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(Unknown Source)
at jrunx.kernel.JRun.startServer(JRun.java:558)
at jrunx.kernel.JRun.<init>(JRun.java:476)
at jrunx.kernel.JRun$1.run(JRun.java:329)
at java.security.AccessController.doPrivileged(Native Method)
at jrunx.kernel.JRun.start(JRun.java:326)
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 jrunx.kernel.JRun.invoke(JRun.java:180)
at jrunx.kernel.JRun.main(JRun.java:168)

12/18 15:55:28 error Encountered the following error while initializing
JDBCPool: {0}
java.sql.SQLException: No suitable driver available for
ReadersAdvantageDS_RADB, please check the driver setting in jrun-resources.xml,
error: oracle.jdbc.driver.OracleDriver
at jrun.sql.pool.JDBCPool.createPhysicalConnection(JDBCPool.java:629)
at jrun.sql.pool.JDBCPool.create(JDBCPool.java:550)
at jrun.sql.pool.JDBCPool.create(JDBCPool.java:541)
at jrunx.pool.ObjectPool.checkOut(ObjectPool.java:240)
at jrunx.pool.ObjectPool.init(ObjectPool.java:73)
at jrun.sql.pool.JDBCPool.init(JDBCPool.java:179)
at jrun.sql.pool.JDBCPool.<init>(JDBCPool.java:102)
at jrun.sql.pool.JDBCManager.createPool(JDBCManager.java:53)
at jrun.sql.management.DataSourceService.start(DataSourceService.java:75)
at sun.reflect.GeneratedMethodAccessor13.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at com.sun.jmx.mbeanserver.StandardMetaDataImpl.invoke(Unknown Source)
at com.sun.jmx.mbeanserver.MetaDataImpl.invoke(Unknown Source)
at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(Unknown
Source)
at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(Unknown Source)
at
jrun.deployment.resource.ResourceDeployer.startDataSources(ResourceDeployer.java
:225)
at jrun.deployment.resource.ResourceDeployer.start(ResourceDeployer.java:84)
at sun.reflect.GeneratedMethodAccessor13.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at com.sun.jmx.mbeanserver.StandardMetaDataImpl.invoke(Unknown Source)
at com.sun.jmx.mbeanserver.MetaDataImpl.invoke(Unknown Source)
at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(Unknown
Source)
at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(Unknown Source)
at jrunx.kernel.ServiceAdapter.invokeMethod(ServiceAdapter.java:705)
at
jrunx.kernel.JRunServiceDeployer.invokeOnServices(JRunServiceDeployer.java:460)
at
jrunx.kernel.JRunServiceDeployer.startServices(JRunServiceDeployer.java:312)
at
jrunx.kernel.JRunServiceDeployer.startLifecycle(JRunServiceDeployer.java:260)
at
jrunx.kernel.JRunServiceDeployer.deployServices(JRunServiceDeployer.java:87)
at jrunx.kernel.DeploymentService.loadServices(DeploymentService.java:46)
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 com.sun.jmx.mbeanserver.StandardMetaDataImpl.invoke(Unknown Source)
at com.sun.jmx.mbeanserver.MetaDataImpl.invoke(Unknown Source)
at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(Unknown
Source)
at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(Unknown Source)
at jrunx.kernel.JRun.startServer(JRun.java:558)
at jrunx.kernel.JRun.<init>(JRun.java:476)
at jrunx.kernel.JRun$1.run(JRun.java:329)
at java.security.AccessController.doPrivileged(Native Method)
at jrunx.kernel.JRun.start(JRun.java:326)
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 jrunx.kernel.JRun.invoke(JRun.java:180)
at jrunx.kernel.JRun.main(JRun.java:168)

12/18 15:55:28 info JRun DataSourceService: Created JDBC XA Connection Pool
named ReadersAdvantageDS_RADB
12/18 15:55:28 info JRun Web Server listening on *:8100
12/18 15:55:29 info JRun Proxy Server listening on *:51000
12/18 15:55:29 info Deploying enterprise application "JRun 4.0 Internal J2EE
Components" from: file:/C:/dev/JRun4/lib/jrun-comp.ear
12/18 15:55:29 info Deploying EJB "JRunSQLInvoker" from:
file:/C:/dev/JRun4/lib/jrun-comp.ear
12/18 15:55:30 info Deploying web application
"file:/C:/dev/JRun4/servers/default/BN1_Prototype/" from:
file:/C:/dev/JRun4/servers/default/BN1_Prototype/
12/18 15:55:30 user JSPServlet: init
12/18 15:55:30 info Deploying enterprise application "default-ear" from:
file:/C:/dev/JRun4/servers/default/default-ear/
12/18 15:55:31 info Deploying web application "JRun Default Web Application"
from: file:/C:/dev/JRun4/servers/default/default-ear/
12/18 15:55:32 info Web Services in default-ear#default-war:
12/18 15:55:32 info AdminService
12/18 15:55:32 user JSPServlet: init
12/18 15:55:32 info Deploying web application
"file:/C:/dev/JRun4/servers/default/ra/" from:
file:/C:/dev/JRun4/servers/default/ra/
Server default ready (startup time: 9 seconds)
12/18 15:55:32 user JSPServlet: init
12/18 15:55:33 info Deploying enterprise application "Macromedia Flash
Remoting MX EAR" from: file:/C:/dev/JRun4/lib/flashgateway.ear
12/18 15:55:33 info Deploying web application "Macromedia Flash Remoting MX"
from: file:/C:/dev/JRun4/lib/flashgateway.ear
12/18 15:55:33 user JSPServlet: init
12/18 15:55:33 user FlashGatewayServlet: init


stefanotravelli

unread,
Dec 19, 2006, 7:22:26 AM12/19/06
to
Usually you put the JDBC Driver jar, that is ojdbc14.jar, in the servers/lib
folder and that's all.

Don't forget to restart the service.

Consider using the bundled data direct driver instead of the Oracle's one
under JRun.

curmudgeon99

unread,
Dec 19, 2006, 8:23:34 AM12/19/06
to
Stefano,
Thank you kindly for your reply. I already did have the ojdbc_g.jar (and
ojdbc_g.zip for good measure) in the servers\lib directory but I always get a
ClassNotFound. I have placed that jar in every lib folder I can find but it is
never found, despite its presence on the eclipse .classpath file before I
deploy.
Is there some issue with using the native Oracle drivers? I'm concerned
about performance with the DataDirect drivers. I seem to recall having
performance issues with that which caused us to prefer the native oracle ones.
Any insights on this?

Thank you,
Tom

stefanotravelli

unread,
Dec 19, 2006, 5:36:05 PM12/19/06
to
I never used MyEclipse, however I guess it start JRun with a shell command as
usual. So the classpath for the server instance is not really related with the
.classpath file in your project, rather it depends on JRun configuration.
JRun gets jars from several folders so to configure classloaders for the J2ee
container according to the specifications.
The base J2ee classloader loads jars from the servers/lib folder because of a
specific settings in the jvm.config file, that is
"java.library.path={jrun.home}/servers/lib". In fact, one could modify this
setting in order to have separate library configuration for different server
instances.

That said, it could be the case that your MyEclipse is launching JRun with a
jvm.config with some other settings so that it doesn't include the servers/lib
folder.

The configuration file to be used is set with '-config' parameter, that is for
instance: "jrun.sh -config your.setting.config -start default".

Regarding drivers performance, of course DataDirect claims that their drivers
are better and faster than the Oracle ones. I can only witness that with
DataDirect you don't have to get crazy with Blob fields.

Hope this helps

0 new messages