Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / General / August 2007

Tip: Looking for answers? Try searching our database.

Tomcat hangs when connecting to Oracle

Thread view: 
kymmx@naver.com - 18 Aug 2007 04:08 GMT
Hi!

My Tomcat web application fails to connect to Oracle with the
following setup. The browser just hangs and finally times out or the
page doesn't change. It's like a typical packet filtering firewall
situation but I flushed my iptables(with -F option) and my ISP
answered me that they don't have any firewalls or whatever in their
networks.

CentOS 4 Linux with kernel 2.6.9-42.0.3.EL
Tomcat 6.0.14 with native library 1.1.10
Tomcat Connector 1.2.25

When I create and run a Java application that simply connects to and
gets some data from the Oracle server, all are fine. ie. only web
applications(or web pages with Tomcat data sources) suffers the
problem.

Where should I look into? Thanks for reading.
Arne Vajhøj - 18 Aug 2007 04:11 GMT
> My Tomcat web application fails to connect to Oracle with the
> following setup. The browser just hangs and finally times out or the
[quoted text clipped - 13 lines]
>
> Where should I look into?

Tomcat log files seems as a good starting point.

Arne
kymmx@naver.com - 18 Aug 2007 05:07 GMT
> Tomcat log files seems as a good starting point.

It just hangs. No logs are generated. It drives me crazy for hours.

Oh, there's another thing to say. Sometimes a test JSP page with
direct JDBC connect succeeds to connect sometimes immediately,
sometimes in about 30 seconds.
Manish Pandit - 18 Aug 2007 05:26 GMT
On Aug 17, 9:07 pm, ky...@naver.com wrote:
> > Tomcat log files seems as a good starting point.
>
[quoted text clipped - 3 lines]
> direct JDBC connect succeeds to connect sometimes immediately,
> sometimes in about 30 seconds.

Run 'top' and check if you see tomcat eating up CPU or memory while it
blocks on a db call.

Given the network latency issue, you can try traceroute from tomcat
box to oracle box and check if you are not seeing any dropped packets
(* in the output). This will also give you an idea of the hops and
latency per hop. Run it a couple of times to get more data points...

-cheers,
Manish
kymmx@naver.com - 18 Aug 2007 05:39 GMT
Sorry, it seems to be the problem in my application. One of my web
page tried to connect to a shutdown server and it hanged all of other
database connections.

Never mind this threads.
Arne Vajhøj - 18 Aug 2007 13:39 GMT
>> Tomcat log files seems as a good starting point.
>
> It just hangs. No logs are generated. It drives me crazy for hours.

Tomcat should generate a log file even if it is running fine.

Arne


Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.