You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Gaurav Pruthi <gk...@gmail.com> on 2008/11/14 13:58:33 UTC

Tomcat Hanging Intermittently

Dear All,

I have tomcat server with apache (mod_jk) and mysql running on my box.
Initially there were no issues with the server. But from past one month, the
tomcat application hangs and websites also doesn't open. Though when i run
nmap localhost, it shows me 8080 and ajp13 services running.

I have notices that in last 1 month serveral websites have been hosted on
the box. Earlier around 6-10 websites were hosted but now it has increased
to 20. Is it putting load on the server.

I am facing another issue.
Most of the websites have .war files deployed, so whenever i restarts the
tomcat, it takes 90 seconds to start the tomcat. Time duration has also
incereased as the  no. websites have increased.

Kindly provide me some solution so that i don't have to face any downtime in
future.



Thanks,
Gaurav Pruthi

Re: Tomcat Hanging Intermittently

Posted by Kees Jan Koster <kj...@kjkoster.org>.
Dear Gaurav,

> I have tomcat server with apache (mod_jk) and mysql running on my box.
> Initially there were no issues with the server. But from past one  
> month, the
> tomcat application hangs and websites also doesn't open. Though when  
> i run
> nmap localhost, it shows me 8080 and ajp13 services running.

You could try to make a thread dump to see what Tomcat is doing. Any  
errors in the logs that you did not expect?

> I have notices that in last 1 month serveral websites have been  
> hosted on
> the box. Earlier around 6-10 websites were hosted but now it has  
> increased
> to 20. Is it putting load on the server.

Virtual server, or actual iron?

> I am facing another issue.
> Most of the websites have .war files deployed, so whenever i  
> restarts the
> tomcat, it takes 90 seconds to start the tomcat. Time duration has  
> also
> incereased as the  no. websites have increased.
>
> Kindly provide me some solution so that i don't have to face any  
> downtime in
> future.

Well, you can start by installing multiple instances of Tomcat and  
placing a few sites in each. If you have the memory I would probably  
aim for having one Tomcat instance per handful of web application (as  
long as they are not inter-dependent). Then use Apache to route the  
traffic to the right application.

That way, if one appliction screws up you don't have to restart the  
whole Tomcat server, just the one instance.
--
Kees Jan

http://java-monitor.com/forum/
kjkoster@kjkoster.org
06-51838192

Rule 1 for being in a hole: stop digging.


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Tomcat Hanging Intermittently

Posted by Christopher Schultz <ch...@christopherschultz.net>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Gaurav,

Gaurav Pruthi wrote:
> I have tomcat server with apache (mod_jk) and mysql running on my box.
> Initially there were no issues with the server. But from past one month, the
> tomcat application hangs and websites also doesn't open. Though when i run
> nmap localhost, it shows me 8080 and ajp13 services running.
> 
> I have notices that in last 1 month serveral websites have been hosted on
> the box. Earlier around 6-10 websites were hosted but now it has increased
> to 20. Is it putting load on the server.

Then Tomcat freezes like this, does it ever recover? How long does that
take? You should take a thread dump during the freeze to find out what
the threads are doing.

> I am facing another issue.

You should start another thread on the mailing list if you have a
separate question.

> Most of the websites have .war files deployed, so whenever i restarts the
> tomcat, it takes 90 seconds to start the tomcat. Time duration has also
> incereased as the  no. websites have increased.

So... deploying an increasing number of web applications increases
startup time? What did you expect?

- -chris

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkkdouUACgkQ9CaO5/Lv0PDPGACfWR7LKZ+TxCoG8OOQSNbb86Kp
oYcAoKELbgkjx/Kwm2Pqgzw6b4bJ/pYR
=lTVp
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Tomcat Hanging Intermittently

Posted by Vasanth Kumar ravi <jo...@gmail.com>.
 have tomcat server with apache (mod_jk) and mysql running on my box.
Initially there were no issues with the server. But from past one month, the
tomcat application hangs and websites also doesn't open. Though when i run
nmap localhost, it shows me 8080 and ajp13 services running.

Check the cpu/memory utilized in the server.
Check your GC logs, if you have one.
Did u get any OOM errors in yout tomcat log files or any other exceptions
while accessing the website.


I have notices that in last 1 month serveral websites have been hosted on
the box. Earlier around 6-10 websites were hosted but now it has increased
to 20. Is it putting load on the server.

Check the cpu/memory utilized in the server. - to find the cause.

I am facing another issue.
Most of the websites have .war files deployed, so whenever i restarts the
tomcat, it takes 90 seconds to start the tomcat. Time duration has also
incereased as the  no. websites have increased.

All depends on your mem/cpu aavailable for use .


On Fri, Nov 14, 2008 at 8:58 PM, Gaurav Pruthi <gk...@gmail.com> wrote:

> Dear All,
>
> I have tomcat server with apache (mod_jk) and mysql running on my box.
> Initially there were no issues with the server. But from past one month,
> the
> tomcat application hangs and websites also doesn't open. Though when i run
> nmap localhost, it shows me 8080 and ajp13 services running.
>
> I have notices that in last 1 month serveral websites have been hosted on
> the box. Earlier around 6-10 websites were hosted but now it has increased
> to 20. Is it putting load on the server.
>
> I am facing another issue.
> Most of the websites have .war files deployed, so whenever i restarts the
> tomcat, it takes 90 seconds to start the tomcat. Time duration has also
> incereased as the  no. websites have increased.
>
> Kindly provide me some solution so that i don't have to face any downtime
> in
> future.
>
>
>
> Thanks,
> Gaurav Pruthi
>



-- 
Regards&Thanks,
Vasanth Kumar Ravi