Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: Help with Tomcat & Oracle on localhost
On Oct 24, 1:26 pm, Henner Hucke <henner.hu..._at_nospam.de> wrote:
> BikRboy schrieb:
>
> > Hello!
>
> > My shop recently relocated our Oracle 10g instance to a new box.
> > Since, this action, I can no longer run JSP's from my local host
> > (Windows XP) running the Tomcat 5.5.17 web server that came with
> > NetBeans 5.5.1.
>
> > However, the JSP's do connect to Oracle and run as they should on the
> > HP UNIX host.
>
> > I was able to compile my JSP code using NetBeans on my local host and
> > run it with Tomcat prior to the migration. I am using the J2EE 1.4
> > framework.
>
> > This is an extract of the error I get in Tomcat:
>
> > org.apache.jasper.JasperException: Exception in JSP: /gtc_ord.jsp:43
>
> > 40: ResultSetMetaData rsmd;
> > 41:
> > 42: try {
> > 43: Class.forName("oracle.jdbc.driver.OracleDriver");
> > 44: conn = DriverManager.getConnection(dbConn,
> > "userName", "passWord");
> > 45:
> > 46: S = conn.createStatement();
>
> > When the above code runs on the Oracle Application Server, it is
> > successful. Data is pulled from the database and the page displays as
> > it should.
>
> > Actions Taken:
> > --------------------
> > 1. Classpath: Unchanged on the local host.
>
> > 2. TNSNAMES.ORA: I can connect to Oracle using the NetBeans SQL Editor
> > & TOAD. They use the same TNSNAMES.ORA file. Addtionally, I can
> > successfully TNSPING the listener from the DOS prompt.
>
> > 3. Library: According to the Oracle documentation, I need to include
> > this JAR file ---- ORAI18N.JAR. Although, I did not need it before I
> > have added this JAR file to the "WEB-INF/lib" path.
>
> > 4. Cleaned, rebuilt, and redeployed the project.
>
> > Does anyone out there have any ideas?
>
> > I prefer to develop code locally before deploying it to the UNIX
> > server. This used to work.
>
> > Thank you, --- Mark
>
> Hello Mark,
>
> in addition what you already did, I would also write a small java test
> program only to see that it can connect to the database using the same
> parameters as you are using in the .jsp. If I run an app on my local
> tomcat to connect to remote databases I normally get an error stack
> including the ORA error number at the top of it. It would help to find
> the reason for your problem if we see the error stack.
>
> Henner
================== 05 NOV 07 =========
Here is the entry from my Catalina log:
java.library.path: C:\Program Files\Java\jdk1.5.0_12\bin;.;C:\WINDOWS \system32;C:\WINDOWS;.;c:\oracle\product\10.2.0\client_1\bin;C: \Program Files\Common Files\Roxio Shared\DLLShared;C:\Program Files\WinSCP\;C:\Program Files\Java\jdk1.5.0_12\bin\;C:\Program Files\Java \jdk1.5.0_12\bin\java;C:\Program Files\Java\jdk1.5.0_12\bin\javac; Nov 2, 2007 2:44:21 PM org.apache.coyote.http11.Http11BaseProtocol init
at
org.apache.naming.resources.FileDirContext.setDocBase(FileDirContext.java:
140)
at
org.apache.catalina.core.StandardContext.resourcesStart(StandardContext.java:
3814)
at
org.apache.catalina.core.StandardContext.start(StandardContext.java:
3985)
at
org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:
759)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java: 739)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java: 524)
at
org.apache.catalina.startup.HostConfig.deployDescriptor(HostConfig.java:
608)
at
org.apache.catalina.startup.HostConfig.deployDescriptors(HostConfig.java:
535)
at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java: 470)
at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1122) at
at
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:
119)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java: 1021)
at org.apache.catalina.core.StandardHost.start(StandardHost.java:718) at org.apache.catalina.core.ContainerBase.start(ContainerBase.java: 1013) at org.apache.catalina.core.StandardEngine.start(StandardEngine.java: 442) at
at org.apache.catalina.core.StandardServer.start(StandardServer.java: 709)
at org.apache.catalina.startup.Catalina.start(Catalina.java:551) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:
25)
at java.lang.reflect.Method.invoke(Method.java:585) at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:294) at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:432)Nov 2, 2007 2:44:22 PM org.apache.catalina.core.StandardContext start SEVERE: Error in resourceStart()
![]() |
![]() |